LCOV - code coverage report
Current view: top level - home/czgdp18079/Quansight/scipy/build/scipy/ndimage/_ni_label.cpython-312-x86_64-linux-gnu.so.p - _ni_label.c (source / functions) Hit Total Coverage
Test: lcov.info Lines: 6014 16561 36.3 %
Date: 2024-11-20 10:49:04 Functions: 186 456 40.8 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* Generated by Cython 3.0.11 */
       2             : 
       3             : #ifndef PY_SSIZE_T_CLEAN
       4             : #define PY_SSIZE_T_CLEAN
       5             : #endif /* PY_SSIZE_T_CLEAN */
       6             : #if defined(CYTHON_LIMITED_API) && 0
       7             :   #ifndef Py_LIMITED_API
       8             :     #if CYTHON_LIMITED_API+0 > 0x03030000
       9             :       #define Py_LIMITED_API CYTHON_LIMITED_API
      10             :     #else
      11             :       #define Py_LIMITED_API 0x03030000
      12             :     #endif
      13             :   #endif
      14             : #endif
      15             : 
      16             : #include "Python.h"
      17             : #ifndef Py_PYTHON_H
      18             :     #error Python headers needed to compile C extensions, please install development version of Python.
      19             : #elif PY_VERSION_HEX < 0x02070000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
      20             :     #error Cython requires Python 2.7+ or Python 3.3+.
      21             : #else
      22             : #if defined(CYTHON_LIMITED_API) && CYTHON_LIMITED_API
      23             : #define __PYX_EXTRA_ABI_MODULE_NAME "limited"
      24             : #else
      25             : #define __PYX_EXTRA_ABI_MODULE_NAME ""
      26             : #endif
      27             : #define CYTHON_ABI "3_0_11" __PYX_EXTRA_ABI_MODULE_NAME
      28             : #define __PYX_ABI_MODULE_NAME "_cython_" CYTHON_ABI
      29             : #define __PYX_TYPE_MODULE_PREFIX __PYX_ABI_MODULE_NAME "."
      30             : #define CYTHON_HEX_VERSION 0x03000BF0
      31             : #define CYTHON_FUTURE_DIVISION 1
      32             : #include <stddef.h>
      33             : #ifndef offsetof
      34             :   #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
      35             : #endif
      36             : #if !defined(_WIN32) && !defined(WIN32) && !defined(MS_WINDOWS)
      37             :   #ifndef __stdcall
      38             :     #define __stdcall
      39             :   #endif
      40             :   #ifndef __cdecl
      41             :     #define __cdecl
      42             :   #endif
      43             :   #ifndef __fastcall
      44             :     #define __fastcall
      45             :   #endif
      46             : #endif
      47             : #ifndef DL_IMPORT
      48             :   #define DL_IMPORT(t) t
      49             : #endif
      50             : #ifndef DL_EXPORT
      51             :   #define DL_EXPORT(t) t
      52             : #endif
      53             : #define __PYX_COMMA ,
      54             : #ifndef HAVE_LONG_LONG
      55             :   #define HAVE_LONG_LONG
      56             : #endif
      57             : #ifndef PY_LONG_LONG
      58             :   #define PY_LONG_LONG LONG_LONG
      59             : #endif
      60             : #ifndef Py_HUGE_VAL
      61             :   #define Py_HUGE_VAL HUGE_VAL
      62             : #endif
      63             : #define __PYX_LIMITED_VERSION_HEX PY_VERSION_HEX
      64             : #if defined(GRAALVM_PYTHON)
      65             :   /* For very preliminary testing purposes. Most variables are set the same as PyPy.
      66             :      The existence of this section does not imply that anything works or is even tested */
      67             :   #define CYTHON_COMPILING_IN_PYPY 0
      68             :   #define CYTHON_COMPILING_IN_CPYTHON 0
      69             :   #define CYTHON_COMPILING_IN_LIMITED_API 0
      70             :   #define CYTHON_COMPILING_IN_GRAAL 1
      71             :   #define CYTHON_COMPILING_IN_NOGIL 0
      72             :   #undef CYTHON_USE_TYPE_SLOTS
      73             :   #define CYTHON_USE_TYPE_SLOTS 0
      74             :   #undef CYTHON_USE_TYPE_SPECS
      75             :   #define CYTHON_USE_TYPE_SPECS 0
      76             :   #undef CYTHON_USE_PYTYPE_LOOKUP
      77             :   #define CYTHON_USE_PYTYPE_LOOKUP 0
      78             :   #if PY_VERSION_HEX < 0x03050000
      79             :     #undef CYTHON_USE_ASYNC_SLOTS
      80             :     #define CYTHON_USE_ASYNC_SLOTS 0
      81             :   #elif !defined(CYTHON_USE_ASYNC_SLOTS)
      82             :     #define CYTHON_USE_ASYNC_SLOTS 1
      83             :   #endif
      84             :   #undef CYTHON_USE_PYLIST_INTERNALS
      85             :   #define CYTHON_USE_PYLIST_INTERNALS 0
      86             :   #undef CYTHON_USE_UNICODE_INTERNALS
      87             :   #define CYTHON_USE_UNICODE_INTERNALS 0
      88             :   #undef CYTHON_USE_UNICODE_WRITER
      89             :   #define CYTHON_USE_UNICODE_WRITER 0
      90             :   #undef CYTHON_USE_PYLONG_INTERNALS
      91             :   #define CYTHON_USE_PYLONG_INTERNALS 0
      92             :   #undef CYTHON_AVOID_BORROWED_REFS
      93             :   #define CYTHON_AVOID_BORROWED_REFS 1
      94             :   #undef CYTHON_ASSUME_SAFE_MACROS
      95             :   #define CYTHON_ASSUME_SAFE_MACROS 0
      96             :   #undef CYTHON_UNPACK_METHODS
      97             :   #define CYTHON_UNPACK_METHODS 0
      98             :   #undef CYTHON_FAST_THREAD_STATE
      99             :   #define CYTHON_FAST_THREAD_STATE 0
     100             :   #undef CYTHON_FAST_GIL
     101             :   #define CYTHON_FAST_GIL 0
     102             :   #undef CYTHON_METH_FASTCALL
     103             :   #define CYTHON_METH_FASTCALL 0
     104             :   #undef CYTHON_FAST_PYCALL
     105             :   #define CYTHON_FAST_PYCALL 0
     106             :   #ifndef CYTHON_PEP487_INIT_SUBCLASS
     107             :     #define CYTHON_PEP487_INIT_SUBCLASS (PY_MAJOR_VERSION >= 3)
     108             :   #endif
     109             :   #undef CYTHON_PEP489_MULTI_PHASE_INIT
     110             :   #define CYTHON_PEP489_MULTI_PHASE_INIT 1
     111             :   #undef CYTHON_USE_MODULE_STATE
     112             :   #define CYTHON_USE_MODULE_STATE 0
     113             :   #undef CYTHON_USE_TP_FINALIZE
     114             :   #define CYTHON_USE_TP_FINALIZE 0
     115             :   #undef CYTHON_USE_DICT_VERSIONS
     116             :   #define CYTHON_USE_DICT_VERSIONS 0
     117             :   #undef CYTHON_USE_EXC_INFO_STACK
     118             :   #define CYTHON_USE_EXC_INFO_STACK 0
     119             :   #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
     120             :     #define CYTHON_UPDATE_DESCRIPTOR_DOC 0
     121             :   #endif
     122             :   #undef CYTHON_USE_FREELISTS
     123             :   #define CYTHON_USE_FREELISTS 0
     124             : #elif defined(PYPY_VERSION)
     125             :   #define CYTHON_COMPILING_IN_PYPY 1
     126             :   #define CYTHON_COMPILING_IN_CPYTHON 0
     127             :   #define CYTHON_COMPILING_IN_LIMITED_API 0
     128             :   #define CYTHON_COMPILING_IN_GRAAL 0
     129             :   #define CYTHON_COMPILING_IN_NOGIL 0
     130             :   #undef CYTHON_USE_TYPE_SLOTS
     131             :   #define CYTHON_USE_TYPE_SLOTS 0
     132             :   #ifndef CYTHON_USE_TYPE_SPECS
     133             :     #define CYTHON_USE_TYPE_SPECS 0
     134             :   #endif
     135             :   #undef CYTHON_USE_PYTYPE_LOOKUP
     136             :   #define CYTHON_USE_PYTYPE_LOOKUP 0
     137             :   #if PY_VERSION_HEX < 0x03050000
     138             :     #undef CYTHON_USE_ASYNC_SLOTS
     139             :     #define CYTHON_USE_ASYNC_SLOTS 0
     140             :   #elif !defined(CYTHON_USE_ASYNC_SLOTS)
     141             :     #define CYTHON_USE_ASYNC_SLOTS 1
     142             :   #endif
     143             :   #undef CYTHON_USE_PYLIST_INTERNALS
     144             :   #define CYTHON_USE_PYLIST_INTERNALS 0
     145             :   #undef CYTHON_USE_UNICODE_INTERNALS
     146             :   #define CYTHON_USE_UNICODE_INTERNALS 0
     147             :   #undef CYTHON_USE_UNICODE_WRITER
     148             :   #define CYTHON_USE_UNICODE_WRITER 0
     149             :   #undef CYTHON_USE_PYLONG_INTERNALS
     150             :   #define CYTHON_USE_PYLONG_INTERNALS 0
     151             :   #undef CYTHON_AVOID_BORROWED_REFS
     152             :   #define CYTHON_AVOID_BORROWED_REFS 1
     153             :   #undef CYTHON_ASSUME_SAFE_MACROS
     154             :   #define CYTHON_ASSUME_SAFE_MACROS 0
     155             :   #undef CYTHON_UNPACK_METHODS
     156             :   #define CYTHON_UNPACK_METHODS 0
     157             :   #undef CYTHON_FAST_THREAD_STATE
     158             :   #define CYTHON_FAST_THREAD_STATE 0
     159             :   #undef CYTHON_FAST_GIL
     160             :   #define CYTHON_FAST_GIL 0
     161             :   #undef CYTHON_METH_FASTCALL
     162             :   #define CYTHON_METH_FASTCALL 0
     163             :   #undef CYTHON_FAST_PYCALL
     164             :   #define CYTHON_FAST_PYCALL 0
     165             :   #ifndef CYTHON_PEP487_INIT_SUBCLASS
     166             :     #define CYTHON_PEP487_INIT_SUBCLASS (PY_MAJOR_VERSION >= 3)
     167             :   #endif
     168             :   #if PY_VERSION_HEX < 0x03090000
     169             :     #undef CYTHON_PEP489_MULTI_PHASE_INIT
     170             :     #define CYTHON_PEP489_MULTI_PHASE_INIT 0
     171             :   #elif !defined(CYTHON_PEP489_MULTI_PHASE_INIT)
     172             :     #define CYTHON_PEP489_MULTI_PHASE_INIT 1
     173             :   #endif
     174             :   #undef CYTHON_USE_MODULE_STATE
     175             :   #define CYTHON_USE_MODULE_STATE 0
     176             :   #undef CYTHON_USE_TP_FINALIZE
     177             :   #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1 && PYPY_VERSION_NUM >= 0x07030C00)
     178             :   #undef CYTHON_USE_DICT_VERSIONS
     179             :   #define CYTHON_USE_DICT_VERSIONS 0
     180             :   #undef CYTHON_USE_EXC_INFO_STACK
     181             :   #define CYTHON_USE_EXC_INFO_STACK 0
     182             :   #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
     183             :     #define CYTHON_UPDATE_DESCRIPTOR_DOC 0
     184             :   #endif
     185             :   #undef CYTHON_USE_FREELISTS
     186             :   #define CYTHON_USE_FREELISTS 0
     187             : #elif defined(CYTHON_LIMITED_API)
     188             :   #ifdef Py_LIMITED_API
     189             :     #undef __PYX_LIMITED_VERSION_HEX
     190             :     #define __PYX_LIMITED_VERSION_HEX Py_LIMITED_API
     191             :   #endif
     192             :   #define CYTHON_COMPILING_IN_PYPY 0
     193             :   #define CYTHON_COMPILING_IN_CPYTHON 0
     194             :   #define CYTHON_COMPILING_IN_LIMITED_API 1
     195             :   #define CYTHON_COMPILING_IN_GRAAL 0
     196             :   #define CYTHON_COMPILING_IN_NOGIL 0
     197             :   #undef CYTHON_CLINE_IN_TRACEBACK
     198             :   #define CYTHON_CLINE_IN_TRACEBACK 0
     199             :   #undef CYTHON_USE_TYPE_SLOTS
     200             :   #define CYTHON_USE_TYPE_SLOTS 0
     201             :   #undef CYTHON_USE_TYPE_SPECS
     202             :   #define CYTHON_USE_TYPE_SPECS 1
     203             :   #undef CYTHON_USE_PYTYPE_LOOKUP
     204             :   #define CYTHON_USE_PYTYPE_LOOKUP 0
     205             :   #undef CYTHON_USE_ASYNC_SLOTS
     206             :   #define CYTHON_USE_ASYNC_SLOTS 0
     207             :   #undef CYTHON_USE_PYLIST_INTERNALS
     208             :   #define CYTHON_USE_PYLIST_INTERNALS 0
     209             :   #undef CYTHON_USE_UNICODE_INTERNALS
     210             :   #define CYTHON_USE_UNICODE_INTERNALS 0
     211             :   #ifndef CYTHON_USE_UNICODE_WRITER
     212             :     #define CYTHON_USE_UNICODE_WRITER 0
     213             :   #endif
     214             :   #undef CYTHON_USE_PYLONG_INTERNALS
     215             :   #define CYTHON_USE_PYLONG_INTERNALS 0
     216             :   #ifndef CYTHON_AVOID_BORROWED_REFS
     217             :     #define CYTHON_AVOID_BORROWED_REFS 0
     218             :   #endif
     219             :   #undef CYTHON_ASSUME_SAFE_MACROS
     220             :   #define CYTHON_ASSUME_SAFE_MACROS 0
     221             :   #undef CYTHON_UNPACK_METHODS
     222             :   #define CYTHON_UNPACK_METHODS 0
     223             :   #undef CYTHON_FAST_THREAD_STATE
     224             :   #define CYTHON_FAST_THREAD_STATE 0
     225             :   #undef CYTHON_FAST_GIL
     226             :   #define CYTHON_FAST_GIL 0
     227             :   #undef CYTHON_METH_FASTCALL
     228             :   #define CYTHON_METH_FASTCALL 0
     229             :   #undef CYTHON_FAST_PYCALL
     230             :   #define CYTHON_FAST_PYCALL 0
     231             :   #ifndef CYTHON_PEP487_INIT_SUBCLASS
     232             :     #define CYTHON_PEP487_INIT_SUBCLASS 1
     233             :   #endif
     234             :   #undef CYTHON_PEP489_MULTI_PHASE_INIT
     235             :   #define CYTHON_PEP489_MULTI_PHASE_INIT 0
     236             :   #undef CYTHON_USE_MODULE_STATE
     237             :   #define CYTHON_USE_MODULE_STATE 1
     238             :   #ifndef CYTHON_USE_TP_FINALIZE
     239             :     #define CYTHON_USE_TP_FINALIZE 0
     240             :   #endif
     241             :   #undef CYTHON_USE_DICT_VERSIONS
     242             :   #define CYTHON_USE_DICT_VERSIONS 0
     243             :   #undef CYTHON_USE_EXC_INFO_STACK
     244             :   #define CYTHON_USE_EXC_INFO_STACK 0
     245             :   #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
     246             :     #define CYTHON_UPDATE_DESCRIPTOR_DOC 0
     247             :   #endif
     248             :   #undef CYTHON_USE_FREELISTS
     249             :   #define CYTHON_USE_FREELISTS 0
     250             : #elif defined(Py_GIL_DISABLED) || defined(Py_NOGIL)
     251             :   #define CYTHON_COMPILING_IN_PYPY 0
     252             :   #define CYTHON_COMPILING_IN_CPYTHON 0
     253             :   #define CYTHON_COMPILING_IN_LIMITED_API 0
     254             :   #define CYTHON_COMPILING_IN_GRAAL 0
     255             :   #define CYTHON_COMPILING_IN_NOGIL 1
     256             :   #ifndef CYTHON_USE_TYPE_SLOTS
     257             :     #define CYTHON_USE_TYPE_SLOTS 1
     258             :   #endif
     259             :   #ifndef CYTHON_USE_TYPE_SPECS
     260             :     #define CYTHON_USE_TYPE_SPECS 0
     261             :   #endif
     262             :   #undef CYTHON_USE_PYTYPE_LOOKUP
     263             :   #define CYTHON_USE_PYTYPE_LOOKUP 0
     264             :   #ifndef CYTHON_USE_ASYNC_SLOTS
     265             :     #define CYTHON_USE_ASYNC_SLOTS 1
     266             :   #endif
     267             :   #ifndef CYTHON_USE_PYLONG_INTERNALS
     268             :     #define CYTHON_USE_PYLONG_INTERNALS 0
     269             :   #endif
     270             :   #undef CYTHON_USE_PYLIST_INTERNALS
     271             :   #define CYTHON_USE_PYLIST_INTERNALS 0
     272             :   #ifndef CYTHON_USE_UNICODE_INTERNALS
     273             :     #define CYTHON_USE_UNICODE_INTERNALS 1
     274             :   #endif
     275             :   #undef CYTHON_USE_UNICODE_WRITER
     276             :   #define CYTHON_USE_UNICODE_WRITER 0
     277             :   #ifndef CYTHON_AVOID_BORROWED_REFS
     278             :     #define CYTHON_AVOID_BORROWED_REFS 0
     279             :   #endif
     280             :   #ifndef CYTHON_ASSUME_SAFE_MACROS
     281             :     #define CYTHON_ASSUME_SAFE_MACROS 1
     282             :   #endif
     283             :   #ifndef CYTHON_UNPACK_METHODS
     284             :     #define CYTHON_UNPACK_METHODS 1
     285             :   #endif
     286             :   #undef CYTHON_FAST_THREAD_STATE
     287             :   #define CYTHON_FAST_THREAD_STATE 0
     288             :   #undef CYTHON_FAST_GIL
     289             :   #define CYTHON_FAST_GIL 0
     290             :   #ifndef CYTHON_METH_FASTCALL
     291             :     #define CYTHON_METH_FASTCALL 1
     292             :   #endif
     293             :   #undef CYTHON_FAST_PYCALL
     294             :   #define CYTHON_FAST_PYCALL 0
     295             :   #ifndef CYTHON_PEP487_INIT_SUBCLASS
     296             :     #define CYTHON_PEP487_INIT_SUBCLASS 1
     297             :   #endif
     298             :   #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
     299             :     #define CYTHON_PEP489_MULTI_PHASE_INIT 1
     300             :   #endif
     301             :   #ifndef CYTHON_USE_MODULE_STATE
     302             :     #define CYTHON_USE_MODULE_STATE 0
     303             :   #endif
     304             :   #ifndef CYTHON_USE_TP_FINALIZE
     305             :     #define CYTHON_USE_TP_FINALIZE 1
     306             :   #endif
     307             :   #undef CYTHON_USE_DICT_VERSIONS
     308             :   #define CYTHON_USE_DICT_VERSIONS 0
     309             :   #undef CYTHON_USE_EXC_INFO_STACK
     310             :   #define CYTHON_USE_EXC_INFO_STACK 0
     311             :   #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
     312             :     #define CYTHON_UPDATE_DESCRIPTOR_DOC 1
     313             :   #endif
     314             :   #ifndef CYTHON_USE_FREELISTS
     315             :     #define CYTHON_USE_FREELISTS 0
     316             :   #endif
     317             : #else
     318             :   #define CYTHON_COMPILING_IN_PYPY 0
     319             :   #define CYTHON_COMPILING_IN_CPYTHON 1
     320             :   #define CYTHON_COMPILING_IN_LIMITED_API 0
     321             :   #define CYTHON_COMPILING_IN_GRAAL 0
     322             :   #define CYTHON_COMPILING_IN_NOGIL 0
     323             :   #ifndef CYTHON_USE_TYPE_SLOTS
     324             :     #define CYTHON_USE_TYPE_SLOTS 1
     325             :   #endif
     326             :   #ifndef CYTHON_USE_TYPE_SPECS
     327             :     #define CYTHON_USE_TYPE_SPECS 0
     328             :   #endif
     329             :   #ifndef CYTHON_USE_PYTYPE_LOOKUP
     330             :     #define CYTHON_USE_PYTYPE_LOOKUP 1
     331             :   #endif
     332             :   #if PY_MAJOR_VERSION < 3
     333             :     #undef CYTHON_USE_ASYNC_SLOTS
     334             :     #define CYTHON_USE_ASYNC_SLOTS 0
     335             :   #elif !defined(CYTHON_USE_ASYNC_SLOTS)
     336             :     #define CYTHON_USE_ASYNC_SLOTS 1
     337             :   #endif
     338             :   #ifndef CYTHON_USE_PYLONG_INTERNALS
     339             :     #define CYTHON_USE_PYLONG_INTERNALS 1
     340             :   #endif
     341             :   #ifndef CYTHON_USE_PYLIST_INTERNALS
     342             :     #define CYTHON_USE_PYLIST_INTERNALS 1
     343             :   #endif
     344             :   #ifndef CYTHON_USE_UNICODE_INTERNALS
     345             :     #define CYTHON_USE_UNICODE_INTERNALS 1
     346             :   #endif
     347             :   #if PY_VERSION_HEX < 0x030300F0 || PY_VERSION_HEX >= 0x030B00A2
     348             :     #undef CYTHON_USE_UNICODE_WRITER
     349             :     #define CYTHON_USE_UNICODE_WRITER 0
     350             :   #elif !defined(CYTHON_USE_UNICODE_WRITER)
     351             :     #define CYTHON_USE_UNICODE_WRITER 1
     352             :   #endif
     353             :   #ifndef CYTHON_AVOID_BORROWED_REFS
     354             :     #define CYTHON_AVOID_BORROWED_REFS 0
     355             :   #endif
     356             :   #ifndef CYTHON_ASSUME_SAFE_MACROS
     357             :     #define CYTHON_ASSUME_SAFE_MACROS 1
     358             :   #endif
     359             :   #ifndef CYTHON_UNPACK_METHODS
     360             :     #define CYTHON_UNPACK_METHODS 1
     361             :   #endif
     362             :   #ifndef CYTHON_FAST_THREAD_STATE
     363             :     #define CYTHON_FAST_THREAD_STATE 1
     364             :   #endif
     365             :   #ifndef CYTHON_FAST_GIL
     366             :     #define CYTHON_FAST_GIL (PY_MAJOR_VERSION < 3 || PY_VERSION_HEX >= 0x03060000 && PY_VERSION_HEX < 0x030C00A6)
     367             :   #endif
     368             :   #ifndef CYTHON_METH_FASTCALL
     369             :     #define CYTHON_METH_FASTCALL (PY_VERSION_HEX >= 0x030700A1)
     370             :   #endif
     371             :   #ifndef CYTHON_FAST_PYCALL
     372             :     #define CYTHON_FAST_PYCALL 1
     373             :   #endif
     374             :   #ifndef CYTHON_PEP487_INIT_SUBCLASS
     375             :     #define CYTHON_PEP487_INIT_SUBCLASS 1
     376             :   #endif
     377             :   #if PY_VERSION_HEX < 0x03050000
     378             :     #undef CYTHON_PEP489_MULTI_PHASE_INIT
     379             :     #define CYTHON_PEP489_MULTI_PHASE_INIT 0
     380             :   #elif !defined(CYTHON_PEP489_MULTI_PHASE_INIT)
     381             :     #define CYTHON_PEP489_MULTI_PHASE_INIT 1
     382             :   #endif
     383             :   #ifndef CYTHON_USE_MODULE_STATE
     384             :     #define CYTHON_USE_MODULE_STATE 0
     385             :   #endif
     386             :   #if PY_VERSION_HEX < 0x030400a1
     387             :     #undef CYTHON_USE_TP_FINALIZE
     388             :     #define CYTHON_USE_TP_FINALIZE 0
     389             :   #elif !defined(CYTHON_USE_TP_FINALIZE)
     390             :     #define CYTHON_USE_TP_FINALIZE 1
     391             :   #endif
     392             :   #if PY_VERSION_HEX < 0x030600B1
     393             :     #undef CYTHON_USE_DICT_VERSIONS
     394             :     #define CYTHON_USE_DICT_VERSIONS 0
     395             :   #elif !defined(CYTHON_USE_DICT_VERSIONS)
     396             :     #define CYTHON_USE_DICT_VERSIONS  (PY_VERSION_HEX < 0x030C00A5)
     397             :   #endif
     398             :   #if PY_VERSION_HEX < 0x030700A3
     399             :     #undef CYTHON_USE_EXC_INFO_STACK
     400             :     #define CYTHON_USE_EXC_INFO_STACK 0
     401             :   #elif !defined(CYTHON_USE_EXC_INFO_STACK)
     402             :     #define CYTHON_USE_EXC_INFO_STACK 1
     403             :   #endif
     404             :   #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
     405             :     #define CYTHON_UPDATE_DESCRIPTOR_DOC 1
     406             :   #endif
     407             :   #ifndef CYTHON_USE_FREELISTS
     408             :     #define CYTHON_USE_FREELISTS 1
     409             :   #endif
     410             : #endif
     411             : #if !defined(CYTHON_FAST_PYCCALL)
     412             : #define CYTHON_FAST_PYCCALL  (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
     413             : #endif
     414             : #if !defined(CYTHON_VECTORCALL)
     415             : #define CYTHON_VECTORCALL  (CYTHON_FAST_PYCCALL && PY_VERSION_HEX >= 0x030800B1)
     416             : #endif
     417             : #define CYTHON_BACKPORT_VECTORCALL (CYTHON_METH_FASTCALL && PY_VERSION_HEX < 0x030800B1)
     418             : #if CYTHON_USE_PYLONG_INTERNALS
     419             :   #if PY_MAJOR_VERSION < 3
     420             :     #include "longintrepr.h"
     421             :   #endif
     422             :   #undef SHIFT
     423             :   #undef BASE
     424             :   #undef MASK
     425             :   #ifdef SIZEOF_VOID_P
     426             :     enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P == sizeof(void*)) };
     427             :   #endif
     428             : #endif
     429             : #ifndef __has_attribute
     430             :   #define __has_attribute(x) 0
     431             : #endif
     432             : #ifndef __has_cpp_attribute
     433             :   #define __has_cpp_attribute(x) 0
     434             : #endif
     435             : #ifndef CYTHON_RESTRICT
     436             :   #if defined(__GNUC__)
     437             :     #define CYTHON_RESTRICT __restrict__
     438             :   #elif defined(_MSC_VER) && _MSC_VER >= 1400
     439             :     #define CYTHON_RESTRICT __restrict
     440             :   #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
     441             :     #define CYTHON_RESTRICT restrict
     442             :   #else
     443             :     #define CYTHON_RESTRICT
     444             :   #endif
     445             : #endif
     446             : #ifndef CYTHON_UNUSED
     447             :   #if defined(__cplusplus)
     448             :     /* for clang __has_cpp_attribute(maybe_unused) is true even before C++17
     449             :      * but leads to warnings with -pedantic, since it is a C++17 feature */
     450             :     #if ((defined(_MSVC_LANG) && _MSVC_LANG >= 201703L) || __cplusplus >= 201703L)
     451             :       #if __has_cpp_attribute(maybe_unused)
     452             :         #define CYTHON_UNUSED [[maybe_unused]]
     453             :       #endif
     454             :     #endif
     455             :   #endif
     456             : #endif
     457             : #ifndef CYTHON_UNUSED
     458             : # if defined(__GNUC__)
     459             : #   if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
     460             : #     define CYTHON_UNUSED __attribute__ ((__unused__))
     461             : #   else
     462             : #     define CYTHON_UNUSED
     463             : #   endif
     464             : # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
     465             : #   define CYTHON_UNUSED __attribute__ ((__unused__))
     466             : # else
     467             : #   define CYTHON_UNUSED
     468             : # endif
     469             : #endif
     470             : #ifndef CYTHON_UNUSED_VAR
     471             : #  if defined(__cplusplus)
     472             :      template<class T> void CYTHON_UNUSED_VAR( const T& ) { }
     473             : #  else
     474             : #    define CYTHON_UNUSED_VAR(x) (void)(x)
     475             : #  endif
     476             : #endif
     477             : #ifndef CYTHON_MAYBE_UNUSED_VAR
     478             :   #define CYTHON_MAYBE_UNUSED_VAR(x) CYTHON_UNUSED_VAR(x)
     479             : #endif
     480             : #ifndef CYTHON_NCP_UNUSED
     481             : # if CYTHON_COMPILING_IN_CPYTHON
     482             : #  define CYTHON_NCP_UNUSED
     483             : # else
     484             : #  define CYTHON_NCP_UNUSED CYTHON_UNUSED
     485             : # endif
     486             : #endif
     487             : #ifndef CYTHON_USE_CPP_STD_MOVE
     488             :   #if defined(__cplusplus) && (\
     489             :     __cplusplus >= 201103L || (defined(_MSC_VER) && _MSC_VER >= 1600))
     490             :     #define CYTHON_USE_CPP_STD_MOVE 1
     491             :   #else
     492             :     #define CYTHON_USE_CPP_STD_MOVE 0
     493             :   #endif
     494             : #endif
     495             : #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
     496             : #ifdef _MSC_VER
     497             :     #ifndef _MSC_STDINT_H_
     498             :         #if _MSC_VER < 1300
     499             :             typedef unsigned char     uint8_t;
     500             :             typedef unsigned short    uint16_t;
     501             :             typedef unsigned int      uint32_t;
     502             :         #else
     503             :             typedef unsigned __int8   uint8_t;
     504             :             typedef unsigned __int16  uint16_t;
     505             :             typedef unsigned __int32  uint32_t;
     506             :         #endif
     507             :     #endif
     508             :     #if _MSC_VER < 1300
     509             :         #ifdef _WIN64
     510             :             typedef unsigned long long  __pyx_uintptr_t;
     511             :         #else
     512             :             typedef unsigned int        __pyx_uintptr_t;
     513             :         #endif
     514             :     #else
     515             :         #ifdef _WIN64
     516             :             typedef unsigned __int64    __pyx_uintptr_t;
     517             :         #else
     518             :             typedef unsigned __int32    __pyx_uintptr_t;
     519             :         #endif
     520             :     #endif
     521             : #else
     522             :     #include <stdint.h>
     523             :     typedef uintptr_t  __pyx_uintptr_t;
     524             : #endif
     525             : #ifndef CYTHON_FALLTHROUGH
     526             :   #if defined(__cplusplus)
     527             :     /* for clang __has_cpp_attribute(fallthrough) is true even before C++17
     528             :      * but leads to warnings with -pedantic, since it is a C++17 feature */
     529             :     #if ((defined(_MSVC_LANG) && _MSVC_LANG >= 201703L) || __cplusplus >= 201703L)
     530             :       #if __has_cpp_attribute(fallthrough)
     531             :         #define CYTHON_FALLTHROUGH [[fallthrough]]
     532             :       #endif
     533             :     #endif
     534             :     #ifndef CYTHON_FALLTHROUGH
     535             :       #if __has_cpp_attribute(clang::fallthrough)
     536             :         #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
     537             :       #elif __has_cpp_attribute(gnu::fallthrough)
     538             :         #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
     539             :       #endif
     540             :     #endif
     541             :   #endif
     542             :   #ifndef CYTHON_FALLTHROUGH
     543             :     #if __has_attribute(fallthrough)
     544             :       #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
     545             :     #else
     546             :       #define CYTHON_FALLTHROUGH
     547             :     #endif
     548             :   #endif
     549             :   #if defined(__clang__) && defined(__apple_build_version__)
     550             :     #if __apple_build_version__ < 7000000
     551             :       #undef  CYTHON_FALLTHROUGH
     552             :       #define CYTHON_FALLTHROUGH
     553             :     #endif
     554             :   #endif
     555             : #endif
     556             : #ifdef __cplusplus
     557             :   template <typename T>
     558             :   struct __PYX_IS_UNSIGNED_IMPL {static const bool value = T(0) < T(-1);};
     559             :   #define __PYX_IS_UNSIGNED(type) (__PYX_IS_UNSIGNED_IMPL<type>::value)
     560             : #else
     561             :   #define __PYX_IS_UNSIGNED(type) (((type)-1) > 0)
     562             : #endif
     563             : #if CYTHON_COMPILING_IN_PYPY == 1
     564             :   #define __PYX_NEED_TP_PRINT_SLOT  (PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x030A0000)
     565             : #else
     566             :   #define __PYX_NEED_TP_PRINT_SLOT  (PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000)
     567             : #endif
     568             : #define __PYX_REINTERPRET_FUNCION(func_pointer, other_pointer) ((func_pointer)(void(*)(void))(other_pointer))
     569             : 
     570             : #ifndef CYTHON_INLINE
     571             :   #if defined(__clang__)
     572             :     #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
     573             :   #elif defined(__GNUC__)
     574             :     #define CYTHON_INLINE __inline__
     575             :   #elif defined(_MSC_VER)
     576             :     #define CYTHON_INLINE __inline
     577             :   #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
     578             :     #define CYTHON_INLINE inline
     579             :   #else
     580             :     #define CYTHON_INLINE
     581             :   #endif
     582             : #endif
     583             : 
     584             : #define __PYX_BUILD_PY_SSIZE_T "n"
     585             : #define CYTHON_FORMAT_SSIZE_T "z"
     586             : #if PY_MAJOR_VERSION < 3
     587             :   #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
     588             :   #define __Pyx_DefaultClassType PyClass_Type
     589             :   #define __Pyx_PyCode_New(a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
     590             :           PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
     591             : #else
     592             :   #define __Pyx_BUILTIN_MODULE_NAME "builtins"
     593             :   #define __Pyx_DefaultClassType PyType_Type
     594             : #if CYTHON_COMPILING_IN_LIMITED_API
     595             :     static CYTHON_INLINE PyObject* __Pyx_PyCode_New(int a, int p, int k, int l, int s, int f,
     596             :                                                     PyObject *code, PyObject *c, PyObject* n, PyObject *v,
     597             :                                                     PyObject *fv, PyObject *cell, PyObject* fn,
     598             :                                                     PyObject *name, int fline, PyObject *lnos) {
     599             :         PyObject *exception_table = NULL;
     600             :         PyObject *types_module=NULL, *code_type=NULL, *result=NULL;
     601             :         #if __PYX_LIMITED_VERSION_HEX < 0x030B0000
     602             :         PyObject *version_info;
     603             :         PyObject *py_minor_version = NULL;
     604             :         #endif
     605             :         long minor_version = 0;
     606             :         PyObject *type, *value, *traceback;
     607             :         PyErr_Fetch(&type, &value, &traceback);
     608             :         #if __PYX_LIMITED_VERSION_HEX >= 0x030B0000
     609             :         minor_version = 11;
     610             :         #else
     611             :         if (!(version_info = PySys_GetObject("version_info"))) goto end;
     612             :         if (!(py_minor_version = PySequence_GetItem(version_info, 1))) goto end;
     613             :         minor_version = PyLong_AsLong(py_minor_version);
     614             :         Py_DECREF(py_minor_version);
     615             :         if (minor_version == -1 && PyErr_Occurred()) goto end;
     616             :         #endif
     617             :         if (!(types_module = PyImport_ImportModule("types"))) goto end;
     618             :         if (!(code_type = PyObject_GetAttrString(types_module, "CodeType"))) goto end;
     619             :         if (minor_version <= 7) {
     620             :             (void)p;
     621             :             result = PyObject_CallFunction(code_type, "iiiiiOOOOOOiOO", a, k, l, s, f, code,
     622             :                           c, n, v, fn, name, fline, lnos, fv, cell);
     623             :         } else if (minor_version <= 10) {
     624             :             result = PyObject_CallFunction(code_type, "iiiiiiOOOOOOiOO", a,p, k, l, s, f, code,
     625             :                           c, n, v, fn, name, fline, lnos, fv, cell);
     626             :         } else {
     627             :             if (!(exception_table = PyBytes_FromStringAndSize(NULL, 0))) goto end;
     628             :             result = PyObject_CallFunction(code_type, "iiiiiiOOOOOOOiOO", a,p, k, l, s, f, code,
     629             :                           c, n, v, fn, name, name, fline, lnos, exception_table, fv, cell);
     630             :         }
     631             :     end:
     632             :         Py_XDECREF(code_type);
     633             :         Py_XDECREF(exception_table);
     634             :         Py_XDECREF(types_module);
     635             :         if (type) {
     636             :             PyErr_Restore(type, value, traceback);
     637             :         }
     638             :         return result;
     639             :     }
     640             :     #ifndef CO_OPTIMIZED
     641             :     #define CO_OPTIMIZED 0x0001
     642             :     #endif
     643             :     #ifndef CO_NEWLOCALS
     644             :     #define CO_NEWLOCALS 0x0002
     645             :     #endif
     646             :     #ifndef CO_VARARGS
     647             :     #define CO_VARARGS 0x0004
     648             :     #endif
     649             :     #ifndef CO_VARKEYWORDS
     650             :     #define CO_VARKEYWORDS 0x0008
     651             :     #endif
     652             :     #ifndef CO_ASYNC_GENERATOR
     653             :     #define CO_ASYNC_GENERATOR 0x0200
     654             :     #endif
     655             :     #ifndef CO_GENERATOR
     656             :     #define CO_GENERATOR 0x0020
     657             :     #endif
     658             :     #ifndef CO_COROUTINE
     659             :     #define CO_COROUTINE 0x0080
     660             :     #endif
     661             : #elif PY_VERSION_HEX >= 0x030B0000
     662          15 :   static CYTHON_INLINE PyCodeObject* __Pyx_PyCode_New(int a, int p, int k, int l, int s, int f,
     663             :                                                     PyObject *code, PyObject *c, PyObject* n, PyObject *v,
     664             :                                                     PyObject *fv, PyObject *cell, PyObject* fn,
     665             :                                                     PyObject *name, int fline, PyObject *lnos) {
     666          15 :     PyCodeObject *result;
     667          15 :     PyObject *empty_bytes = PyBytes_FromStringAndSize("", 0);
     668          15 :     if (!empty_bytes) return NULL;
     669          15 :     result =
     670             :       #if PY_VERSION_HEX >= 0x030C0000
     671          15 :         PyUnstable_Code_NewWithPosOnlyArgs
     672             :       #else
     673             :         PyCode_NewWithPosOnlyArgs
     674             :       #endif
     675             :         (a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, name, fline, lnos, empty_bytes);
     676          15 :     Py_DECREF(empty_bytes);
     677             :     return result;
     678             :   }
     679             : #elif PY_VERSION_HEX >= 0x030800B2 && !CYTHON_COMPILING_IN_PYPY
     680             :   #define __Pyx_PyCode_New(a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
     681             :           PyCode_NewWithPosOnlyArgs(a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
     682             : #else
     683             :   #define __Pyx_PyCode_New(a, p, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
     684             :           PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
     685             : #endif
     686             : #endif
     687             : #if PY_VERSION_HEX >= 0x030900A4 || defined(Py_IS_TYPE)
     688             :   #define __Pyx_IS_TYPE(ob, type) Py_IS_TYPE(ob, type)
     689             : #else
     690             :   #define __Pyx_IS_TYPE(ob, type) (((const PyObject*)ob)->ob_type == (type))
     691             : #endif
     692             : #if PY_VERSION_HEX >= 0x030A00B1 || defined(Py_Is)
     693             :   #define __Pyx_Py_Is(x, y)  Py_Is(x, y)
     694             : #else
     695             :   #define __Pyx_Py_Is(x, y) ((x) == (y))
     696             : #endif
     697             : #if PY_VERSION_HEX >= 0x030A00B1 || defined(Py_IsNone)
     698             :   #define __Pyx_Py_IsNone(ob) Py_IsNone(ob)
     699             : #else
     700             :   #define __Pyx_Py_IsNone(ob) __Pyx_Py_Is((ob), Py_None)
     701             : #endif
     702             : #if PY_VERSION_HEX >= 0x030A00B1 || defined(Py_IsTrue)
     703             :   #define __Pyx_Py_IsTrue(ob) Py_IsTrue(ob)
     704             : #else
     705             :   #define __Pyx_Py_IsTrue(ob) __Pyx_Py_Is((ob), Py_True)
     706             : #endif
     707             : #if PY_VERSION_HEX >= 0x030A00B1 || defined(Py_IsFalse)
     708             :   #define __Pyx_Py_IsFalse(ob) Py_IsFalse(ob)
     709             : #else
     710             :   #define __Pyx_Py_IsFalse(ob) __Pyx_Py_Is((ob), Py_False)
     711             : #endif
     712             : #define __Pyx_NoneAsNull(obj)  (__Pyx_Py_IsNone(obj) ? NULL : (obj))
     713             : #if PY_VERSION_HEX >= 0x030900F0 && !CYTHON_COMPILING_IN_PYPY
     714             :   #define __Pyx_PyObject_GC_IsFinalized(o) PyObject_GC_IsFinalized(o)
     715             : #else
     716             :   #define __Pyx_PyObject_GC_IsFinalized(o) _PyGC_FINALIZED(o)
     717             : #endif
     718             : #ifndef CO_COROUTINE
     719             :   #define CO_COROUTINE 0x80
     720             : #endif
     721             : #ifndef CO_ASYNC_GENERATOR
     722             :   #define CO_ASYNC_GENERATOR 0x200
     723             : #endif
     724             : #ifndef Py_TPFLAGS_CHECKTYPES
     725             :   #define Py_TPFLAGS_CHECKTYPES 0
     726             : #endif
     727             : #ifndef Py_TPFLAGS_HAVE_INDEX
     728             :   #define Py_TPFLAGS_HAVE_INDEX 0
     729             : #endif
     730             : #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
     731             :   #define Py_TPFLAGS_HAVE_NEWBUFFER 0
     732             : #endif
     733             : #ifndef Py_TPFLAGS_HAVE_FINALIZE
     734             :   #define Py_TPFLAGS_HAVE_FINALIZE 0
     735             : #endif
     736             : #ifndef Py_TPFLAGS_SEQUENCE
     737             :   #define Py_TPFLAGS_SEQUENCE 0
     738             : #endif
     739             : #ifndef Py_TPFLAGS_MAPPING
     740             :   #define Py_TPFLAGS_MAPPING 0
     741             : #endif
     742             : #ifndef METH_STACKLESS
     743             :   #define METH_STACKLESS 0
     744             : #endif
     745             : #if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
     746             :   #ifndef METH_FASTCALL
     747             :      #define METH_FASTCALL 0x80
     748             :   #endif
     749             :   typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *self, PyObject *const *args, Py_ssize_t nargs);
     750             :   typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *self, PyObject *const *args,
     751             :                                                           Py_ssize_t nargs, PyObject *kwnames);
     752             : #else
     753             :   #if PY_VERSION_HEX >= 0x030d00A4
     754             :   #  define __Pyx_PyCFunctionFast PyCFunctionFast
     755             :   #  define __Pyx_PyCFunctionFastWithKeywords PyCFunctionFastWithKeywords
     756             :   #else
     757             :   #  define __Pyx_PyCFunctionFast _PyCFunctionFast
     758             :   #  define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
     759             :   #endif
     760             : #endif
     761             : #if CYTHON_METH_FASTCALL
     762             :   #define __Pyx_METH_FASTCALL METH_FASTCALL
     763             :   #define __Pyx_PyCFunction_FastCall __Pyx_PyCFunctionFast
     764             :   #define __Pyx_PyCFunction_FastCallWithKeywords __Pyx_PyCFunctionFastWithKeywords
     765             : #else
     766             :   #define __Pyx_METH_FASTCALL METH_VARARGS
     767             :   #define __Pyx_PyCFunction_FastCall PyCFunction
     768             :   #define __Pyx_PyCFunction_FastCallWithKeywords PyCFunctionWithKeywords
     769             : #endif
     770             : #if CYTHON_VECTORCALL
     771             :   #define __pyx_vectorcallfunc vectorcallfunc
     772             :   #define __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET  PY_VECTORCALL_ARGUMENTS_OFFSET
     773             :   #define __Pyx_PyVectorcall_NARGS(n)  PyVectorcall_NARGS((size_t)(n))
     774             : #elif CYTHON_BACKPORT_VECTORCALL
     775             :   typedef PyObject *(*__pyx_vectorcallfunc)(PyObject *callable, PyObject *const *args,
     776             :                                             size_t nargsf, PyObject *kwnames);
     777             :   #define __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET  ((size_t)1 << (8 * sizeof(size_t) - 1))
     778             :   #define __Pyx_PyVectorcall_NARGS(n)  ((Py_ssize_t)(((size_t)(n)) & ~__Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET))
     779             : #else
     780             :   #define __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET  0
     781             :   #define __Pyx_PyVectorcall_NARGS(n)  ((Py_ssize_t)(n))
     782             : #endif
     783             : #if PY_MAJOR_VERSION >= 0x030900B1
     784             : #define __Pyx_PyCFunction_CheckExact(func)  PyCFunction_CheckExact(func)
     785             : #else
     786             : #define __Pyx_PyCFunction_CheckExact(func)  PyCFunction_Check(func)
     787             : #endif
     788             : #define __Pyx_CyOrPyCFunction_Check(func)  PyCFunction_Check(func)
     789             : #if CYTHON_COMPILING_IN_CPYTHON
     790             : #define __Pyx_CyOrPyCFunction_GET_FUNCTION(func)  (((PyCFunctionObject*)(func))->m_ml->ml_meth)
     791             : #elif !CYTHON_COMPILING_IN_LIMITED_API
     792             : #define __Pyx_CyOrPyCFunction_GET_FUNCTION(func)  PyCFunction_GET_FUNCTION(func)
     793             : #endif
     794             : #if CYTHON_COMPILING_IN_CPYTHON
     795             : #define __Pyx_CyOrPyCFunction_GET_FLAGS(func)  (((PyCFunctionObject*)(func))->m_ml->ml_flags)
     796           0 : static CYTHON_INLINE PyObject* __Pyx_CyOrPyCFunction_GET_SELF(PyObject *func) {
     797           0 :     return (__Pyx_CyOrPyCFunction_GET_FLAGS(func) & METH_STATIC) ? NULL : ((PyCFunctionObject*)func)->m_self;
     798             : }
     799             : #endif
     800             : static CYTHON_INLINE int __Pyx__IsSameCFunction(PyObject *func, void *cfunc) {
     801             : #if CYTHON_COMPILING_IN_LIMITED_API
     802             :     return PyCFunction_Check(func) && PyCFunction_GetFunction(func) == (PyCFunction) cfunc;
     803             : #else
     804             :     return PyCFunction_Check(func) && PyCFunction_GET_FUNCTION(func) == (PyCFunction) cfunc;
     805             : #endif
     806             : }
     807             : #define __Pyx_IsSameCFunction(func, cfunc)   __Pyx__IsSameCFunction(func, cfunc)
     808             : #if __PYX_LIMITED_VERSION_HEX < 0x030900B1
     809             :   #define __Pyx_PyType_FromModuleAndSpec(m, s, b)  ((void)m, PyType_FromSpecWithBases(s, b))
     810             :   typedef PyObject *(*__Pyx_PyCMethod)(PyObject *, PyTypeObject *, PyObject *const *, size_t, PyObject *);
     811             : #else
     812             :   #define __Pyx_PyType_FromModuleAndSpec(m, s, b)  PyType_FromModuleAndSpec(m, s, b)
     813             :   #define __Pyx_PyCMethod  PyCMethod
     814             : #endif
     815             : #ifndef METH_METHOD
     816             :   #define METH_METHOD 0x200
     817             : #endif
     818             : #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
     819             :   #define PyObject_Malloc(s)   PyMem_Malloc(s)
     820             :   #define PyObject_Free(p)     PyMem_Free(p)
     821             :   #define PyObject_Realloc(p)  PyMem_Realloc(p)
     822             : #endif
     823             : #if CYTHON_COMPILING_IN_LIMITED_API
     824             :   #define __Pyx_PyCode_HasFreeVars(co)  (PyCode_GetNumFree(co) > 0)
     825             :   #define __Pyx_PyFrame_SetLineNumber(frame, lineno)
     826             : #else
     827             :   #define __Pyx_PyCode_HasFreeVars(co)  (PyCode_GetNumFree(co) > 0)
     828             :   #define __Pyx_PyFrame_SetLineNumber(frame, lineno)  (frame)->f_lineno = (lineno)
     829             : #endif
     830             : #if CYTHON_COMPILING_IN_LIMITED_API
     831             :   #define __Pyx_PyThreadState_Current PyThreadState_Get()
     832             : #elif !CYTHON_FAST_THREAD_STATE
     833             :   #define __Pyx_PyThreadState_Current PyThreadState_GET()
     834             : #elif PY_VERSION_HEX >= 0x030d00A1
     835             :   #define __Pyx_PyThreadState_Current PyThreadState_GetUnchecked()
     836             : #elif PY_VERSION_HEX >= 0x03060000
     837             :   #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
     838             : #elif PY_VERSION_HEX >= 0x03000000
     839             :   #define __Pyx_PyThreadState_Current PyThreadState_GET()
     840             : #else
     841             :   #define __Pyx_PyThreadState_Current _PyThreadState_Current
     842             : #endif
     843             : #if CYTHON_COMPILING_IN_LIMITED_API
     844             : static CYTHON_INLINE void *__Pyx_PyModule_GetState(PyObject *op)
     845             : {
     846             :     void *result;
     847             :     result = PyModule_GetState(op);
     848             :     if (!result)
     849             :         Py_FatalError("Couldn't find the module state");
     850             :     return result;
     851             : }
     852             : #endif
     853             : #define __Pyx_PyObject_GetSlot(obj, name, func_ctype)  __Pyx_PyType_GetSlot(Py_TYPE(obj), name, func_ctype)
     854             : #if CYTHON_COMPILING_IN_LIMITED_API
     855             :   #define __Pyx_PyType_GetSlot(type, name, func_ctype)  ((func_ctype) PyType_GetSlot((type), Py_##name))
     856             : #else
     857             :   #define __Pyx_PyType_GetSlot(type, name, func_ctype)  ((type)->name)
     858             : #endif
     859             : #if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
     860             : #include "pythread.h"
     861             : #define Py_tss_NEEDS_INIT 0
     862             : typedef int Py_tss_t;
     863             : static CYTHON_INLINE int PyThread_tss_create(Py_tss_t *key) {
     864             :   *key = PyThread_create_key();
     865             :   return 0;
     866             : }
     867             : static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(void) {
     868             :   Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(sizeof(Py_tss_t));
     869             :   *key = Py_tss_NEEDS_INIT;
     870             :   return key;
     871             : }
     872             : static CYTHON_INLINE void PyThread_tss_free(Py_tss_t *key) {
     873             :   PyObject_Free(key);
     874             : }
     875             : static CYTHON_INLINE int PyThread_tss_is_created(Py_tss_t *key) {
     876             :   return *key != Py_tss_NEEDS_INIT;
     877             : }
     878             : static CYTHON_INLINE void PyThread_tss_delete(Py_tss_t *key) {
     879             :   PyThread_delete_key(*key);
     880             :   *key = Py_tss_NEEDS_INIT;
     881             : }
     882             : static CYTHON_INLINE int PyThread_tss_set(Py_tss_t *key, void *value) {
     883             :   return PyThread_set_key_value(*key, value);
     884             : }
     885             : static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
     886             :   return PyThread_get_key_value(*key);
     887             : }
     888             : #endif
     889             : #if PY_MAJOR_VERSION < 3
     890             :     #if CYTHON_COMPILING_IN_PYPY
     891             :         #if PYPY_VERSION_NUM < 0x07030600
     892             :             #if defined(__cplusplus) && __cplusplus >= 201402L
     893             :                 [[deprecated("`with nogil:` inside a nogil function will not release the GIL in PyPy2 < 7.3.6")]]
     894             :             #elif defined(__GNUC__) || defined(__clang__)
     895             :                 __attribute__ ((__deprecated__("`with nogil:` inside a nogil function will not release the GIL in PyPy2 < 7.3.6")))
     896             :             #elif defined(_MSC_VER)
     897             :                 __declspec(deprecated("`with nogil:` inside a nogil function will not release the GIL in PyPy2 < 7.3.6"))
     898             :             #endif
     899             :             static CYTHON_INLINE int PyGILState_Check(void) {
     900             :                 return 0;
     901             :             }
     902             :         #else  // PYPY_VERSION_NUM < 0x07030600
     903             :         #endif  // PYPY_VERSION_NUM < 0x07030600
     904             :     #else
     905             :         static CYTHON_INLINE int PyGILState_Check(void) {
     906             :             PyThreadState * tstate = _PyThreadState_Current;
     907             :             return tstate && (tstate == PyGILState_GetThisThreadState());
     908             :         }
     909             :     #endif
     910             : #endif
     911             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030d0000 || defined(_PyDict_NewPresized)
     912             : #define __Pyx_PyDict_NewPresized(n)  ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
     913             : #else
     914             : #define __Pyx_PyDict_NewPresized(n)  PyDict_New()
     915             : #endif
     916             : #if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
     917             :   #define __Pyx_PyNumber_Divide(x,y)         PyNumber_TrueDivide(x,y)
     918             :   #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceTrueDivide(x,y)
     919             : #else
     920             :   #define __Pyx_PyNumber_Divide(x,y)         PyNumber_Divide(x,y)
     921             :   #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceDivide(x,y)
     922             : #endif
     923             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX > 0x030600B4 && PY_VERSION_HEX < 0x030d0000 && CYTHON_USE_UNICODE_INTERNALS
     924             : #define __Pyx_PyDict_GetItemStrWithError(dict, name)  _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
     925           0 : static CYTHON_INLINE PyObject * __Pyx_PyDict_GetItemStr(PyObject *dict, PyObject *name) {
     926           0 :     PyObject *res = __Pyx_PyDict_GetItemStrWithError(dict, name);
     927           0 :     if (res == NULL) PyErr_Clear();
     928           0 :     return res;
     929             : }
     930             : #elif PY_MAJOR_VERSION >= 3 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07020000)
     931             : #define __Pyx_PyDict_GetItemStrWithError  PyDict_GetItemWithError
     932             : #define __Pyx_PyDict_GetItemStr           PyDict_GetItem
     933             : #else
     934             : static CYTHON_INLINE PyObject * __Pyx_PyDict_GetItemStrWithError(PyObject *dict, PyObject *name) {
     935             : #if CYTHON_COMPILING_IN_PYPY
     936             :     return PyDict_GetItem(dict, name);
     937             : #else
     938             :     PyDictEntry *ep;
     939             :     PyDictObject *mp = (PyDictObject*) dict;
     940             :     long hash = ((PyStringObject *) name)->ob_shash;
     941             :     assert(hash != -1);
     942             :     ep = (mp->ma_lookup)(mp, name, hash);
     943             :     if (ep == NULL) {
     944             :         return NULL;
     945             :     }
     946             :     return ep->me_value;
     947             : #endif
     948             : }
     949             : #define __Pyx_PyDict_GetItemStr           PyDict_GetItem
     950             : #endif
     951             : #if CYTHON_USE_TYPE_SLOTS
     952             :   #define __Pyx_PyType_GetFlags(tp)   (((PyTypeObject *)tp)->tp_flags)
     953             :   #define __Pyx_PyType_HasFeature(type, feature)  ((__Pyx_PyType_GetFlags(type) & (feature)) != 0)
     954             :   #define __Pyx_PyObject_GetIterNextFunc(obj)  (Py_TYPE(obj)->tp_iternext)
     955             : #else
     956             :   #define __Pyx_PyType_GetFlags(tp)   (PyType_GetFlags((PyTypeObject *)tp))
     957             :   #define __Pyx_PyType_HasFeature(type, feature)  PyType_HasFeature(type, feature)
     958             :   #define __Pyx_PyObject_GetIterNextFunc(obj)  PyIter_Next
     959             : #endif
     960             : #if CYTHON_COMPILING_IN_LIMITED_API
     961             :   #define __Pyx_SetItemOnTypeDict(tp, k, v) PyObject_GenericSetAttr((PyObject*)tp, k, v)
     962             : #else
     963             :   #define __Pyx_SetItemOnTypeDict(tp, k, v) PyDict_SetItem(tp->tp_dict, k, v)
     964             : #endif
     965             : #if CYTHON_USE_TYPE_SPECS && PY_VERSION_HEX >= 0x03080000
     966             : #define __Pyx_PyHeapTypeObject_GC_Del(obj)  {\
     967             :     PyTypeObject *type = Py_TYPE((PyObject*)obj);\
     968             :     assert(__Pyx_PyType_HasFeature(type, Py_TPFLAGS_HEAPTYPE));\
     969             :     PyObject_GC_Del(obj);\
     970             :     Py_DECREF(type);\
     971             : }
     972             : #else
     973             : #define __Pyx_PyHeapTypeObject_GC_Del(obj)  PyObject_GC_Del(obj)
     974             : #endif
     975             : #if CYTHON_COMPILING_IN_LIMITED_API
     976             :   #define CYTHON_PEP393_ENABLED 1
     977             :   #define __Pyx_PyUnicode_READY(op)       (0)
     978             :   #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GetLength(u)
     979             :   #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_ReadChar(u, i)
     980             :   #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u)   ((void)u, 1114111U)
     981             :   #define __Pyx_PyUnicode_KIND(u)         ((void)u, (0))
     982             :   #define __Pyx_PyUnicode_DATA(u)         ((void*)u)
     983             :   #define __Pyx_PyUnicode_READ(k, d, i)   ((void)k, PyUnicode_ReadChar((PyObject*)(d), i))
     984             :   #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GetLength(u))
     985             : #elif PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
     986             :   #define CYTHON_PEP393_ENABLED 1
     987             :   #if PY_VERSION_HEX >= 0x030C0000
     988             :     #define __Pyx_PyUnicode_READY(op)       (0)
     989             :   #else
     990             :     #define __Pyx_PyUnicode_READY(op)       (likely(PyUnicode_IS_READY(op)) ?\
     991             :                                                 0 : _PyUnicode_Ready((PyObject *)(op)))
     992             :   #endif
     993             :   #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_LENGTH(u)
     994             :   #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
     995             :   #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u)   PyUnicode_MAX_CHAR_VALUE(u)
     996             :   #define __Pyx_PyUnicode_KIND(u)         ((int)PyUnicode_KIND(u))
     997             :   #define __Pyx_PyUnicode_DATA(u)         PyUnicode_DATA(u)
     998             :   #define __Pyx_PyUnicode_READ(k, d, i)   PyUnicode_READ(k, d, i)
     999             :   #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  PyUnicode_WRITE(k, d, i, (Py_UCS4) ch)
    1000             :   #if PY_VERSION_HEX >= 0x030C0000
    1001             :     #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GET_LENGTH(u))
    1002             :   #else
    1003             :     #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x03090000
    1004             :     #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : ((PyCompactUnicodeObject *)(u))->wstr_length))
    1005             :     #else
    1006             :     #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
    1007             :     #endif
    1008             :   #endif
    1009             : #else
    1010             :   #define CYTHON_PEP393_ENABLED 0
    1011             :   #define PyUnicode_1BYTE_KIND  1
    1012             :   #define PyUnicode_2BYTE_KIND  2
    1013             :   #define PyUnicode_4BYTE_KIND  4
    1014             :   #define __Pyx_PyUnicode_READY(op)       (0)
    1015             :   #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_SIZE(u)
    1016             :   #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
    1017             :   #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u)   ((sizeof(Py_UNICODE) == 2) ? 65535U : 1114111U)
    1018             :   #define __Pyx_PyUnicode_KIND(u)         ((int)sizeof(Py_UNICODE))
    1019             :   #define __Pyx_PyUnicode_DATA(u)         ((void*)PyUnicode_AS_UNICODE(u))
    1020             :   #define __Pyx_PyUnicode_READ(k, d, i)   ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
    1021             :   #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  (((void)(k)), ((Py_UNICODE*)d)[i] = (Py_UNICODE) ch)
    1022             :   #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GET_SIZE(u))
    1023             : #endif
    1024             : #if CYTHON_COMPILING_IN_PYPY
    1025             :   #define __Pyx_PyUnicode_Concat(a, b)      PyNumber_Add(a, b)
    1026             :   #define __Pyx_PyUnicode_ConcatSafe(a, b)  PyNumber_Add(a, b)
    1027             : #else
    1028             :   #define __Pyx_PyUnicode_Concat(a, b)      PyUnicode_Concat(a, b)
    1029             :   #define __Pyx_PyUnicode_ConcatSafe(a, b)  ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
    1030             :       PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
    1031             : #endif
    1032             : #if CYTHON_COMPILING_IN_PYPY
    1033             :   #if !defined(PyUnicode_DecodeUnicodeEscape)
    1034             :     #define PyUnicode_DecodeUnicodeEscape(s, size, errors)  PyUnicode_Decode(s, size, "unicode_escape", errors)
    1035             :   #endif
    1036             :   #if !defined(PyUnicode_Contains) || (PY_MAJOR_VERSION == 2 && PYPY_VERSION_NUM < 0x07030500)
    1037             :     #undef PyUnicode_Contains
    1038             :     #define PyUnicode_Contains(u, s)  PySequence_Contains(u, s)
    1039             :   #endif
    1040             :   #if !defined(PyByteArray_Check)
    1041             :     #define PyByteArray_Check(obj)  PyObject_TypeCheck(obj, &PyByteArray_Type)
    1042             :   #endif
    1043             :   #if !defined(PyObject_Format)
    1044             :     #define PyObject_Format(obj, fmt)  PyObject_CallMethod(obj, "__format__", "O", fmt)
    1045             :   #endif
    1046             : #endif
    1047             : #define __Pyx_PyString_FormatSafe(a, b)   ((unlikely((a) == Py_None || (PyString_Check(b) && !PyString_CheckExact(b)))) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
    1048             : #define __Pyx_PyUnicode_FormatSafe(a, b)  ((unlikely((a) == Py_None || (PyUnicode_Check(b) && !PyUnicode_CheckExact(b)))) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
    1049             : #if PY_MAJOR_VERSION >= 3
    1050             :   #define __Pyx_PyString_Format(a, b)  PyUnicode_Format(a, b)
    1051             : #else
    1052             :   #define __Pyx_PyString_Format(a, b)  PyString_Format(a, b)
    1053             : #endif
    1054             : #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
    1055             :   #define PyObject_ASCII(o)            PyObject_Repr(o)
    1056             : #endif
    1057             : #if PY_MAJOR_VERSION >= 3
    1058             :   #define PyBaseString_Type            PyUnicode_Type
    1059             :   #define PyStringObject               PyUnicodeObject
    1060             :   #define PyString_Type                PyUnicode_Type
    1061             :   #define PyString_Check               PyUnicode_Check
    1062             :   #define PyString_CheckExact          PyUnicode_CheckExact
    1063             : #ifndef PyObject_Unicode
    1064             :   #define PyObject_Unicode             PyObject_Str
    1065             : #endif
    1066             : #endif
    1067             : #if PY_MAJOR_VERSION >= 3
    1068             :   #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
    1069             :   #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
    1070             : #else
    1071             :   #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
    1072             :   #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
    1073             : #endif
    1074             : #if CYTHON_COMPILING_IN_CPYTHON
    1075             :   #define __Pyx_PySequence_ListKeepNew(obj)\
    1076             :     (likely(PyList_CheckExact(obj) && Py_REFCNT(obj) == 1) ? __Pyx_NewRef(obj) : PySequence_List(obj))
    1077             : #else
    1078             :   #define __Pyx_PySequence_ListKeepNew(obj)  PySequence_List(obj)
    1079             : #endif
    1080             : #ifndef PySet_CheckExact
    1081             :   #define PySet_CheckExact(obj)        __Pyx_IS_TYPE(obj, &PySet_Type)
    1082             : #endif
    1083             : #if PY_VERSION_HEX >= 0x030900A4
    1084             :   #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj, refcnt)
    1085             :   #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj, size)
    1086             : #else
    1087             :   #define __Pyx_SET_REFCNT(obj, refcnt) Py_REFCNT(obj) = (refcnt)
    1088             :   #define __Pyx_SET_SIZE(obj, size) Py_SIZE(obj) = (size)
    1089             : #endif
    1090             : #if CYTHON_ASSUME_SAFE_MACROS
    1091             :   #define __Pyx_PySequence_ITEM(o, i) PySequence_ITEM(o, i)
    1092             :   #define __Pyx_PySequence_SIZE(seq)  Py_SIZE(seq)
    1093             :   #define __Pyx_PyTuple_SET_ITEM(o, i, v) (PyTuple_SET_ITEM(o, i, v), (0))
    1094             :   #define __Pyx_PyList_SET_ITEM(o, i, v) (PyList_SET_ITEM(o, i, v), (0))
    1095             :   #define __Pyx_PyTuple_GET_SIZE(o) PyTuple_GET_SIZE(o)
    1096             :   #define __Pyx_PyList_GET_SIZE(o) PyList_GET_SIZE(o)
    1097             :   #define __Pyx_PySet_GET_SIZE(o) PySet_GET_SIZE(o)
    1098             :   #define __Pyx_PyBytes_GET_SIZE(o) PyBytes_GET_SIZE(o)
    1099             :   #define __Pyx_PyByteArray_GET_SIZE(o) PyByteArray_GET_SIZE(o)
    1100             : #else
    1101             :   #define __Pyx_PySequence_ITEM(o, i) PySequence_GetItem(o, i)
    1102             :   #define __Pyx_PySequence_SIZE(seq)  PySequence_Size(seq)
    1103             :   #define __Pyx_PyTuple_SET_ITEM(o, i, v) PyTuple_SetItem(o, i, v)
    1104             :   #define __Pyx_PyList_SET_ITEM(o, i, v) PyList_SetItem(o, i, v)
    1105             :   #define __Pyx_PyTuple_GET_SIZE(o) PyTuple_Size(o)
    1106             :   #define __Pyx_PyList_GET_SIZE(o) PyList_Size(o)
    1107             :   #define __Pyx_PySet_GET_SIZE(o) PySet_Size(o)
    1108             :   #define __Pyx_PyBytes_GET_SIZE(o) PyBytes_Size(o)
    1109             :   #define __Pyx_PyByteArray_GET_SIZE(o) PyByteArray_Size(o)
    1110             : #endif
    1111             : #if __PYX_LIMITED_VERSION_HEX >= 0x030d00A1
    1112             :   #define __Pyx_PyImport_AddModuleRef(name) PyImport_AddModuleRef(name)
    1113             : #else
    1114          12 :   static CYTHON_INLINE PyObject *__Pyx_PyImport_AddModuleRef(const char *name) {
    1115          12 :       PyObject *module = PyImport_AddModule(name);
    1116          12 :       Py_XINCREF(module);
    1117          12 :       return module;
    1118             :   }
    1119             : #endif
    1120             : #if PY_MAJOR_VERSION >= 3
    1121             :   #define PyIntObject                  PyLongObject
    1122             :   #define PyInt_Type                   PyLong_Type
    1123             :   #define PyInt_Check(op)              PyLong_Check(op)
    1124             :   #define PyInt_CheckExact(op)         PyLong_CheckExact(op)
    1125             :   #define __Pyx_Py3Int_Check(op)       PyLong_Check(op)
    1126             :   #define __Pyx_Py3Int_CheckExact(op)  PyLong_CheckExact(op)
    1127             :   #define PyInt_FromString             PyLong_FromString
    1128             :   #define PyInt_FromUnicode            PyLong_FromUnicode
    1129             :   #define PyInt_FromLong               PyLong_FromLong
    1130             :   #define PyInt_FromSize_t             PyLong_FromSize_t
    1131             :   #define PyInt_FromSsize_t            PyLong_FromSsize_t
    1132             :   #define PyInt_AsLong                 PyLong_AsLong
    1133             :   #define PyInt_AS_LONG                PyLong_AS_LONG
    1134             :   #define PyInt_AsSsize_t              PyLong_AsSsize_t
    1135             :   #define PyInt_AsUnsignedLongMask     PyLong_AsUnsignedLongMask
    1136             :   #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
    1137             :   #define PyNumber_Int                 PyNumber_Long
    1138             : #else
    1139             :   #define __Pyx_Py3Int_Check(op)       (PyLong_Check(op) || PyInt_Check(op))
    1140             :   #define __Pyx_Py3Int_CheckExact(op)  (PyLong_CheckExact(op) || PyInt_CheckExact(op))
    1141             : #endif
    1142             : #if PY_MAJOR_VERSION >= 3
    1143             :   #define PyBoolObject                 PyLongObject
    1144             : #endif
    1145             : #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
    1146             :   #ifndef PyUnicode_InternFromString
    1147             :     #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
    1148             :   #endif
    1149             : #endif
    1150             : #if PY_VERSION_HEX < 0x030200A4
    1151             :   typedef long Py_hash_t;
    1152             :   #define __Pyx_PyInt_FromHash_t PyInt_FromLong
    1153             :   #define __Pyx_PyInt_AsHash_t   __Pyx_PyIndex_AsHash_t
    1154             : #else
    1155             :   #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
    1156             :   #define __Pyx_PyInt_AsHash_t   __Pyx_PyIndex_AsSsize_t
    1157             : #endif
    1158             : #if CYTHON_USE_ASYNC_SLOTS
    1159             :   #if PY_VERSION_HEX >= 0x030500B1
    1160             :     #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
    1161             :     #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
    1162             :   #else
    1163             :     #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
    1164             :   #endif
    1165             : #else
    1166             :   #define __Pyx_PyType_AsAsync(obj) NULL
    1167             : #endif
    1168             : #ifndef __Pyx_PyAsyncMethodsStruct
    1169             :     typedef struct {
    1170             :         unaryfunc am_await;
    1171             :         unaryfunc am_aiter;
    1172             :         unaryfunc am_anext;
    1173             :     } __Pyx_PyAsyncMethodsStruct;
    1174             : #endif
    1175             : 
    1176             : #if defined(_WIN32) || defined(WIN32) || defined(MS_WINDOWS)
    1177             :   #if !defined(_USE_MATH_DEFINES)
    1178             :     #define _USE_MATH_DEFINES
    1179             :   #endif
    1180             : #endif
    1181             : #include <math.h>
    1182             : #ifdef NAN
    1183             : #define __PYX_NAN() ((float) NAN)
    1184             : #else
    1185             : static CYTHON_INLINE float __PYX_NAN() {
    1186             :   float value;
    1187             :   memset(&value, 0xFF, sizeof(value));
    1188             :   return value;
    1189             : }
    1190             : #endif
    1191             : #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
    1192             : #define __Pyx_truncl trunc
    1193             : #else
    1194             : #define __Pyx_truncl truncl
    1195             : #endif
    1196             : 
    1197             : #define __PYX_MARK_ERR_POS(f_index, lineno) \
    1198             :     { __pyx_filename = __pyx_f[f_index]; (void)__pyx_filename; __pyx_lineno = lineno; (void)__pyx_lineno; __pyx_clineno = __LINE__;  (void)__pyx_clineno; }
    1199             : #define __PYX_ERR(f_index, lineno, Ln_error) \
    1200             :     { __PYX_MARK_ERR_POS(f_index, lineno) goto Ln_error; }
    1201             : 
    1202             : #ifdef CYTHON_EXTERN_C
    1203             :     #undef __PYX_EXTERN_C
    1204             :     #define __PYX_EXTERN_C CYTHON_EXTERN_C
    1205             : #elif defined(__PYX_EXTERN_C)
    1206             :     #ifdef _MSC_VER
    1207             :     #pragma message ("Please do not define the '__PYX_EXTERN_C' macro externally. Use 'CYTHON_EXTERN_C' instead.")
    1208             :     #else
    1209             :     #warning Please do not define the '__PYX_EXTERN_C' macro externally. Use 'CYTHON_EXTERN_C' instead.
    1210             :     #endif
    1211             : #else
    1212             :   #ifdef __cplusplus
    1213             :     #define __PYX_EXTERN_C extern "C"
    1214             :   #else
    1215             :     #define __PYX_EXTERN_C extern
    1216             :   #endif
    1217             : #endif
    1218             : 
    1219             : #define __PYX_HAVE___ni_label
    1220             : #define __PYX_HAVE_API___ni_label
    1221             : /* Early includes */
    1222             : #include <string.h>
    1223             : #include <stdio.h>
    1224             : 
    1225             :     /* Using NumPy API declarations from "numpy/__init__.cython-30.pxd" */
    1226             :     
    1227             : #include "numpy/arrayobject.h"
    1228             : #include "numpy/ndarrayobject.h"
    1229             : #include "numpy/ndarraytypes.h"
    1230             : #include "numpy/arrayscalars.h"
    1231             : #include "numpy/ufuncobject.h"
    1232             : #include "pythread.h"
    1233             : #include <stdlib.h>
    1234             : #ifdef _OPENMP
    1235             : #include <omp.h>
    1236             : #endif /* _OPENMP */
    1237             : 
    1238             : #if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
    1239             : #define CYTHON_WITHOUT_ASSERTIONS
    1240             : #endif
    1241             : 
    1242             : typedef struct {PyObject **p; const char *s; const Py_ssize_t n; const char* encoding;
    1243             :                 const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry;
    1244             : 
    1245             : #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
    1246             : #define __PYX_DEFAULT_STRING_ENCODING_IS_UTF8 0
    1247             : #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT (PY_MAJOR_VERSION >= 3 && __PYX_DEFAULT_STRING_ENCODING_IS_UTF8)
    1248             : #define __PYX_DEFAULT_STRING_ENCODING ""
    1249             : #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
    1250             : #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
    1251             : #define __Pyx_uchar_cast(c) ((unsigned char)c)
    1252             : #define __Pyx_long_cast(x) ((long)x)
    1253             : #define __Pyx_fits_Py_ssize_t(v, type, is_signed)  (\
    1254             :     (sizeof(type) < sizeof(Py_ssize_t))  ||\
    1255             :     (sizeof(type) > sizeof(Py_ssize_t) &&\
    1256             :           likely(v < (type)PY_SSIZE_T_MAX ||\
    1257             :                  v == (type)PY_SSIZE_T_MAX)  &&\
    1258             :           (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
    1259             :                                 v == (type)PY_SSIZE_T_MIN)))  ||\
    1260             :     (sizeof(type) == sizeof(Py_ssize_t) &&\
    1261             :           (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
    1262             :                                v == (type)PY_SSIZE_T_MAX)))  )
    1263        1190 : static CYTHON_INLINE int __Pyx_is_valid_index(Py_ssize_t i, Py_ssize_t limit) {
    1264        1190 :     return (size_t) i < (size_t) limit;
    1265             : }
    1266             : #if defined (__cplusplus) && __cplusplus >= 201103L
    1267             :     #include <cstdlib>
    1268             :     #define __Pyx_sst_abs(value) std::abs(value)
    1269             : #elif SIZEOF_INT >= SIZEOF_SIZE_T
    1270             :     #define __Pyx_sst_abs(value) abs(value)
    1271             : #elif SIZEOF_LONG >= SIZEOF_SIZE_T
    1272             :     #define __Pyx_sst_abs(value) labs(value)
    1273             : #elif defined (_MSC_VER)
    1274             :     #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
    1275             : #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    1276             :     #define __Pyx_sst_abs(value) llabs(value)
    1277             : #elif defined (__GNUC__)
    1278             :     #define __Pyx_sst_abs(value) __builtin_llabs(value)
    1279             : #else
    1280             :     #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
    1281             : #endif
    1282             : static CYTHON_INLINE Py_ssize_t __Pyx_ssize_strlen(const char *s);
    1283             : static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject*);
    1284             : static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
    1285             : static CYTHON_INLINE PyObject* __Pyx_PyByteArray_FromString(const char*);
    1286             : #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
    1287             : #define __Pyx_PyBytes_FromString        PyBytes_FromString
    1288             : #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
    1289             : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*);
    1290             : #if PY_MAJOR_VERSION < 3
    1291             :     #define __Pyx_PyStr_FromString        __Pyx_PyBytes_FromString
    1292             :     #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
    1293             : #else
    1294             :     #define __Pyx_PyStr_FromString        __Pyx_PyUnicode_FromString
    1295             :     #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
    1296             : #endif
    1297             : #define __Pyx_PyBytes_AsWritableString(s)     ((char*) PyBytes_AS_STRING(s))
    1298             : #define __Pyx_PyBytes_AsWritableSString(s)    ((signed char*) PyBytes_AS_STRING(s))
    1299             : #define __Pyx_PyBytes_AsWritableUString(s)    ((unsigned char*) PyBytes_AS_STRING(s))
    1300             : #define __Pyx_PyBytes_AsString(s)     ((const char*) PyBytes_AS_STRING(s))
    1301             : #define __Pyx_PyBytes_AsSString(s)    ((const signed char*) PyBytes_AS_STRING(s))
    1302             : #define __Pyx_PyBytes_AsUString(s)    ((const unsigned char*) PyBytes_AS_STRING(s))
    1303             : #define __Pyx_PyObject_AsWritableString(s)    ((char*)(__pyx_uintptr_t) __Pyx_PyObject_AsString(s))
    1304             : #define __Pyx_PyObject_AsWritableSString(s)    ((signed char*)(__pyx_uintptr_t) __Pyx_PyObject_AsString(s))
    1305             : #define __Pyx_PyObject_AsWritableUString(s)    ((unsigned char*)(__pyx_uintptr_t) __Pyx_PyObject_AsString(s))
    1306             : #define __Pyx_PyObject_AsSString(s)    ((const signed char*) __Pyx_PyObject_AsString(s))
    1307             : #define __Pyx_PyObject_AsUString(s)    ((const unsigned char*) __Pyx_PyObject_AsString(s))
    1308             : #define __Pyx_PyObject_FromCString(s)  __Pyx_PyObject_FromString((const char*)s)
    1309             : #define __Pyx_PyBytes_FromCString(s)   __Pyx_PyBytes_FromString((const char*)s)
    1310             : #define __Pyx_PyByteArray_FromCString(s)   __Pyx_PyByteArray_FromString((const char*)s)
    1311             : #define __Pyx_PyStr_FromCString(s)     __Pyx_PyStr_FromString((const char*)s)
    1312             : #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
    1313             : #define __Pyx_PyUnicode_FromOrdinal(o)       PyUnicode_FromOrdinal((int)o)
    1314             : #define __Pyx_PyUnicode_AsUnicode            PyUnicode_AsUnicode
    1315             : #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
    1316             : #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
    1317             : static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b);
    1318             : static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
    1319             : static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject*);
    1320             : static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
    1321             : #define __Pyx_PySequence_Tuple(obj)\
    1322             :     (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
    1323             : static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
    1324             : static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
    1325             : static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject*);
    1326             : #if CYTHON_ASSUME_SAFE_MACROS
    1327             : #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
    1328             : #else
    1329             : #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
    1330             : #endif
    1331             : #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
    1332             : #if PY_MAJOR_VERSION >= 3
    1333             : #define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
    1334             : #else
    1335             : #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
    1336             : #endif
    1337             : #if CYTHON_USE_PYLONG_INTERNALS
    1338             :   #if PY_VERSION_HEX >= 0x030C00A7
    1339             :   #ifndef _PyLong_SIGN_MASK
    1340             :     #define _PyLong_SIGN_MASK 3
    1341             :   #endif
    1342             :   #ifndef _PyLong_NON_SIZE_BITS
    1343             :     #define _PyLong_NON_SIZE_BITS 3
    1344             :   #endif
    1345             :   #define __Pyx_PyLong_Sign(x)  (((PyLongObject*)x)->long_value.lv_tag & _PyLong_SIGN_MASK)
    1346             :   #define __Pyx_PyLong_IsNeg(x)  ((__Pyx_PyLong_Sign(x) & 2) != 0)
    1347             :   #define __Pyx_PyLong_IsNonNeg(x)  (!__Pyx_PyLong_IsNeg(x))
    1348             :   #define __Pyx_PyLong_IsZero(x)  (__Pyx_PyLong_Sign(x) & 1)
    1349             :   #define __Pyx_PyLong_IsPos(x)  (__Pyx_PyLong_Sign(x) == 0)
    1350             :   #define __Pyx_PyLong_CompactValueUnsigned(x)  (__Pyx_PyLong_Digits(x)[0])
    1351             :   #define __Pyx_PyLong_DigitCount(x)  ((Py_ssize_t) (((PyLongObject*)x)->long_value.lv_tag >> _PyLong_NON_SIZE_BITS))
    1352             :   #define __Pyx_PyLong_SignedDigitCount(x)\
    1353             :         ((1 - (Py_ssize_t) __Pyx_PyLong_Sign(x)) * __Pyx_PyLong_DigitCount(x))
    1354             :   #if defined(PyUnstable_Long_IsCompact) && defined(PyUnstable_Long_CompactValue)
    1355             :     #define __Pyx_PyLong_IsCompact(x)     PyUnstable_Long_IsCompact((PyLongObject*) x)
    1356             :     #define __Pyx_PyLong_CompactValue(x)  PyUnstable_Long_CompactValue((PyLongObject*) x)
    1357             :   #else
    1358             :     #define __Pyx_PyLong_IsCompact(x)     (((PyLongObject*)x)->long_value.lv_tag < (2 << _PyLong_NON_SIZE_BITS))
    1359             :     #define __Pyx_PyLong_CompactValue(x)  ((1 - (Py_ssize_t) __Pyx_PyLong_Sign(x)) * (Py_ssize_t) __Pyx_PyLong_Digits(x)[0])
    1360             :   #endif
    1361             :   typedef Py_ssize_t  __Pyx_compact_pylong;
    1362             :   typedef size_t  __Pyx_compact_upylong;
    1363             :   #else
    1364             :   #define __Pyx_PyLong_IsNeg(x)  (Py_SIZE(x) < 0)
    1365             :   #define __Pyx_PyLong_IsNonNeg(x)  (Py_SIZE(x) >= 0)
    1366             :   #define __Pyx_PyLong_IsZero(x)  (Py_SIZE(x) == 0)
    1367             :   #define __Pyx_PyLong_IsPos(x)  (Py_SIZE(x) > 0)
    1368             :   #define __Pyx_PyLong_CompactValueUnsigned(x)  ((Py_SIZE(x) == 0) ? 0 : __Pyx_PyLong_Digits(x)[0])
    1369             :   #define __Pyx_PyLong_DigitCount(x)  __Pyx_sst_abs(Py_SIZE(x))
    1370             :   #define __Pyx_PyLong_SignedDigitCount(x)  Py_SIZE(x)
    1371             :   #define __Pyx_PyLong_IsCompact(x)  (Py_SIZE(x) == 0 || Py_SIZE(x) == 1 || Py_SIZE(x) == -1)
    1372             :   #define __Pyx_PyLong_CompactValue(x)\
    1373             :         ((Py_SIZE(x) == 0) ? (sdigit) 0 : ((Py_SIZE(x) < 0) ? -(sdigit)__Pyx_PyLong_Digits(x)[0] : (sdigit)__Pyx_PyLong_Digits(x)[0]))
    1374             :   typedef sdigit  __Pyx_compact_pylong;
    1375             :   typedef digit  __Pyx_compact_upylong;
    1376             :   #endif
    1377             :   #if PY_VERSION_HEX >= 0x030C00A5
    1378             :   #define __Pyx_PyLong_Digits(x)  (((PyLongObject*)x)->long_value.ob_digit)
    1379             :   #else
    1380             :   #define __Pyx_PyLong_Digits(x)  (((PyLongObject*)x)->ob_digit)
    1381             :   #endif
    1382             : #endif
    1383             : #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
    1384             : #include <string.h>
    1385             : static int __Pyx_sys_getdefaultencoding_not_ascii;
    1386             : static int __Pyx_init_sys_getdefaultencoding_params(void) {
    1387             :     PyObject* sys;
    1388             :     PyObject* default_encoding = NULL;
    1389             :     PyObject* ascii_chars_u = NULL;
    1390             :     PyObject* ascii_chars_b = NULL;
    1391             :     const char* default_encoding_c;
    1392             :     sys = PyImport_ImportModule("sys");
    1393             :     if (!sys) goto bad;
    1394             :     default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
    1395             :     Py_DECREF(sys);
    1396             :     if (!default_encoding) goto bad;
    1397             :     default_encoding_c = PyBytes_AsString(default_encoding);
    1398             :     if (!default_encoding_c) goto bad;
    1399             :     if (strcmp(default_encoding_c, "ascii") == 0) {
    1400             :         __Pyx_sys_getdefaultencoding_not_ascii = 0;
    1401             :     } else {
    1402             :         char ascii_chars[128];
    1403             :         int c;
    1404             :         for (c = 0; c < 128; c++) {
    1405             :             ascii_chars[c] = (char) c;
    1406             :         }
    1407             :         __Pyx_sys_getdefaultencoding_not_ascii = 1;
    1408             :         ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
    1409             :         if (!ascii_chars_u) goto bad;
    1410             :         ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
    1411             :         if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
    1412             :             PyErr_Format(
    1413             :                 PyExc_ValueError,
    1414             :                 "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
    1415             :                 default_encoding_c);
    1416             :             goto bad;
    1417             :         }
    1418             :         Py_DECREF(ascii_chars_u);
    1419             :         Py_DECREF(ascii_chars_b);
    1420             :     }
    1421             :     Py_DECREF(default_encoding);
    1422             :     return 0;
    1423             : bad:
    1424             :     Py_XDECREF(default_encoding);
    1425             :     Py_XDECREF(ascii_chars_u);
    1426             :     Py_XDECREF(ascii_chars_b);
    1427             :     return -1;
    1428             : }
    1429             : #endif
    1430             : #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
    1431             : #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
    1432             : #else
    1433             : #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
    1434             : #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
    1435             : #include <string.h>
    1436             : static char* __PYX_DEFAULT_STRING_ENCODING;
    1437             : static int __Pyx_init_sys_getdefaultencoding_params(void) {
    1438             :     PyObject* sys;
    1439             :     PyObject* default_encoding = NULL;
    1440             :     char* default_encoding_c;
    1441             :     sys = PyImport_ImportModule("sys");
    1442             :     if (!sys) goto bad;
    1443             :     default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
    1444             :     Py_DECREF(sys);
    1445             :     if (!default_encoding) goto bad;
    1446             :     default_encoding_c = PyBytes_AsString(default_encoding);
    1447             :     if (!default_encoding_c) goto bad;
    1448             :     __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c) + 1);
    1449             :     if (!__PYX_DEFAULT_STRING_ENCODING) goto bad;
    1450             :     strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
    1451             :     Py_DECREF(default_encoding);
    1452             :     return 0;
    1453             : bad:
    1454             :     Py_XDECREF(default_encoding);
    1455             :     return -1;
    1456             : }
    1457             : #endif
    1458             : #endif
    1459             : 
    1460             : 
    1461             : /* Test for GCC > 2.95 */
    1462             : #if defined(__GNUC__)     && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
    1463             :   #define likely(x)   __builtin_expect(!!(x), 1)
    1464             :   #define unlikely(x) __builtin_expect(!!(x), 0)
    1465             : #else /* !__GNUC__ or GCC < 2.95 */
    1466             :   #define likely(x)   (x)
    1467             :   #define unlikely(x) (x)
    1468             : #endif /* __GNUC__ */
    1469             : static CYTHON_INLINE void __Pyx_pretend_to_initialize(void* ptr) { (void)ptr; }
    1470             : 
    1471             : #if !CYTHON_USE_MODULE_STATE
    1472             : static PyObject *__pyx_m = NULL;
    1473             : #endif
    1474             : static int __pyx_lineno;
    1475             : static int __pyx_clineno = 0;
    1476             : static const char * __pyx_cfilenm = __FILE__;
    1477             : static const char *__pyx_filename;
    1478             : 
    1479             : /* Header.proto */
    1480             : #if !defined(CYTHON_CCOMPLEX)
    1481             :   #if defined(__cplusplus)
    1482             :     #define CYTHON_CCOMPLEX 1
    1483             :   #elif (defined(_Complex_I) && !defined(_MSC_VER)) || ((defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112L) && !defined(__STDC_NO_COMPLEX__) && !defined(_MSC_VER))
    1484             :     #define CYTHON_CCOMPLEX 1
    1485             :   #else
    1486             :     #define CYTHON_CCOMPLEX 0
    1487             :   #endif
    1488             : #endif
    1489             : #if CYTHON_CCOMPLEX
    1490             :   #ifdef __cplusplus
    1491             :     #include <complex>
    1492             :   #else
    1493             :     #include <complex.h>
    1494             :   #endif
    1495             : #endif
    1496             : #if CYTHON_CCOMPLEX && !defined(__cplusplus) && defined(__sun__) && defined(__GNUC__)
    1497             :   #undef _Complex_I
    1498             :   #define _Complex_I 1.0fj
    1499             : #endif
    1500             : 
    1501             : /* #### Code section: filename_table ### */
    1502             : 
    1503             : static const char *__pyx_f[] = {
    1504             :   "_ni_label.pyx",
    1505             :   "<stringsource>",
    1506             :   "__init__.cython-30.pxd",
    1507             :   "type.pxd",
    1508             : };
    1509             : /* #### Code section: utility_code_proto_before_types ### */
    1510             : /* ForceInitThreads.proto */
    1511             : #ifndef __PYX_FORCE_INIT_THREADS
    1512             :   #define __PYX_FORCE_INIT_THREADS 0
    1513             : #endif
    1514             : 
    1515             : /* NoFastGil.proto */
    1516             : #define __Pyx_PyGILState_Ensure PyGILState_Ensure
    1517             : #define __Pyx_PyGILState_Release PyGILState_Release
    1518             : #define __Pyx_FastGIL_Remember()
    1519             : #define __Pyx_FastGIL_Forget()
    1520             : #define __Pyx_FastGilFuncInit()
    1521             : 
    1522             : /* BufferFormatStructs.proto */
    1523             : struct __Pyx_StructField_;
    1524             : #define __PYX_BUF_FLAGS_PACKED_STRUCT (1 << 0)
    1525             : typedef struct {
    1526             :   const char* name;
    1527             :   struct __Pyx_StructField_* fields;
    1528             :   size_t size;
    1529             :   size_t arraysize[8];
    1530             :   int ndim;
    1531             :   char typegroup;
    1532             :   char is_unsigned;
    1533             :   int flags;
    1534             : } __Pyx_TypeInfo;
    1535             : typedef struct __Pyx_StructField_ {
    1536             :   __Pyx_TypeInfo* type;
    1537             :   const char* name;
    1538             :   size_t offset;
    1539             : } __Pyx_StructField;
    1540             : typedef struct {
    1541             :   __Pyx_StructField* field;
    1542             :   size_t parent_offset;
    1543             : } __Pyx_BufFmt_StackElem;
    1544             : typedef struct {
    1545             :   __Pyx_StructField root;
    1546             :   __Pyx_BufFmt_StackElem* head;
    1547             :   size_t fmt_offset;
    1548             :   size_t new_count, enc_count;
    1549             :   size_t struct_alignment;
    1550             :   int is_complex;
    1551             :   char enc_type;
    1552             :   char new_packmode;
    1553             :   char enc_packmode;
    1554             :   char is_valid_array;
    1555             : } __Pyx_BufFmt_Context;
    1556             : 
    1557             : /* Atomics.proto */
    1558             : #include <pythread.h>
    1559             : #ifndef CYTHON_ATOMICS
    1560             :     #define CYTHON_ATOMICS 1
    1561             : #endif
    1562             : #define __PYX_CYTHON_ATOMICS_ENABLED() CYTHON_ATOMICS
    1563             : #define __pyx_atomic_int_type int
    1564             : #define __pyx_nonatomic_int_type int
    1565             : #if CYTHON_ATOMICS && (defined(__STDC_VERSION__) &&\
    1566             :                         (__STDC_VERSION__ >= 201112L) &&\
    1567             :                         !defined(__STDC_NO_ATOMICS__))
    1568             :     #include <stdatomic.h>
    1569             : #elif CYTHON_ATOMICS && (defined(__cplusplus) && (\
    1570             :                     (__cplusplus >= 201103L) ||\
    1571             :                     (defined(_MSC_VER) && _MSC_VER >= 1700)))
    1572             :     #include <atomic>
    1573             : #endif
    1574             : #if CYTHON_ATOMICS && (defined(__STDC_VERSION__) &&\
    1575             :                         (__STDC_VERSION__ >= 201112L) &&\
    1576             :                         !defined(__STDC_NO_ATOMICS__) &&\
    1577             :                        ATOMIC_INT_LOCK_FREE == 2)
    1578             :     #undef __pyx_atomic_int_type
    1579             :     #define __pyx_atomic_int_type atomic_int
    1580             :     #define __pyx_atomic_incr_aligned(value) atomic_fetch_add_explicit(value, 1, memory_order_relaxed)
    1581             :     #define __pyx_atomic_decr_aligned(value) atomic_fetch_sub_explicit(value, 1, memory_order_acq_rel)
    1582             :     #if defined(__PYX_DEBUG_ATOMICS) && defined(_MSC_VER)
    1583             :         #pragma message ("Using standard C atomics")
    1584             :     #elif defined(__PYX_DEBUG_ATOMICS)
    1585             :         #warning "Using standard C atomics"
    1586             :     #endif
    1587             : #elif CYTHON_ATOMICS && (defined(__cplusplus) && (\
    1588             :                     (__cplusplus >= 201103L) ||\
    1589             : \
    1590             :                     (defined(_MSC_VER) && _MSC_VER >= 1700)) &&\
    1591             :                     ATOMIC_INT_LOCK_FREE == 2)
    1592             :     #undef __pyx_atomic_int_type
    1593             :     #define __pyx_atomic_int_type std::atomic_int
    1594             :     #define __pyx_atomic_incr_aligned(value) std::atomic_fetch_add_explicit(value, 1, std::memory_order_relaxed)
    1595             :     #define __pyx_atomic_decr_aligned(value) std::atomic_fetch_sub_explicit(value, 1, std::memory_order_acq_rel)
    1596             :     #if defined(__PYX_DEBUG_ATOMICS) && defined(_MSC_VER)
    1597             :         #pragma message ("Using standard C++ atomics")
    1598             :     #elif defined(__PYX_DEBUG_ATOMICS)
    1599             :         #warning "Using standard C++ atomics"
    1600             :     #endif
    1601             : #elif CYTHON_ATOMICS && (__GNUC__ >= 5 || (__GNUC__ == 4 &&\
    1602             :                     (__GNUC_MINOR__ > 1 ||\
    1603             :                     (__GNUC_MINOR__ == 1 && __GNUC_PATCHLEVEL__ >= 2))))
    1604             :     #define __pyx_atomic_incr_aligned(value) __sync_fetch_and_add(value, 1)
    1605             :     #define __pyx_atomic_decr_aligned(value) __sync_fetch_and_sub(value, 1)
    1606             :     #ifdef __PYX_DEBUG_ATOMICS
    1607             :         #warning "Using GNU atomics"
    1608             :     #endif
    1609             : #elif CYTHON_ATOMICS && defined(_MSC_VER)
    1610             :     #include <intrin.h>
    1611             :     #undef __pyx_atomic_int_type
    1612             :     #define __pyx_atomic_int_type long
    1613             :     #undef __pyx_nonatomic_int_type
    1614             :     #define __pyx_nonatomic_int_type long
    1615             :     #pragma intrinsic (_InterlockedExchangeAdd)
    1616             :     #define __pyx_atomic_incr_aligned(value) _InterlockedExchangeAdd(value, 1)
    1617             :     #define __pyx_atomic_decr_aligned(value) _InterlockedExchangeAdd(value, -1)
    1618             :     #ifdef __PYX_DEBUG_ATOMICS
    1619             :         #pragma message ("Using MSVC atomics")
    1620             :     #endif
    1621             : #else
    1622             :     #undef CYTHON_ATOMICS
    1623             :     #define CYTHON_ATOMICS 0
    1624             :     #ifdef __PYX_DEBUG_ATOMICS
    1625             :         #warning "Not using atomics"
    1626             :     #endif
    1627             : #endif
    1628             : #if CYTHON_ATOMICS
    1629             :     #define __pyx_add_acquisition_count(memview)\
    1630             :              __pyx_atomic_incr_aligned(__pyx_get_slice_count_pointer(memview))
    1631             :     #define __pyx_sub_acquisition_count(memview)\
    1632             :             __pyx_atomic_decr_aligned(__pyx_get_slice_count_pointer(memview))
    1633             : #else
    1634             :     #define __pyx_add_acquisition_count(memview)\
    1635             :             __pyx_add_acquisition_count_locked(__pyx_get_slice_count_pointer(memview), memview->lock)
    1636             :     #define __pyx_sub_acquisition_count(memview)\
    1637             :             __pyx_sub_acquisition_count_locked(__pyx_get_slice_count_pointer(memview), memview->lock)
    1638             : #endif
    1639             : 
    1640             : /* MemviewSliceStruct.proto */
    1641             : struct __pyx_memoryview_obj;
    1642             : typedef struct {
    1643             :   struct __pyx_memoryview_obj *memview;
    1644             :   char *data;
    1645             :   Py_ssize_t shape[8];
    1646             :   Py_ssize_t strides[8];
    1647             :   Py_ssize_t suboffsets[8];
    1648             : } __Pyx_memviewslice;
    1649             : #define __Pyx_MemoryView_Len(m)  (m.shape[0])
    1650             : 
    1651             : /* #### Code section: numeric_typedefs ### */
    1652             : 
    1653             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":769
    1654             :  * # in Cython to enable them only on the right systems.
    1655             :  * 
    1656             :  * ctypedef npy_int8       int8_t             # <<<<<<<<<<<<<<
    1657             :  * ctypedef npy_int16      int16_t
    1658             :  * ctypedef npy_int32      int32_t
    1659             :  */
    1660             : typedef npy_int8 __pyx_t_5numpy_int8_t;
    1661             : 
    1662             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":770
    1663             :  * 
    1664             :  * ctypedef npy_int8       int8_t
    1665             :  * ctypedef npy_int16      int16_t             # <<<<<<<<<<<<<<
    1666             :  * ctypedef npy_int32      int32_t
    1667             :  * ctypedef npy_int64      int64_t
    1668             :  */
    1669             : typedef npy_int16 __pyx_t_5numpy_int16_t;
    1670             : 
    1671             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":771
    1672             :  * ctypedef npy_int8       int8_t
    1673             :  * ctypedef npy_int16      int16_t
    1674             :  * ctypedef npy_int32      int32_t             # <<<<<<<<<<<<<<
    1675             :  * ctypedef npy_int64      int64_t
    1676             :  * #ctypedef npy_int96      int96_t
    1677             :  */
    1678             : typedef npy_int32 __pyx_t_5numpy_int32_t;
    1679             : 
    1680             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":772
    1681             :  * ctypedef npy_int16      int16_t
    1682             :  * ctypedef npy_int32      int32_t
    1683             :  * ctypedef npy_int64      int64_t             # <<<<<<<<<<<<<<
    1684             :  * #ctypedef npy_int96      int96_t
    1685             :  * #ctypedef npy_int128     int128_t
    1686             :  */
    1687             : typedef npy_int64 __pyx_t_5numpy_int64_t;
    1688             : 
    1689             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":776
    1690             :  * #ctypedef npy_int128     int128_t
    1691             :  * 
    1692             :  * ctypedef npy_uint8      uint8_t             # <<<<<<<<<<<<<<
    1693             :  * ctypedef npy_uint16     uint16_t
    1694             :  * ctypedef npy_uint32     uint32_t
    1695             :  */
    1696             : typedef npy_uint8 __pyx_t_5numpy_uint8_t;
    1697             : 
    1698             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":777
    1699             :  * 
    1700             :  * ctypedef npy_uint8      uint8_t
    1701             :  * ctypedef npy_uint16     uint16_t             # <<<<<<<<<<<<<<
    1702             :  * ctypedef npy_uint32     uint32_t
    1703             :  * ctypedef npy_uint64     uint64_t
    1704             :  */
    1705             : typedef npy_uint16 __pyx_t_5numpy_uint16_t;
    1706             : 
    1707             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":778
    1708             :  * ctypedef npy_uint8      uint8_t
    1709             :  * ctypedef npy_uint16     uint16_t
    1710             :  * ctypedef npy_uint32     uint32_t             # <<<<<<<<<<<<<<
    1711             :  * ctypedef npy_uint64     uint64_t
    1712             :  * #ctypedef npy_uint96     uint96_t
    1713             :  */
    1714             : typedef npy_uint32 __pyx_t_5numpy_uint32_t;
    1715             : 
    1716             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":779
    1717             :  * ctypedef npy_uint16     uint16_t
    1718             :  * ctypedef npy_uint32     uint32_t
    1719             :  * ctypedef npy_uint64     uint64_t             # <<<<<<<<<<<<<<
    1720             :  * #ctypedef npy_uint96     uint96_t
    1721             :  * #ctypedef npy_uint128    uint128_t
    1722             :  */
    1723             : typedef npy_uint64 __pyx_t_5numpy_uint64_t;
    1724             : 
    1725             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":783
    1726             :  * #ctypedef npy_uint128    uint128_t
    1727             :  * 
    1728             :  * ctypedef npy_float32    float32_t             # <<<<<<<<<<<<<<
    1729             :  * ctypedef npy_float64    float64_t
    1730             :  * #ctypedef npy_float80    float80_t
    1731             :  */
    1732             : typedef npy_float32 __pyx_t_5numpy_float32_t;
    1733             : 
    1734             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":784
    1735             :  * 
    1736             :  * ctypedef npy_float32    float32_t
    1737             :  * ctypedef npy_float64    float64_t             # <<<<<<<<<<<<<<
    1738             :  * #ctypedef npy_float80    float80_t
    1739             :  * #ctypedef npy_float128   float128_t
    1740             :  */
    1741             : typedef npy_float64 __pyx_t_5numpy_float64_t;
    1742             : 
    1743             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":791
    1744             :  * ctypedef double complex complex128_t
    1745             :  * 
    1746             :  * ctypedef npy_longlong   longlong_t             # <<<<<<<<<<<<<<
    1747             :  * ctypedef npy_ulonglong  ulonglong_t
    1748             :  * 
    1749             :  */
    1750             : typedef npy_longlong __pyx_t_5numpy_longlong_t;
    1751             : 
    1752             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":792
    1753             :  * 
    1754             :  * ctypedef npy_longlong   longlong_t
    1755             :  * ctypedef npy_ulonglong  ulonglong_t             # <<<<<<<<<<<<<<
    1756             :  * 
    1757             :  * ctypedef npy_intp       intp_t
    1758             :  */
    1759             : typedef npy_ulonglong __pyx_t_5numpy_ulonglong_t;
    1760             : 
    1761             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":794
    1762             :  * ctypedef npy_ulonglong  ulonglong_t
    1763             :  * 
    1764             :  * ctypedef npy_intp       intp_t             # <<<<<<<<<<<<<<
    1765             :  * ctypedef npy_uintp      uintp_t
    1766             :  * 
    1767             :  */
    1768             : typedef npy_intp __pyx_t_5numpy_intp_t;
    1769             : 
    1770             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":795
    1771             :  * 
    1772             :  * ctypedef npy_intp       intp_t
    1773             :  * ctypedef npy_uintp      uintp_t             # <<<<<<<<<<<<<<
    1774             :  * 
    1775             :  * ctypedef npy_double     float_t
    1776             :  */
    1777             : typedef npy_uintp __pyx_t_5numpy_uintp_t;
    1778             : 
    1779             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":797
    1780             :  * ctypedef npy_uintp      uintp_t
    1781             :  * 
    1782             :  * ctypedef npy_double     float_t             # <<<<<<<<<<<<<<
    1783             :  * ctypedef npy_double     double_t
    1784             :  * ctypedef npy_longdouble longdouble_t
    1785             :  */
    1786             : typedef npy_double __pyx_t_5numpy_float_t;
    1787             : 
    1788             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":798
    1789             :  * 
    1790             :  * ctypedef npy_double     float_t
    1791             :  * ctypedef npy_double     double_t             # <<<<<<<<<<<<<<
    1792             :  * ctypedef npy_longdouble longdouble_t
    1793             :  * 
    1794             :  */
    1795             : typedef npy_double __pyx_t_5numpy_double_t;
    1796             : 
    1797             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":799
    1798             :  * ctypedef npy_double     float_t
    1799             :  * ctypedef npy_double     double_t
    1800             :  * ctypedef npy_longdouble longdouble_t             # <<<<<<<<<<<<<<
    1801             :  * 
    1802             :  * ctypedef float complex       cfloat_t
    1803             :  */
    1804             : typedef npy_longdouble __pyx_t_5numpy_longdouble_t;
    1805             : /* #### Code section: complex_type_declarations ### */
    1806             : /* Declarations.proto */
    1807             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    1808             :   #ifdef __cplusplus
    1809             :     typedef ::std::complex< float > __pyx_t_float_complex;
    1810             :   #else
    1811             :     typedef float _Complex __pyx_t_float_complex;
    1812             :   #endif
    1813             : #else
    1814             :     typedef struct { float real, imag; } __pyx_t_float_complex;
    1815             : #endif
    1816             : static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float, float);
    1817             : 
    1818             : /* Declarations.proto */
    1819             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    1820             :   #ifdef __cplusplus
    1821             :     typedef ::std::complex< double > __pyx_t_double_complex;
    1822             :   #else
    1823             :     typedef double _Complex __pyx_t_double_complex;
    1824             :   #endif
    1825             : #else
    1826             :     typedef struct { double real, imag; } __pyx_t_double_complex;
    1827             : #endif
    1828             : static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double, double);
    1829             : 
    1830             : /* Declarations.proto */
    1831             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    1832             :   #ifdef __cplusplus
    1833             :     typedef ::std::complex< long double > __pyx_t_long_double_complex;
    1834             :   #else
    1835             :     typedef long double _Complex __pyx_t_long_double_complex;
    1836             :   #endif
    1837             : #else
    1838             :     typedef struct { long double real, imag; } __pyx_t_long_double_complex;
    1839             : #endif
    1840             : static CYTHON_INLINE __pyx_t_long_double_complex __pyx_t_long_double_complex_from_parts(long double, long double);
    1841             : 
    1842             : /* #### Code section: type_declarations ### */
    1843             : 
    1844             : /*--- Type declarations ---*/
    1845             : struct __pyx_array_obj;
    1846             : struct __pyx_MemviewEnum_obj;
    1847             : struct __pyx_memoryview_obj;
    1848             : struct __pyx_memoryviewslice_obj;
    1849             : 
    1850             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1095
    1851             :  * 
    1852             :  * # Iterator API added in v1.6
    1853             :  * ctypedef int (*NpyIter_IterNextFunc)(NpyIter* it) noexcept nogil             # <<<<<<<<<<<<<<
    1854             :  * ctypedef void (*NpyIter_GetMultiIndexFunc)(NpyIter* it, npy_intp* outcoords) noexcept nogil
    1855             :  * 
    1856             :  */
    1857             : typedef int (*__pyx_t_5numpy_NpyIter_IterNextFunc)(NpyIter *);
    1858             : 
    1859             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1096
    1860             :  * # Iterator API added in v1.6
    1861             :  * ctypedef int (*NpyIter_IterNextFunc)(NpyIter* it) noexcept nogil
    1862             :  * ctypedef void (*NpyIter_GetMultiIndexFunc)(NpyIter* it, npy_intp* outcoords) noexcept nogil             # <<<<<<<<<<<<<<
    1863             :  * 
    1864             :  * cdef extern from "numpy/arrayobject.h":
    1865             :  */
    1866             : typedef void (*__pyx_t_5numpy_NpyIter_GetMultiIndexFunc)(NpyIter *, npy_intp *);
    1867             : struct __pyx_defaults;
    1868             : typedef struct __pyx_defaults __pyx_defaults;
    1869             : struct __pyx_defaults1;
    1870             : typedef struct __pyx_defaults1 __pyx_defaults1;
    1871             : struct __pyx_defaults2;
    1872             : typedef struct __pyx_defaults2 __pyx_defaults2;
    1873             : 
    1874             : /* "_ni_label.pyx":14
    1875             :  *    ctypedef int Py_intptr_t
    1876             :  * 
    1877             :  * cdef enum:             # <<<<<<<<<<<<<<
    1878             :  *     BACKGROUND = 0
    1879             :  *     FOREGROUND = 1
    1880             :  */
    1881             : enum  {
    1882             :   __pyx_e_9_ni_label_BACKGROUND = 0,
    1883             :   __pyx_e_9_ni_label_FOREGROUND = 1
    1884             : };
    1885             : 
    1886             : /* "_ni_label.pyx":106
    1887             :  * # Typedefs for referring to specialized instances of fused functions
    1888             :  * ######################################################################
    1889             :  * ctypedef void (*nonzero_line_func_t)(void *p, np.intp_t stride,             # <<<<<<<<<<<<<<
    1890             :  *                                      np.uintp_t *line, np.intp_t L) noexcept nogil
    1891             :  * ctypedef void (*read_line_func_t)(void *p, np.intp_t stride,
    1892             :  */
    1893             : typedef void (*__pyx_t_9_ni_label_nonzero_line_func_t)(void *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t);
    1894             : 
    1895             : /* "_ni_label.pyx":108
    1896             :  * ctypedef void (*nonzero_line_func_t)(void *p, np.intp_t stride,
    1897             :  *                                      np.uintp_t *line, np.intp_t L) noexcept nogil
    1898             :  * ctypedef void (*read_line_func_t)(void *p, np.intp_t stride,             # <<<<<<<<<<<<<<
    1899             :  *                                   np.uintp_t *line, np.intp_t L) noexcept nogil
    1900             :  * ctypedef bint (*write_line_func_t)(void *p, np.intp_t stride,
    1901             :  */
    1902             : typedef void (*__pyx_t_9_ni_label_read_line_func_t)(void *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t);
    1903             : 
    1904             : /* "_ni_label.pyx":110
    1905             :  * ctypedef void (*read_line_func_t)(void *p, np.intp_t stride,
    1906             :  *                                   np.uintp_t *line, np.intp_t L) noexcept nogil
    1907             :  * ctypedef bint (*write_line_func_t)(void *p, np.intp_t stride,             # <<<<<<<<<<<<<<
    1908             :  *                                    np.uintp_t *line, np.intp_t L) noexcept nogil
    1909             :  * 
    1910             :  */
    1911             : typedef int (*__pyx_t_9_ni_label_write_line_func_t)(void *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t);
    1912             : struct __pyx_defaults {
    1913             :   PyObject *__pyx_arg__fused_sigindex;
    1914             : };
    1915             : struct __pyx_defaults1 {
    1916             :   PyObject *__pyx_arg__fused_sigindex;
    1917             : };
    1918             : struct __pyx_defaults2 {
    1919             :   PyObject *__pyx_arg__fused_sigindex;
    1920             : };
    1921             : 
    1922             : /* "View.MemoryView":114
    1923             :  * @cython.collection_type("sequence")
    1924             :  * @cname("__pyx_array")
    1925             :  * cdef class array:             # <<<<<<<<<<<<<<
    1926             :  * 
    1927             :  *     cdef:
    1928             :  */
    1929             : struct __pyx_array_obj {
    1930             :   PyObject_HEAD
    1931             :   struct __pyx_vtabstruct_array *__pyx_vtab;
    1932             :   char *data;
    1933             :   Py_ssize_t len;
    1934             :   char *format;
    1935             :   int ndim;
    1936             :   Py_ssize_t *_shape;
    1937             :   Py_ssize_t *_strides;
    1938             :   Py_ssize_t itemsize;
    1939             :   PyObject *mode;
    1940             :   PyObject *_format;
    1941             :   void (*callback_free_data)(void *);
    1942             :   int free_data;
    1943             :   int dtype_is_object;
    1944             : };
    1945             : 
    1946             : 
    1947             : /* "View.MemoryView":302
    1948             :  * 
    1949             :  * @cname('__pyx_MemviewEnum')
    1950             :  * cdef class Enum(object):             # <<<<<<<<<<<<<<
    1951             :  *     cdef object name
    1952             :  *     def __init__(self, name):
    1953             :  */
    1954             : struct __pyx_MemviewEnum_obj {
    1955             :   PyObject_HEAD
    1956             :   PyObject *name;
    1957             : };
    1958             : 
    1959             : 
    1960             : /* "View.MemoryView":337
    1961             :  * 
    1962             :  * @cname('__pyx_memoryview')
    1963             :  * cdef class memoryview:             # <<<<<<<<<<<<<<
    1964             :  * 
    1965             :  *     cdef object obj
    1966             :  */
    1967             : struct __pyx_memoryview_obj {
    1968             :   PyObject_HEAD
    1969             :   struct __pyx_vtabstruct_memoryview *__pyx_vtab;
    1970             :   PyObject *obj;
    1971             :   PyObject *_size;
    1972             :   PyObject *_array_interface;
    1973             :   PyThread_type_lock lock;
    1974             :   __pyx_atomic_int_type acquisition_count;
    1975             :   Py_buffer view;
    1976             :   int flags;
    1977             :   int dtype_is_object;
    1978             :   __Pyx_TypeInfo *typeinfo;
    1979             : };
    1980             : 
    1981             : 
    1982             : /* "View.MemoryView":952
    1983             :  * @cython.collection_type("sequence")
    1984             :  * @cname('__pyx_memoryviewslice')
    1985             :  * cdef class _memoryviewslice(memoryview):             # <<<<<<<<<<<<<<
    1986             :  *     "Internal class for passing memoryview slices to Python"
    1987             :  * 
    1988             :  */
    1989             : struct __pyx_memoryviewslice_obj {
    1990             :   struct __pyx_memoryview_obj __pyx_base;
    1991             :   __Pyx_memviewslice from_slice;
    1992             :   PyObject *from_object;
    1993             :   PyObject *(*to_object_func)(char *);
    1994             :   int (*to_dtype_func)(char *, PyObject *);
    1995             : };
    1996             : 
    1997             : 
    1998             : 
    1999             : /* "View.MemoryView":114
    2000             :  * @cython.collection_type("sequence")
    2001             :  * @cname("__pyx_array")
    2002             :  * cdef class array:             # <<<<<<<<<<<<<<
    2003             :  * 
    2004             :  *     cdef:
    2005             :  */
    2006             : 
    2007             : struct __pyx_vtabstruct_array {
    2008             :   PyObject *(*get_memview)(struct __pyx_array_obj *);
    2009             : };
    2010             : static struct __pyx_vtabstruct_array *__pyx_vtabptr_array;
    2011             : 
    2012             : 
    2013             : /* "View.MemoryView":337
    2014             :  * 
    2015             :  * @cname('__pyx_memoryview')
    2016             :  * cdef class memoryview:             # <<<<<<<<<<<<<<
    2017             :  * 
    2018             :  *     cdef object obj
    2019             :  */
    2020             : 
    2021             : struct __pyx_vtabstruct_memoryview {
    2022             :   char *(*get_item_pointer)(struct __pyx_memoryview_obj *, PyObject *);
    2023             :   PyObject *(*is_slice)(struct __pyx_memoryview_obj *, PyObject *);
    2024             :   PyObject *(*setitem_slice_assignment)(struct __pyx_memoryview_obj *, PyObject *, PyObject *);
    2025             :   PyObject *(*setitem_slice_assign_scalar)(struct __pyx_memoryview_obj *, struct __pyx_memoryview_obj *, PyObject *);
    2026             :   PyObject *(*setitem_indexed)(struct __pyx_memoryview_obj *, PyObject *, PyObject *);
    2027             :   PyObject *(*convert_item_to_object)(struct __pyx_memoryview_obj *, char *);
    2028             :   PyObject *(*assign_item_from_object)(struct __pyx_memoryview_obj *, char *, PyObject *);
    2029             :   PyObject *(*_get_base)(struct __pyx_memoryview_obj *);
    2030             : };
    2031             : static struct __pyx_vtabstruct_memoryview *__pyx_vtabptr_memoryview;
    2032             : 
    2033             : 
    2034             : /* "View.MemoryView":952
    2035             :  * @cython.collection_type("sequence")
    2036             :  * @cname('__pyx_memoryviewslice')
    2037             :  * cdef class _memoryviewslice(memoryview):             # <<<<<<<<<<<<<<
    2038             :  *     "Internal class for passing memoryview slices to Python"
    2039             :  * 
    2040             :  */
    2041             : 
    2042             : struct __pyx_vtabstruct__memoryviewslice {
    2043             :   struct __pyx_vtabstruct_memoryview __pyx_base;
    2044             : };
    2045             : static struct __pyx_vtabstruct__memoryviewslice *__pyx_vtabptr__memoryviewslice;
    2046             : /* #### Code section: utility_code_proto ### */
    2047             : 
    2048             : /* --- Runtime support code (head) --- */
    2049             : /* Refnanny.proto */
    2050             : #ifndef CYTHON_REFNANNY
    2051             :   #define CYTHON_REFNANNY 0
    2052             : #endif
    2053             : #if CYTHON_REFNANNY
    2054             :   typedef struct {
    2055             :     void (*INCREF)(void*, PyObject*, Py_ssize_t);
    2056             :     void (*DECREF)(void*, PyObject*, Py_ssize_t);
    2057             :     void (*GOTREF)(void*, PyObject*, Py_ssize_t);
    2058             :     void (*GIVEREF)(void*, PyObject*, Py_ssize_t);
    2059             :     void* (*SetupContext)(const char*, Py_ssize_t, const char*);
    2060             :     void (*FinishContext)(void**);
    2061             :   } __Pyx_RefNannyAPIStruct;
    2062             :   static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
    2063             :   static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname);
    2064             :   #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
    2065             : #ifdef WITH_THREAD
    2066             :   #define __Pyx_RefNannySetupContext(name, acquire_gil)\
    2067             :           if (acquire_gil) {\
    2068             :               PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
    2069             :               __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), (__LINE__), (__FILE__));\
    2070             :               PyGILState_Release(__pyx_gilstate_save);\
    2071             :           } else {\
    2072             :               __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), (__LINE__), (__FILE__));\
    2073             :           }
    2074             :   #define __Pyx_RefNannyFinishContextNogil() {\
    2075             :               PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
    2076             :               __Pyx_RefNannyFinishContext();\
    2077             :               PyGILState_Release(__pyx_gilstate_save);\
    2078             :           }
    2079             : #else
    2080             :   #define __Pyx_RefNannySetupContext(name, acquire_gil)\
    2081             :           __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), (__LINE__), (__FILE__))
    2082             :   #define __Pyx_RefNannyFinishContextNogil() __Pyx_RefNannyFinishContext()
    2083             : #endif
    2084             :   #define __Pyx_RefNannyFinishContextNogil() {\
    2085             :               PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
    2086             :               __Pyx_RefNannyFinishContext();\
    2087             :               PyGILState_Release(__pyx_gilstate_save);\
    2088             :           }
    2089             :   #define __Pyx_RefNannyFinishContext()\
    2090             :           __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
    2091             :   #define __Pyx_INCREF(r)  __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), (__LINE__))
    2092             :   #define __Pyx_DECREF(r)  __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), (__LINE__))
    2093             :   #define __Pyx_GOTREF(r)  __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), (__LINE__))
    2094             :   #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), (__LINE__))
    2095             :   #define __Pyx_XINCREF(r)  do { if((r) == NULL); else {__Pyx_INCREF(r); }} while(0)
    2096             :   #define __Pyx_XDECREF(r)  do { if((r) == NULL); else {__Pyx_DECREF(r); }} while(0)
    2097             :   #define __Pyx_XGOTREF(r)  do { if((r) == NULL); else {__Pyx_GOTREF(r); }} while(0)
    2098             :   #define __Pyx_XGIVEREF(r) do { if((r) == NULL); else {__Pyx_GIVEREF(r);}} while(0)
    2099             : #else
    2100             :   #define __Pyx_RefNannyDeclarations
    2101             :   #define __Pyx_RefNannySetupContext(name, acquire_gil)
    2102             :   #define __Pyx_RefNannyFinishContextNogil()
    2103             :   #define __Pyx_RefNannyFinishContext()
    2104             :   #define __Pyx_INCREF(r) Py_INCREF(r)
    2105             :   #define __Pyx_DECREF(r) Py_DECREF(r)
    2106             :   #define __Pyx_GOTREF(r)
    2107             :   #define __Pyx_GIVEREF(r)
    2108             :   #define __Pyx_XINCREF(r) Py_XINCREF(r)
    2109             :   #define __Pyx_XDECREF(r) Py_XDECREF(r)
    2110             :   #define __Pyx_XGOTREF(r)
    2111             :   #define __Pyx_XGIVEREF(r)
    2112             : #endif
    2113             : #define __Pyx_Py_XDECREF_SET(r, v) do {\
    2114             :         PyObject *tmp = (PyObject *) r;\
    2115             :         r = v; Py_XDECREF(tmp);\
    2116             :     } while (0)
    2117             : #define __Pyx_XDECREF_SET(r, v) do {\
    2118             :         PyObject *tmp = (PyObject *) r;\
    2119             :         r = v; __Pyx_XDECREF(tmp);\
    2120             :     } while (0)
    2121             : #define __Pyx_DECREF_SET(r, v) do {\
    2122             :         PyObject *tmp = (PyObject *) r;\
    2123             :         r = v; __Pyx_DECREF(tmp);\
    2124             :     } while (0)
    2125             : #define __Pyx_CLEAR(r)    do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
    2126             : #define __Pyx_XCLEAR(r)   do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
    2127             : 
    2128             : /* PyErrExceptionMatches.proto */
    2129             : #if CYTHON_FAST_THREAD_STATE
    2130             : #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
    2131             : static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
    2132             : #else
    2133             : #define __Pyx_PyErr_ExceptionMatches(err)  PyErr_ExceptionMatches(err)
    2134             : #endif
    2135             : 
    2136             : /* PyThreadStateGet.proto */
    2137             : #if CYTHON_FAST_THREAD_STATE
    2138             : #define __Pyx_PyThreadState_declare  PyThreadState *__pyx_tstate;
    2139             : #define __Pyx_PyThreadState_assign  __pyx_tstate = __Pyx_PyThreadState_Current;
    2140             : #if PY_VERSION_HEX >= 0x030C00A6
    2141             : #define __Pyx_PyErr_Occurred()  (__pyx_tstate->current_exception != NULL)
    2142             : #define __Pyx_PyErr_CurrentExceptionType()  (__pyx_tstate->current_exception ? (PyObject*) Py_TYPE(__pyx_tstate->current_exception) : (PyObject*) NULL)
    2143             : #else
    2144             : #define __Pyx_PyErr_Occurred()  (__pyx_tstate->curexc_type != NULL)
    2145             : #define __Pyx_PyErr_CurrentExceptionType()  (__pyx_tstate->curexc_type)
    2146             : #endif
    2147             : #else
    2148             : #define __Pyx_PyThreadState_declare
    2149             : #define __Pyx_PyThreadState_assign
    2150             : #define __Pyx_PyErr_Occurred()  (PyErr_Occurred() != NULL)
    2151             : #define __Pyx_PyErr_CurrentExceptionType()  PyErr_Occurred()
    2152             : #endif
    2153             : 
    2154             : /* PyErrFetchRestore.proto */
    2155             : #if CYTHON_FAST_THREAD_STATE
    2156             : #define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
    2157             : #define __Pyx_ErrRestoreWithState(type, value, tb)  __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
    2158             : #define __Pyx_ErrFetchWithState(type, value, tb)    __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
    2159             : #define __Pyx_ErrRestore(type, value, tb)  __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
    2160             : #define __Pyx_ErrFetch(type, value, tb)    __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
    2161             : static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
    2162             : static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
    2163             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A6
    2164             : #define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
    2165             : #else
    2166             : #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
    2167             : #endif
    2168             : #else
    2169             : #define __Pyx_PyErr_Clear() PyErr_Clear()
    2170             : #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
    2171             : #define __Pyx_ErrRestoreWithState(type, value, tb)  PyErr_Restore(type, value, tb)
    2172             : #define __Pyx_ErrFetchWithState(type, value, tb)  PyErr_Fetch(type, value, tb)
    2173             : #define __Pyx_ErrRestoreInState(tstate, type, value, tb)  PyErr_Restore(type, value, tb)
    2174             : #define __Pyx_ErrFetchInState(tstate, type, value, tb)  PyErr_Fetch(type, value, tb)
    2175             : #define __Pyx_ErrRestore(type, value, tb)  PyErr_Restore(type, value, tb)
    2176             : #define __Pyx_ErrFetch(type, value, tb)  PyErr_Fetch(type, value, tb)
    2177             : #endif
    2178             : 
    2179             : /* PyObjectGetAttrStr.proto */
    2180             : #if CYTHON_USE_TYPE_SLOTS
    2181             : static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
    2182             : #else
    2183             : #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
    2184             : #endif
    2185             : 
    2186             : /* PyObjectGetAttrStrNoError.proto */
    2187             : static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name);
    2188             : 
    2189             : /* GetBuiltinName.proto */
    2190             : static PyObject *__Pyx_GetBuiltinName(PyObject *name);
    2191             : 
    2192             : /* TupleAndListFromArray.proto */
    2193             : #if CYTHON_COMPILING_IN_CPYTHON
    2194             : static CYTHON_INLINE PyObject* __Pyx_PyList_FromArray(PyObject *const *src, Py_ssize_t n);
    2195             : static CYTHON_INLINE PyObject* __Pyx_PyTuple_FromArray(PyObject *const *src, Py_ssize_t n);
    2196             : #endif
    2197             : 
    2198             : /* IncludeStringH.proto */
    2199             : #include <string.h>
    2200             : 
    2201             : /* BytesEquals.proto */
    2202             : static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals);
    2203             : 
    2204             : /* UnicodeEquals.proto */
    2205             : static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals);
    2206             : 
    2207             : /* fastcall.proto */
    2208             : #if CYTHON_AVOID_BORROWED_REFS
    2209             :     #define __Pyx_Arg_VARARGS(args, i) PySequence_GetItem(args, i)
    2210             : #elif CYTHON_ASSUME_SAFE_MACROS
    2211             :     #define __Pyx_Arg_VARARGS(args, i) PyTuple_GET_ITEM(args, i)
    2212             : #else
    2213             :     #define __Pyx_Arg_VARARGS(args, i) PyTuple_GetItem(args, i)
    2214             : #endif
    2215             : #if CYTHON_AVOID_BORROWED_REFS
    2216             :     #define __Pyx_Arg_NewRef_VARARGS(arg) __Pyx_NewRef(arg)
    2217             :     #define __Pyx_Arg_XDECREF_VARARGS(arg) Py_XDECREF(arg)
    2218             : #else
    2219             :     #define __Pyx_Arg_NewRef_VARARGS(arg) arg
    2220             :     #define __Pyx_Arg_XDECREF_VARARGS(arg)
    2221             : #endif
    2222             : #define __Pyx_NumKwargs_VARARGS(kwds) PyDict_Size(kwds)
    2223             : #define __Pyx_KwValues_VARARGS(args, nargs) NULL
    2224             : #define __Pyx_GetKwValue_VARARGS(kw, kwvalues, s) __Pyx_PyDict_GetItemStrWithError(kw, s)
    2225             : #define __Pyx_KwargsAsDict_VARARGS(kw, kwvalues) PyDict_Copy(kw)
    2226             : #if CYTHON_METH_FASTCALL
    2227             :     #define __Pyx_Arg_FASTCALL(args, i) args[i]
    2228             :     #define __Pyx_NumKwargs_FASTCALL(kwds) PyTuple_GET_SIZE(kwds)
    2229             :     #define __Pyx_KwValues_FASTCALL(args, nargs) ((args) + (nargs))
    2230             :     static CYTHON_INLINE PyObject * __Pyx_GetKwValue_FASTCALL(PyObject *kwnames, PyObject *const *kwvalues, PyObject *s);
    2231             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030d0000
    2232             :     CYTHON_UNUSED static PyObject *__Pyx_KwargsAsDict_FASTCALL(PyObject *kwnames, PyObject *const *kwvalues);
    2233             :   #else
    2234             :     #define __Pyx_KwargsAsDict_FASTCALL(kw, kwvalues) _PyStack_AsDict(kwvalues, kw)
    2235             :   #endif
    2236             :     #define __Pyx_Arg_NewRef_FASTCALL(arg) arg  /* no-op, __Pyx_Arg_FASTCALL is direct and this needs
    2237             :                                                    to have the same reference counting */
    2238             :     #define __Pyx_Arg_XDECREF_FASTCALL(arg)
    2239             : #else
    2240             :     #define __Pyx_Arg_FASTCALL __Pyx_Arg_VARARGS
    2241             :     #define __Pyx_NumKwargs_FASTCALL __Pyx_NumKwargs_VARARGS
    2242             :     #define __Pyx_KwValues_FASTCALL __Pyx_KwValues_VARARGS
    2243             :     #define __Pyx_GetKwValue_FASTCALL __Pyx_GetKwValue_VARARGS
    2244             :     #define __Pyx_KwargsAsDict_FASTCALL __Pyx_KwargsAsDict_VARARGS
    2245             :     #define __Pyx_Arg_NewRef_FASTCALL(arg) __Pyx_Arg_NewRef_VARARGS(arg)
    2246             :     #define __Pyx_Arg_XDECREF_FASTCALL(arg) __Pyx_Arg_XDECREF_VARARGS(arg)
    2247             : #endif
    2248             : #if CYTHON_COMPILING_IN_CPYTHON && CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    2249             : #define __Pyx_ArgsSlice_VARARGS(args, start, stop) __Pyx_PyTuple_FromArray(&__Pyx_Arg_VARARGS(args, start), stop - start)
    2250             : #define __Pyx_ArgsSlice_FASTCALL(args, start, stop) __Pyx_PyTuple_FromArray(&__Pyx_Arg_FASTCALL(args, start), stop - start)
    2251             : #else
    2252             : #define __Pyx_ArgsSlice_VARARGS(args, start, stop) PyTuple_GetSlice(args, start, stop)
    2253             : #define __Pyx_ArgsSlice_FASTCALL(args, start, stop) PyTuple_GetSlice(args, start, stop)
    2254             : #endif
    2255             : 
    2256             : /* RaiseArgTupleInvalid.proto */
    2257             : static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact,
    2258             :     Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
    2259             : 
    2260             : /* RaiseDoubleKeywords.proto */
    2261             : static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name);
    2262             : 
    2263             : /* ParseKeywords.proto */
    2264             : static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject *const *kwvalues,
    2265             :     PyObject **argnames[],
    2266             :     PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,
    2267             :     const char* function_name);
    2268             : 
    2269             : /* ArgTypeTest.proto */
    2270             : #define __Pyx_ArgTypeTest(obj, type, none_allowed, name, exact)\
    2271             :     ((likely(__Pyx_IS_TYPE(obj, type) | (none_allowed && (obj == Py_None)))) ? 1 :\
    2272             :         __Pyx__ArgTypeTest(obj, type, name, exact))
    2273             : static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact);
    2274             : 
    2275             : /* RaiseException.proto */
    2276             : static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
    2277             : 
    2278             : /* PyFunctionFastCall.proto */
    2279             : #if CYTHON_FAST_PYCALL
    2280             : #if !CYTHON_VECTORCALL
    2281             : #define __Pyx_PyFunction_FastCall(func, args, nargs)\
    2282             :     __Pyx_PyFunction_FastCallDict((func), (args), (nargs), NULL)
    2283             : static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs);
    2284             : #endif
    2285             : #define __Pyx_BUILD_ASSERT_EXPR(cond)\
    2286             :     (sizeof(char [1 - 2*!(cond)]) - 1)
    2287             : #ifndef Py_MEMBER_SIZE
    2288             : #define Py_MEMBER_SIZE(type, member) sizeof(((type *)0)->member)
    2289             : #endif
    2290             : #if !CYTHON_VECTORCALL
    2291             : #if PY_VERSION_HEX >= 0x03080000
    2292             :   #include "frameobject.h"
    2293             : #if PY_VERSION_HEX >= 0x030b00a6 && !CYTHON_COMPILING_IN_LIMITED_API
    2294             :   #ifndef Py_BUILD_CORE
    2295             :     #define Py_BUILD_CORE 1
    2296             :   #endif
    2297             :   #include "internal/pycore_frame.h"
    2298             : #endif
    2299             :   #define __Pxy_PyFrame_Initialize_Offsets()
    2300             :   #define __Pyx_PyFrame_GetLocalsplus(frame)  ((frame)->f_localsplus)
    2301             : #else
    2302             :   static size_t __pyx_pyframe_localsplus_offset = 0;
    2303             :   #include "frameobject.h"
    2304             :   #define __Pxy_PyFrame_Initialize_Offsets()\
    2305             :     ((void)__Pyx_BUILD_ASSERT_EXPR(sizeof(PyFrameObject) == offsetof(PyFrameObject, f_localsplus) + Py_MEMBER_SIZE(PyFrameObject, f_localsplus)),\
    2306             :      (void)(__pyx_pyframe_localsplus_offset = ((size_t)PyFrame_Type.tp_basicsize) - Py_MEMBER_SIZE(PyFrameObject, f_localsplus)))
    2307             :   #define __Pyx_PyFrame_GetLocalsplus(frame)\
    2308             :     (assert(__pyx_pyframe_localsplus_offset), (PyObject **)(((char *)(frame)) + __pyx_pyframe_localsplus_offset))
    2309             : #endif
    2310             : #endif
    2311             : #endif
    2312             : 
    2313             : /* PyObjectCall.proto */
    2314             : #if CYTHON_COMPILING_IN_CPYTHON
    2315             : static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
    2316             : #else
    2317             : #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
    2318             : #endif
    2319             : 
    2320             : /* PyObjectCallMethO.proto */
    2321             : #if CYTHON_COMPILING_IN_CPYTHON
    2322             : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg);
    2323             : #endif
    2324             : 
    2325             : /* PyObjectFastCall.proto */
    2326             : #define __Pyx_PyObject_FastCall(func, args, nargs)  __Pyx_PyObject_FastCallDict(func, args, (size_t)(nargs), NULL)
    2327             : static CYTHON_INLINE PyObject* __Pyx_PyObject_FastCallDict(PyObject *func, PyObject **args, size_t nargs, PyObject *kwargs);
    2328             : 
    2329             : /* RaiseUnexpectedTypeError.proto */
    2330             : static int __Pyx_RaiseUnexpectedTypeError(const char *expected, PyObject *obj);
    2331             : 
    2332             : /* GCCDiagnostics.proto */
    2333             : #if !defined(__INTEL_COMPILER) && defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
    2334             : #define __Pyx_HAS_GCC_DIAGNOSTIC
    2335             : #endif
    2336             : 
    2337             : /* BuildPyUnicode.proto */
    2338             : static PyObject* __Pyx_PyUnicode_BuildFromAscii(Py_ssize_t ulength, char* chars, int clength,
    2339             :                                                 int prepend_sign, char padding_char);
    2340             : 
    2341             : /* CIntToPyUnicode.proto */
    2342             : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_From_int(int value, Py_ssize_t width, char padding_char, char format_char);
    2343             : 
    2344             : /* CIntToPyUnicode.proto */
    2345             : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_From_Py_ssize_t(Py_ssize_t value, Py_ssize_t width, char padding_char, char format_char);
    2346             : 
    2347             : /* JoinPyUnicode.proto */
    2348             : static PyObject* __Pyx_PyUnicode_Join(PyObject* value_tuple, Py_ssize_t value_count, Py_ssize_t result_ulength,
    2349             :                                       Py_UCS4 max_char);
    2350             : 
    2351             : /* StrEquals.proto */
    2352             : #if PY_MAJOR_VERSION >= 3
    2353             : #define __Pyx_PyString_Equals __Pyx_PyUnicode_Equals
    2354             : #else
    2355             : #define __Pyx_PyString_Equals __Pyx_PyBytes_Equals
    2356             : #endif
    2357             : 
    2358             : /* PyObjectFormatSimple.proto */
    2359             : #if CYTHON_COMPILING_IN_PYPY
    2360             :     #define __Pyx_PyObject_FormatSimple(s, f) (\
    2361             :         likely(PyUnicode_CheckExact(s)) ? (Py_INCREF(s), s) :\
    2362             :         PyObject_Format(s, f))
    2363             : #elif PY_MAJOR_VERSION < 3
    2364             :     #define __Pyx_PyObject_FormatSimple(s, f) (\
    2365             :         likely(PyUnicode_CheckExact(s)) ? (Py_INCREF(s), s) :\
    2366             :         likely(PyString_CheckExact(s)) ? PyUnicode_FromEncodedObject(s, NULL, "strict") :\
    2367             :         PyObject_Format(s, f))
    2368             : #elif CYTHON_USE_TYPE_SLOTS
    2369             :     #define __Pyx_PyObject_FormatSimple(s, f) (\
    2370             :         likely(PyUnicode_CheckExact(s)) ? (Py_INCREF(s), s) :\
    2371             :         likely(PyLong_CheckExact(s)) ? PyLong_Type.tp_repr(s) :\
    2372             :         likely(PyFloat_CheckExact(s)) ? PyFloat_Type.tp_repr(s) :\
    2373             :         PyObject_Format(s, f))
    2374             : #else
    2375             :     #define __Pyx_PyObject_FormatSimple(s, f) (\
    2376             :         likely(PyUnicode_CheckExact(s)) ? (Py_INCREF(s), s) :\
    2377             :         PyObject_Format(s, f))
    2378             : #endif
    2379             : 
    2380             : CYTHON_UNUSED static int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
    2381             : static PyObject *__pyx_array_get_memview(struct __pyx_array_obj *); /*proto*/
    2382             : /* GetAttr.proto */
    2383             : static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *);
    2384             : 
    2385             : /* GetItemInt.proto */
    2386             : #define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    2387             :     (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    2388             :     __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\
    2389             :     (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\
    2390             :                __Pyx_GetItemInt_Generic(o, to_py_func(i))))
    2391             : #define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    2392             :     (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    2393             :     __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
    2394             :     (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL))
    2395             : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
    2396             :                                                               int wraparound, int boundscheck);
    2397             : #define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    2398             :     (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    2399             :     __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
    2400             :     (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL))
    2401             : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
    2402             :                                                               int wraparound, int boundscheck);
    2403             : static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j);
    2404             : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
    2405             :                                                      int is_list, int wraparound, int boundscheck);
    2406             : 
    2407             : /* PyObjectCallOneArg.proto */
    2408             : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg);
    2409             : 
    2410             : /* ObjectGetItem.proto */
    2411             : #if CYTHON_USE_TYPE_SLOTS
    2412             : static CYTHON_INLINE PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject *key);
    2413             : #else
    2414             : #define __Pyx_PyObject_GetItem(obj, key)  PyObject_GetItem(obj, key)
    2415             : #endif
    2416             : 
    2417             : /* KeywordStringCheck.proto */
    2418             : static int __Pyx_CheckKeywordStrings(PyObject *kw, const char* function_name, int kw_allowed);
    2419             : 
    2420             : /* DivInt[Py_ssize_t].proto */
    2421             : static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t, Py_ssize_t);
    2422             : 
    2423             : /* UnaryNegOverflows.proto */
    2424             : #define __Pyx_UNARY_NEG_WOULD_OVERFLOW(x)\
    2425             :         (((x) < 0) & ((unsigned long)(x) == 0-(unsigned long)(x)))
    2426             : 
    2427             : /* GetAttr3.proto */
    2428             : static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *, PyObject *, PyObject *);
    2429             : 
    2430             : /* PyDictVersioning.proto */
    2431             : #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
    2432             : #define __PYX_DICT_VERSION_INIT  ((PY_UINT64_T) -1)
    2433             : #define __PYX_GET_DICT_VERSION(dict)  (((PyDictObject*)(dict))->ma_version_tag)
    2434             : #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
    2435             :     (version_var) = __PYX_GET_DICT_VERSION(dict);\
    2436             :     (cache_var) = (value);
    2437             : #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
    2438             :     static PY_UINT64_T __pyx_dict_version = 0;\
    2439             :     static PyObject *__pyx_dict_cached_value = NULL;\
    2440             :     if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
    2441             :         (VAR) = __pyx_dict_cached_value;\
    2442             :     } else {\
    2443             :         (VAR) = __pyx_dict_cached_value = (LOOKUP);\
    2444             :         __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
    2445             :     }\
    2446             : }
    2447             : static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
    2448             : static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
    2449             : static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
    2450             : #else
    2451             : #define __PYX_GET_DICT_VERSION(dict)  (0)
    2452             : #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
    2453             : #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP)  (VAR) = (LOOKUP);
    2454             : #endif
    2455             : 
    2456             : /* GetModuleGlobalName.proto */
    2457             : #if CYTHON_USE_DICT_VERSIONS
    2458             : #define __Pyx_GetModuleGlobalName(var, name)  do {\
    2459             :     static PY_UINT64_T __pyx_dict_version = 0;\
    2460             :     static PyObject *__pyx_dict_cached_value = NULL;\
    2461             :     (var) = (likely(__pyx_dict_version == __PYX_GET_DICT_VERSION(__pyx_d))) ?\
    2462             :         (likely(__pyx_dict_cached_value) ? __Pyx_NewRef(__pyx_dict_cached_value) : __Pyx_GetBuiltinName(name)) :\
    2463             :         __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
    2464             : } while(0)
    2465             : #define __Pyx_GetModuleGlobalNameUncached(var, name)  do {\
    2466             :     PY_UINT64_T __pyx_dict_version;\
    2467             :     PyObject *__pyx_dict_cached_value;\
    2468             :     (var) = __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
    2469             : } while(0)
    2470             : static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value);
    2471             : #else
    2472             : #define __Pyx_GetModuleGlobalName(var, name)  (var) = __Pyx__GetModuleGlobalName(name)
    2473             : #define __Pyx_GetModuleGlobalNameUncached(var, name)  (var) = __Pyx__GetModuleGlobalName(name)
    2474             : static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name);
    2475             : #endif
    2476             : 
    2477             : /* AssertionsEnabled.proto */
    2478             : #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
    2479             :   #define __Pyx_init_assertions_enabled()  (0)
    2480             :   #define __pyx_assertions_enabled()  (1)
    2481             : #elif CYTHON_COMPILING_IN_LIMITED_API  ||  (CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030C0000)
    2482             :   static int __pyx_assertions_enabled_flag;
    2483             :   #define __pyx_assertions_enabled() (__pyx_assertions_enabled_flag)
    2484           3 :   static int __Pyx_init_assertions_enabled(void) {
    2485           3 :     PyObject *builtins, *debug, *debug_str;
    2486           3 :     int flag;
    2487           3 :     builtins = PyEval_GetBuiltins();
    2488           3 :     if (!builtins) goto bad;
    2489           3 :     debug_str = PyUnicode_FromStringAndSize("__debug__", 9);
    2490           3 :     if (!debug_str) goto bad;
    2491           3 :     debug = PyObject_GetItem(builtins, debug_str);
    2492           3 :     Py_DECREF(debug_str);
    2493           3 :     if (!debug) goto bad;
    2494           3 :     flag = PyObject_IsTrue(debug);
    2495           3 :     Py_DECREF(debug);
    2496           3 :     if (flag == -1) goto bad;
    2497           3 :     __pyx_assertions_enabled_flag = flag;
    2498           3 :     return 0;
    2499           0 :   bad:
    2500           0 :     __pyx_assertions_enabled_flag = 1;
    2501           0 :     return -1;
    2502             :   }
    2503             : #else
    2504             :   #define __Pyx_init_assertions_enabled()  (0)
    2505             :   #define __pyx_assertions_enabled()  (!Py_OptimizeFlag)
    2506             : #endif
    2507             : 
    2508             : /* RaiseTooManyValuesToUnpack.proto */
    2509             : static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected);
    2510             : 
    2511             : /* RaiseNeedMoreValuesToUnpack.proto */
    2512             : static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index);
    2513             : 
    2514             : /* RaiseNoneIterError.proto */
    2515             : static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void);
    2516             : 
    2517             : /* ExtTypeTest.proto */
    2518             : static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type);
    2519             : 
    2520             : /* GetTopmostException.proto */
    2521             : #if CYTHON_USE_EXC_INFO_STACK && CYTHON_FAST_THREAD_STATE
    2522             : static _PyErr_StackItem * __Pyx_PyErr_GetTopmostException(PyThreadState *tstate);
    2523             : #endif
    2524             : 
    2525             : /* SaveResetException.proto */
    2526             : #if CYTHON_FAST_THREAD_STATE
    2527             : #define __Pyx_ExceptionSave(type, value, tb)  __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
    2528             : static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
    2529             : #define __Pyx_ExceptionReset(type, value, tb)  __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
    2530             : static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
    2531             : #else
    2532             : #define __Pyx_ExceptionSave(type, value, tb)   PyErr_GetExcInfo(type, value, tb)
    2533             : #define __Pyx_ExceptionReset(type, value, tb)  PyErr_SetExcInfo(type, value, tb)
    2534             : #endif
    2535             : 
    2536             : /* GetException.proto */
    2537             : #if CYTHON_FAST_THREAD_STATE
    2538             : #define __Pyx_GetException(type, value, tb)  __Pyx__GetException(__pyx_tstate, type, value, tb)
    2539             : static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
    2540             : #else
    2541             : static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
    2542             : #endif
    2543             : 
    2544             : /* SwapException.proto */
    2545             : #if CYTHON_FAST_THREAD_STATE
    2546             : #define __Pyx_ExceptionSwap(type, value, tb)  __Pyx__ExceptionSwap(__pyx_tstate, type, value, tb)
    2547             : static CYTHON_INLINE void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
    2548             : #else
    2549             : static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb);
    2550             : #endif
    2551             : 
    2552             : /* Import.proto */
    2553             : static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level);
    2554             : 
    2555             : /* ImportDottedModule.proto */
    2556             : static PyObject *__Pyx_ImportDottedModule(PyObject *name, PyObject *parts_tuple);
    2557             : #if PY_MAJOR_VERSION >= 3
    2558             : static PyObject *__Pyx_ImportDottedModule_WalkParts(PyObject *module, PyObject *name, PyObject *parts_tuple);
    2559             : #endif
    2560             : 
    2561             : /* FastTypeChecks.proto */
    2562             : #if CYTHON_COMPILING_IN_CPYTHON
    2563             : #define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
    2564             : #define __Pyx_TypeCheck2(obj, type1, type2) __Pyx_IsAnySubtype2(Py_TYPE(obj), (PyTypeObject *)type1, (PyTypeObject *)type2)
    2565             : static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
    2566             : static CYTHON_INLINE int __Pyx_IsAnySubtype2(PyTypeObject *cls, PyTypeObject *a, PyTypeObject *b);
    2567             : static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
    2568             : static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
    2569             : #else
    2570             : #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
    2571             : #define __Pyx_TypeCheck2(obj, type1, type2) (PyObject_TypeCheck(obj, (PyTypeObject *)type1) || PyObject_TypeCheck(obj, (PyTypeObject *)type2))
    2572             : #define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
    2573             : #define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
    2574             : #endif
    2575             : #define __Pyx_PyErr_ExceptionMatches2(err1, err2)  __Pyx_PyErr_GivenExceptionMatches2(__Pyx_PyErr_CurrentExceptionType(), err1, err2)
    2576             : #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)
    2577             : 
    2578             : CYTHON_UNUSED static int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
    2579             : /* ListCompAppend.proto */
    2580             : #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
    2581           0 : static CYTHON_INLINE int __Pyx_ListComp_Append(PyObject* list, PyObject* x) {
    2582           0 :     PyListObject* L = (PyListObject*) list;
    2583           0 :     Py_ssize_t len = Py_SIZE(list);
    2584           0 :     if (likely(L->allocated > len)) {
    2585           0 :         Py_INCREF(x);
    2586             :         #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030d0000
    2587             :         L->ob_item[len] = x;
    2588             :         #else
    2589           0 :         PyList_SET_ITEM(list, len, x);
    2590             :         #endif
    2591           0 :         __Pyx_SET_SIZE(list, len + 1);
    2592           0 :         return 0;
    2593             :     }
    2594           0 :     return PyList_Append(list, x);
    2595             : }
    2596             : #else
    2597             : #define __Pyx_ListComp_Append(L,x) PyList_Append(L,x)
    2598             : #endif
    2599             : 
    2600             : /* PySequenceMultiply.proto */
    2601             : #define __Pyx_PySequence_Multiply_Left(mul, seq)  __Pyx_PySequence_Multiply(seq, mul)
    2602             : static CYTHON_INLINE PyObject* __Pyx_PySequence_Multiply(PyObject *seq, Py_ssize_t mul);
    2603             : 
    2604             : /* SetItemInt.proto */
    2605             : #define __Pyx_SetItemInt(o, i, v, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    2606             :     (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    2607             :     __Pyx_SetItemInt_Fast(o, (Py_ssize_t)i, v, is_list, wraparound, boundscheck) :\
    2608             :     (is_list ? (PyErr_SetString(PyExc_IndexError, "list assignment index out of range"), -1) :\
    2609             :                __Pyx_SetItemInt_Generic(o, to_py_func(i), v)))
    2610             : static int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v);
    2611             : static CYTHON_INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v,
    2612             :                                                int is_list, int wraparound, int boundscheck);
    2613             : 
    2614             : /* RaiseUnboundLocalError.proto */
    2615             : static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname);
    2616             : 
    2617             : /* DivInt[long].proto */
    2618             : static CYTHON_INLINE long __Pyx_div_long(long, long);
    2619             : 
    2620             : /* PySequenceContains.proto */
    2621           0 : static CYTHON_INLINE int __Pyx_PySequence_ContainsTF(PyObject* item, PyObject* seq, int eq) {
    2622           0 :     int result = PySequence_Contains(seq, item);
    2623           0 :     return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
    2624             : }
    2625             : 
    2626             : /* ImportFrom.proto */
    2627             : static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name);
    2628             : 
    2629             : /* HasAttr.proto */
    2630             : static CYTHON_INLINE int __Pyx_HasAttr(PyObject *, PyObject *);
    2631             : 
    2632             : /* PyDictContains.proto */
    2633           0 : static CYTHON_INLINE int __Pyx_PyDict_ContainsTF(PyObject* item, PyObject* dict, int eq) {
    2634           0 :     int result = PyDict_Contains(dict, item);
    2635           0 :     return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
    2636             : }
    2637             : 
    2638             : /* DictGetItem.proto */
    2639             : #if PY_MAJOR_VERSION >= 3 && !CYTHON_COMPILING_IN_PYPY
    2640             : static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key);
    2641             : #define __Pyx_PyObject_Dict_GetItem(obj, name)\
    2642             :     (likely(PyDict_CheckExact(obj)) ?\
    2643             :      __Pyx_PyDict_GetItem(obj, name) : PyObject_GetItem(obj, name))
    2644             : #else
    2645             : #define __Pyx_PyDict_GetItem(d, key) PyObject_GetItem(d, key)
    2646             : #define __Pyx_PyObject_Dict_GetItem(obj, name)  PyObject_GetItem(obj, name)
    2647             : #endif
    2648             : 
    2649             : /* UnicodeAsUCS4.proto */
    2650             : static CYTHON_INLINE Py_UCS4 __Pyx_PyUnicode_AsPy_UCS4(PyObject*);
    2651             : 
    2652             : /* object_ord.proto */
    2653             : #if PY_MAJOR_VERSION >= 3
    2654             : #define __Pyx_PyObject_Ord(c)\
    2655             :     (likely(PyUnicode_Check(c)) ? (long)__Pyx_PyUnicode_AsPy_UCS4(c) : __Pyx__PyObject_Ord(c))
    2656             : #else
    2657             : #define __Pyx_PyObject_Ord(c) __Pyx__PyObject_Ord(c)
    2658             : #endif
    2659             : static long __Pyx__PyObject_Ord(PyObject* c);
    2660             : 
    2661             : /* memoryview_get_from_buffer.proto */
    2662             : #if !CYTHON_COMPILING_IN_LIMITED_API || CYTHON_LIMITED_API >= 0x030b0000
    2663             : #define __Pyx_PyMemoryView_Get_itemsize(o) PyMemoryView_GET_BUFFER(o)->itemsize
    2664             : #else
    2665             :  // can't get format like this unfortunately. It's unicode via getattr
    2666             : static Py_ssize_t __Pyx_PyMemoryView_Get_itemsize(PyObject *obj);
    2667             : #endif
    2668             : 
    2669             : /* memoryview_get_from_buffer.proto */
    2670             : #if !CYTHON_COMPILING_IN_LIMITED_API || CYTHON_LIMITED_API >= 0x030b0000
    2671             : #define __Pyx_PyMemoryView_Get_ndim(o) PyMemoryView_GET_BUFFER(o)->ndim
    2672             : #else
    2673             :  // can't get format like this unfortunately. It's unicode via getattr
    2674             : static int __Pyx_PyMemoryView_Get_ndim(PyObject *obj);
    2675             : #endif
    2676             : 
    2677             : /* IterFinish.proto */
    2678             : static CYTHON_INLINE int __Pyx_IterFinish(void);
    2679             : 
    2680             : /* PyObjectCallNoArg.proto */
    2681             : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func);
    2682             : 
    2683             : /* PyObjectGetMethod.proto */
    2684             : static int __Pyx_PyObject_GetMethod(PyObject *obj, PyObject *name, PyObject **method);
    2685             : 
    2686             : /* PyObjectCallMethod0.proto */
    2687             : static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name);
    2688             : 
    2689             : /* UnpackItemEndCheck.proto */
    2690             : static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected);
    2691             : 
    2692             : /* UnpackTupleError.proto */
    2693             : static void __Pyx_UnpackTupleError(PyObject *, Py_ssize_t index);
    2694             : 
    2695             : /* UnpackTuple2.proto */
    2696             : #define __Pyx_unpack_tuple2(tuple, value1, value2, is_tuple, has_known_size, decref_tuple)\
    2697             :     (likely(is_tuple || PyTuple_Check(tuple)) ?\
    2698             :         (likely(has_known_size || PyTuple_GET_SIZE(tuple) == 2) ?\
    2699             :             __Pyx_unpack_tuple2_exact(tuple, value1, value2, decref_tuple) :\
    2700             :             (__Pyx_UnpackTupleError(tuple, 2), -1)) :\
    2701             :         __Pyx_unpack_tuple2_generic(tuple, value1, value2, has_known_size, decref_tuple))
    2702             : static CYTHON_INLINE int __Pyx_unpack_tuple2_exact(
    2703             :     PyObject* tuple, PyObject** value1, PyObject** value2, int decref_tuple);
    2704             : static int __Pyx_unpack_tuple2_generic(
    2705             :     PyObject* tuple, PyObject** value1, PyObject** value2, int has_known_size, int decref_tuple);
    2706             : 
    2707             : /* dict_iter.proto */
    2708             : static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* dict, int is_dict, PyObject* method_name,
    2709             :                                                    Py_ssize_t* p_orig_length, int* p_is_dict);
    2710             : static CYTHON_INLINE int __Pyx_dict_iter_next(PyObject* dict_or_iter, Py_ssize_t orig_length, Py_ssize_t* ppos,
    2711             :                                               PyObject** pkey, PyObject** pvalue, PyObject** pitem, int is_dict);
    2712             : 
    2713             : /* ListExtend.proto */
    2714           0 : static CYTHON_INLINE int __Pyx_PyList_Extend(PyObject* L, PyObject* v) {
    2715             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030d0000
    2716           0 :     PyObject* none = _PyList_Extend((PyListObject*)L, v);
    2717           0 :     if (unlikely(!none))
    2718             :         return -1;
    2719           0 :     Py_DECREF(none);
    2720             :     return 0;
    2721             : #else
    2722             :     return PyList_SetSlice(L, PY_SSIZE_T_MAX, PY_SSIZE_T_MAX, v);
    2723             : #endif
    2724             : }
    2725             : 
    2726             : /* py_dict_values.proto */
    2727             : static CYTHON_INLINE PyObject* __Pyx_PyDict_Values(PyObject* d);
    2728             : 
    2729             : /* UnpackUnboundCMethod.proto */
    2730             : typedef struct {
    2731             :     PyObject *type;
    2732             :     PyObject **method_name;
    2733             :     PyCFunction func;
    2734             :     PyObject *method;
    2735             :     int flag;
    2736             : } __Pyx_CachedCFunction;
    2737             : 
    2738             : /* CallUnboundCMethod0.proto */
    2739             : static PyObject* __Pyx__CallUnboundCMethod0(__Pyx_CachedCFunction* cfunc, PyObject* self);
    2740             : #if CYTHON_COMPILING_IN_CPYTHON
    2741             : #define __Pyx_CallUnboundCMethod0(cfunc, self)\
    2742             :     (likely((cfunc)->func) ?\
    2743             :         (likely((cfunc)->flag == METH_NOARGS) ?  (*((cfunc)->func))(self, NULL) :\
    2744             :          (PY_VERSION_HEX >= 0x030600B1 && likely((cfunc)->flag == METH_FASTCALL) ?\
    2745             :             (PY_VERSION_HEX >= 0x030700A0 ?\
    2746             :                 (*(__Pyx_PyCFunctionFast)(void*)(PyCFunction)(cfunc)->func)(self, &__pyx_empty_tuple, 0) :\
    2747             :                 (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)(cfunc)->func)(self, &__pyx_empty_tuple, 0, NULL)) :\
    2748             :           (PY_VERSION_HEX >= 0x030700A0 && (cfunc)->flag == (METH_FASTCALL | METH_KEYWORDS) ?\
    2749             :             (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)(cfunc)->func)(self, &__pyx_empty_tuple, 0, NULL) :\
    2750             :             (likely((cfunc)->flag == (METH_VARARGS | METH_KEYWORDS)) ?  ((*(PyCFunctionWithKeywords)(void*)(PyCFunction)(cfunc)->func)(self, __pyx_empty_tuple, NULL)) :\
    2751             :                ((cfunc)->flag == METH_VARARGS ?  (*((cfunc)->func))(self, __pyx_empty_tuple) :\
    2752             :                __Pyx__CallUnboundCMethod0(cfunc, self)))))) :\
    2753             :         __Pyx__CallUnboundCMethod0(cfunc, self))
    2754             : #else
    2755             : #define __Pyx_CallUnboundCMethod0(cfunc, self)  __Pyx__CallUnboundCMethod0(cfunc, self)
    2756             : #endif
    2757             : 
    2758             : /* dict_getitem_default.proto */
    2759             : static PyObject* __Pyx_PyDict_GetItemDefault(PyObject* d, PyObject* key, PyObject* default_value);
    2760             : 
    2761             : /* CallUnboundCMethod1.proto */
    2762             : static PyObject* __Pyx__CallUnboundCMethod1(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg);
    2763             : #if CYTHON_COMPILING_IN_CPYTHON
    2764             : static CYTHON_INLINE PyObject* __Pyx_CallUnboundCMethod1(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg);
    2765             : #else
    2766             : #define __Pyx_CallUnboundCMethod1(cfunc, self, arg)  __Pyx__CallUnboundCMethod1(cfunc, self, arg)
    2767             : #endif
    2768             : 
    2769             : /* CallUnboundCMethod2.proto */
    2770             : static PyObject* __Pyx__CallUnboundCMethod2(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg1, PyObject* arg2);
    2771             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030600B1
    2772             : static CYTHON_INLINE PyObject *__Pyx_CallUnboundCMethod2(__Pyx_CachedCFunction *cfunc, PyObject *self, PyObject *arg1, PyObject *arg2);
    2773             : #else
    2774             : #define __Pyx_CallUnboundCMethod2(cfunc, self, arg1, arg2)  __Pyx__CallUnboundCMethod2(cfunc, self, arg1, arg2)
    2775             : #endif
    2776             : 
    2777             : /* ListAppend.proto */
    2778             : #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
    2779         357 : static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) {
    2780         357 :     PyListObject* L = (PyListObject*) list;
    2781         357 :     Py_ssize_t len = Py_SIZE(list);
    2782         357 :     if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) {
    2783           0 :         Py_INCREF(x);
    2784             :         #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030d0000
    2785             :         L->ob_item[len] = x;
    2786             :         #else
    2787           0 :         PyList_SET_ITEM(list, len, x);
    2788             :         #endif
    2789           0 :         __Pyx_SET_SIZE(list, len + 1);
    2790           0 :         return 0;
    2791             :     }
    2792         357 :     return PyList_Append(list, x);
    2793             : }
    2794             : #else
    2795             : #define __Pyx_PyList_Append(L,x) PyList_Append(L,x)
    2796             : #endif
    2797             : 
    2798             : /* IsLittleEndian.proto */
    2799             : static CYTHON_INLINE int __Pyx_Is_Little_Endian(void);
    2800             : 
    2801             : /* BufferFormatCheck.proto */
    2802             : static const char* __Pyx_BufFmt_CheckString(__Pyx_BufFmt_Context* ctx, const char* ts);
    2803             : static void __Pyx_BufFmt_Init(__Pyx_BufFmt_Context* ctx,
    2804             :                               __Pyx_BufFmt_StackElem* stack,
    2805             :                               __Pyx_TypeInfo* type);
    2806             : 
    2807             : /* BufferGetAndValidate.proto */
    2808             : #define __Pyx_GetBufferAndValidate(buf, obj, dtype, flags, nd, cast, stack)\
    2809             :     ((obj == Py_None || obj == NULL) ?\
    2810             :     (__Pyx_ZeroBuffer(buf), 0) :\
    2811             :     __Pyx__GetBufferAndValidate(buf, obj, dtype, flags, nd, cast, stack))
    2812             : static int  __Pyx__GetBufferAndValidate(Py_buffer* buf, PyObject* obj,
    2813             :     __Pyx_TypeInfo* dtype, int flags, int nd, int cast, __Pyx_BufFmt_StackElem* stack);
    2814             : static void __Pyx_ZeroBuffer(Py_buffer* buf);
    2815             : static CYTHON_INLINE void __Pyx_SafeReleaseBuffer(Py_buffer* info);
    2816             : static Py_ssize_t __Pyx_minusones[] = { -1, -1, -1, -1, -1, -1, -1, -1 };
    2817             : static Py_ssize_t __Pyx_zeros[] = { 0, 0, 0, 0, 0, 0, 0, 0 };
    2818             : 
    2819             : /* DivInt[npy_intp].proto */
    2820             : static CYTHON_INLINE npy_intp __Pyx_div_npy_intp(npy_intp, npy_intp);
    2821             : 
    2822             : /* PyIntCompare.proto */
    2823             : static CYTHON_INLINE PyObject* __Pyx_PyInt_NeObjC(PyObject *op1, PyObject *op2, long intval, long inplace);
    2824             : 
    2825             : /* PyObject_GenericGetAttrNoDict.proto */
    2826             : #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
    2827             : static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name);
    2828             : #else
    2829             : #define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr
    2830             : #endif
    2831             : 
    2832             : /* PyObject_GenericGetAttr.proto */
    2833             : #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
    2834             : static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name);
    2835             : #else
    2836             : #define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr
    2837             : #endif
    2838             : 
    2839             : /* IncludeStructmemberH.proto */
    2840             : #include <structmember.h>
    2841             : 
    2842             : /* FixUpExtensionType.proto */
    2843             : #if CYTHON_USE_TYPE_SPECS
    2844             : static int __Pyx_fix_up_extension_type_from_spec(PyType_Spec *spec, PyTypeObject *type);
    2845             : #endif
    2846             : 
    2847             : /* ValidateBasesTuple.proto */
    2848             : #if CYTHON_COMPILING_IN_CPYTHON || CYTHON_COMPILING_IN_LIMITED_API || CYTHON_USE_TYPE_SPECS
    2849             : static int __Pyx_validate_bases_tuple(const char *type_name, Py_ssize_t dictoffset, PyObject *bases);
    2850             : #endif
    2851             : 
    2852             : /* PyType_Ready.proto */
    2853             : CYTHON_UNUSED static int __Pyx_PyType_Ready(PyTypeObject *t);
    2854             : 
    2855             : /* SetVTable.proto */
    2856             : static int __Pyx_SetVtable(PyTypeObject* typeptr , void* vtable);
    2857             : 
    2858             : /* GetVTable.proto */
    2859             : static void* __Pyx_GetVtable(PyTypeObject *type);
    2860             : 
    2861             : /* MergeVTables.proto */
    2862             : #if !CYTHON_COMPILING_IN_LIMITED_API
    2863             : static int __Pyx_MergeVtables(PyTypeObject *type);
    2864             : #endif
    2865             : 
    2866             : /* SetupReduce.proto */
    2867             : #if !CYTHON_COMPILING_IN_LIMITED_API
    2868             : static int __Pyx_setup_reduce(PyObject* type_obj);
    2869             : #endif
    2870             : 
    2871             : /* TypeImport.proto */
    2872             : #ifndef __PYX_HAVE_RT_ImportType_proto_3_0_11
    2873             : #define __PYX_HAVE_RT_ImportType_proto_3_0_11
    2874             : #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
    2875             : #include <stdalign.h>
    2876             : #endif
    2877             : #if (defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112L) || __cplusplus >= 201103L
    2878             : #define __PYX_GET_STRUCT_ALIGNMENT_3_0_11(s) alignof(s)
    2879             : #else
    2880             : #define __PYX_GET_STRUCT_ALIGNMENT_3_0_11(s) sizeof(void*)
    2881             : #endif
    2882             : enum __Pyx_ImportType_CheckSize_3_0_11 {
    2883             :    __Pyx_ImportType_CheckSize_Error_3_0_11 = 0,
    2884             :    __Pyx_ImportType_CheckSize_Warn_3_0_11 = 1,
    2885             :    __Pyx_ImportType_CheckSize_Ignore_3_0_11 = 2
    2886             : };
    2887             : static PyTypeObject *__Pyx_ImportType_3_0_11(PyObject* module, const char *module_name, const char *class_name, size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_0_11 check_size);
    2888             : #endif
    2889             : 
    2890             : /* Py3UpdateBases.proto */
    2891             : static PyObject* __Pyx_PEP560_update_bases(PyObject *bases);
    2892             : 
    2893             : /* CalculateMetaclass.proto */
    2894             : static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases);
    2895             : 
    2896             : /* PyObjectCall2Args.proto */
    2897             : static CYTHON_INLINE PyObject* __Pyx_PyObject_Call2Args(PyObject* function, PyObject* arg1, PyObject* arg2);
    2898             : 
    2899             : /* PyObjectLookupSpecial.proto */
    2900             : #if CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS
    2901             : #define __Pyx_PyObject_LookupSpecialNoError(obj, attr_name)  __Pyx__PyObject_LookupSpecial(obj, attr_name, 0)
    2902             : #define __Pyx_PyObject_LookupSpecial(obj, attr_name)  __Pyx__PyObject_LookupSpecial(obj, attr_name, 1)
    2903             : static CYTHON_INLINE PyObject* __Pyx__PyObject_LookupSpecial(PyObject* obj, PyObject* attr_name, int with_error);
    2904             : #else
    2905             : #define __Pyx_PyObject_LookupSpecialNoError(o,n) __Pyx_PyObject_GetAttrStrNoError(o,n)
    2906             : #define __Pyx_PyObject_LookupSpecial(o,n) __Pyx_PyObject_GetAttrStr(o,n)
    2907             : #endif
    2908             : 
    2909             : /* Py3ClassCreate.proto */
    2910             : static PyObject *__Pyx_Py3MetaclassPrepare(PyObject *metaclass, PyObject *bases, PyObject *name, PyObject *qualname,
    2911             :                                            PyObject *mkw, PyObject *modname, PyObject *doc);
    2912             : static PyObject *__Pyx_Py3ClassCreate(PyObject *metaclass, PyObject *name, PyObject *bases, PyObject *dict,
    2913             :                                       PyObject *mkw, int calculate_metaclass, int allow_py2_metaclass);
    2914             : 
    2915             : /* FetchSharedCythonModule.proto */
    2916             : static PyObject *__Pyx_FetchSharedCythonABIModule(void);
    2917             : 
    2918             : /* FetchCommonType.proto */
    2919             : #if !CYTHON_USE_TYPE_SPECS
    2920             : static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type);
    2921             : #else
    2922             : static PyTypeObject* __Pyx_FetchCommonTypeFromSpec(PyObject *module, PyType_Spec *spec, PyObject *bases);
    2923             : #endif
    2924             : 
    2925             : /* PyMethodNew.proto */
    2926             : #if CYTHON_COMPILING_IN_LIMITED_API
    2927             : static PyObject *__Pyx_PyMethod_New(PyObject *func, PyObject *self, PyObject *typ) {
    2928             :     PyObject *typesModule=NULL, *methodType=NULL, *result=NULL;
    2929             :     CYTHON_UNUSED_VAR(typ);
    2930             :     if (!self)
    2931             :         return __Pyx_NewRef(func);
    2932             :     typesModule = PyImport_ImportModule("types");
    2933             :     if (!typesModule) return NULL;
    2934             :     methodType = PyObject_GetAttrString(typesModule, "MethodType");
    2935             :     Py_DECREF(typesModule);
    2936             :     if (!methodType) return NULL;
    2937             :     result = PyObject_CallFunctionObjArgs(methodType, func, self, NULL);
    2938             :     Py_DECREF(methodType);
    2939             :     return result;
    2940             : }
    2941             : #elif PY_MAJOR_VERSION >= 3
    2942           0 : static PyObject *__Pyx_PyMethod_New(PyObject *func, PyObject *self, PyObject *typ) {
    2943           0 :     CYTHON_UNUSED_VAR(typ);
    2944           0 :     if (!self)
    2945           0 :         return __Pyx_NewRef(func);
    2946           0 :     return PyMethod_New(func, self);
    2947             : }
    2948             : #else
    2949             :     #define __Pyx_PyMethod_New PyMethod_New
    2950             : #endif
    2951             : 
    2952             : /* PyVectorcallFastCallDict.proto */
    2953             : #if CYTHON_METH_FASTCALL
    2954             : static CYTHON_INLINE PyObject *__Pyx_PyVectorcall_FastCallDict(PyObject *func, __pyx_vectorcallfunc vc, PyObject *const *args, size_t nargs, PyObject *kw);
    2955             : #endif
    2956             : 
    2957             : /* CythonFunctionShared.proto */
    2958             : #define __Pyx_CyFunction_USED
    2959             : #define __Pyx_CYFUNCTION_STATICMETHOD  0x01
    2960             : #define __Pyx_CYFUNCTION_CLASSMETHOD   0x02
    2961             : #define __Pyx_CYFUNCTION_CCLASS        0x04
    2962             : #define __Pyx_CYFUNCTION_COROUTINE     0x08
    2963             : #define __Pyx_CyFunction_GetClosure(f)\
    2964             :     (((__pyx_CyFunctionObject *) (f))->func_closure)
    2965             : #if PY_VERSION_HEX < 0x030900B1 || CYTHON_COMPILING_IN_LIMITED_API
    2966             :   #define __Pyx_CyFunction_GetClassObj(f)\
    2967             :       (((__pyx_CyFunctionObject *) (f))->func_classobj)
    2968             : #else
    2969             :   #define __Pyx_CyFunction_GetClassObj(f)\
    2970             :       ((PyObject*) ((PyCMethodObject *) (f))->mm_class)
    2971             : #endif
    2972             : #define __Pyx_CyFunction_SetClassObj(f, classobj)\
    2973             :     __Pyx__CyFunction_SetClassObj((__pyx_CyFunctionObject *) (f), (classobj))
    2974             : #define __Pyx_CyFunction_Defaults(type, f)\
    2975             :     ((type *)(((__pyx_CyFunctionObject *) (f))->defaults))
    2976             : #define __Pyx_CyFunction_SetDefaultsGetter(f, g)\
    2977             :     ((__pyx_CyFunctionObject *) (f))->defaults_getter = (g)
    2978             : typedef struct {
    2979             : #if CYTHON_COMPILING_IN_LIMITED_API
    2980             :     PyObject_HEAD
    2981             :     PyObject *func;
    2982             : #elif PY_VERSION_HEX < 0x030900B1
    2983             :     PyCFunctionObject func;
    2984             : #else
    2985             :     PyCMethodObject func;
    2986             : #endif
    2987             : #if CYTHON_BACKPORT_VECTORCALL
    2988             :     __pyx_vectorcallfunc func_vectorcall;
    2989             : #endif
    2990             : #if PY_VERSION_HEX < 0x030500A0 || CYTHON_COMPILING_IN_LIMITED_API
    2991             :     PyObject *func_weakreflist;
    2992             : #endif
    2993             :     PyObject *func_dict;
    2994             :     PyObject *func_name;
    2995             :     PyObject *func_qualname;
    2996             :     PyObject *func_doc;
    2997             :     PyObject *func_globals;
    2998             :     PyObject *func_code;
    2999             :     PyObject *func_closure;
    3000             : #if PY_VERSION_HEX < 0x030900B1 || CYTHON_COMPILING_IN_LIMITED_API
    3001             :     PyObject *func_classobj;
    3002             : #endif
    3003             :     void *defaults;
    3004             :     int defaults_pyobjects;
    3005             :     size_t defaults_size;
    3006             :     int flags;
    3007             :     PyObject *defaults_tuple;
    3008             :     PyObject *defaults_kwdict;
    3009             :     PyObject *(*defaults_getter)(PyObject *);
    3010             :     PyObject *func_annotations;
    3011             :     PyObject *func_is_coroutine;
    3012             : } __pyx_CyFunctionObject;
    3013             : #undef __Pyx_CyOrPyCFunction_Check
    3014             : #define __Pyx_CyFunction_Check(obj)  __Pyx_TypeCheck(obj, __pyx_CyFunctionType)
    3015             : #define __Pyx_CyOrPyCFunction_Check(obj)  __Pyx_TypeCheck2(obj, __pyx_CyFunctionType, &PyCFunction_Type)
    3016             : #define __Pyx_CyFunction_CheckExact(obj)  __Pyx_IS_TYPE(obj, __pyx_CyFunctionType)
    3017             : static CYTHON_INLINE int __Pyx__IsSameCyOrCFunction(PyObject *func, void *cfunc);
    3018             : #undef __Pyx_IsSameCFunction
    3019             : #define __Pyx_IsSameCFunction(func, cfunc)   __Pyx__IsSameCyOrCFunction(func, cfunc)
    3020             : static PyObject *__Pyx_CyFunction_Init(__pyx_CyFunctionObject* op, PyMethodDef *ml,
    3021             :                                       int flags, PyObject* qualname,
    3022             :                                       PyObject *closure,
    3023             :                                       PyObject *module, PyObject *globals,
    3024             :                                       PyObject* code);
    3025             : static CYTHON_INLINE void __Pyx__CyFunction_SetClassObj(__pyx_CyFunctionObject* f, PyObject* classobj);
    3026             : static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *m,
    3027             :                                                          size_t size,
    3028             :                                                          int pyobjects);
    3029             : static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *m,
    3030             :                                                             PyObject *tuple);
    3031             : static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *m,
    3032             :                                                              PyObject *dict);
    3033             : static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *m,
    3034             :                                                               PyObject *dict);
    3035             : static int __pyx_CyFunction_init(PyObject *module);
    3036             : #if CYTHON_METH_FASTCALL
    3037             : static PyObject * __Pyx_CyFunction_Vectorcall_NOARGS(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames);
    3038             : static PyObject * __Pyx_CyFunction_Vectorcall_O(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames);
    3039             : static PyObject * __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames);
    3040             : static PyObject * __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS_METHOD(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames);
    3041             : #if CYTHON_BACKPORT_VECTORCALL
    3042             : #define __Pyx_CyFunction_func_vectorcall(f) (((__pyx_CyFunctionObject*)f)->func_vectorcall)
    3043             : #else
    3044             : #define __Pyx_CyFunction_func_vectorcall(f) (((PyCFunctionObject*)f)->vectorcall)
    3045             : #endif
    3046             : #endif
    3047             : 
    3048             : /* FusedFunction.proto */
    3049             : typedef struct {
    3050             :     __pyx_CyFunctionObject func;
    3051             :     PyObject *__signatures__;
    3052             :     PyObject *self;
    3053             : } __pyx_FusedFunctionObject;
    3054             : static PyObject *__pyx_FusedFunction_New(PyMethodDef *ml, int flags,
    3055             :                                          PyObject *qualname, PyObject *closure,
    3056             :                                          PyObject *module, PyObject *globals,
    3057             :                                          PyObject *code);
    3058             : static int __pyx_FusedFunction_clear(__pyx_FusedFunctionObject *self);
    3059             : static int __pyx_FusedFunction_init(PyObject *module);
    3060             : #define __Pyx_FusedFunction_USED
    3061             : 
    3062             : /* CythonFunction.proto */
    3063             : static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml,
    3064             :                                       int flags, PyObject* qualname,
    3065             :                                       PyObject *closure,
    3066             :                                       PyObject *module, PyObject *globals,
    3067             :                                       PyObject* code);
    3068             : 
    3069             : /* CLineInTraceback.proto */
    3070             : #ifdef CYTHON_CLINE_IN_TRACEBACK
    3071             : #define __Pyx_CLineForTraceback(tstate, c_line)  (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
    3072             : #else
    3073             : static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line);
    3074             : #endif
    3075             : 
    3076             : /* CodeObjectCache.proto */
    3077             : #if !CYTHON_COMPILING_IN_LIMITED_API
    3078             : typedef struct {
    3079             :     PyCodeObject* code_object;
    3080             :     int code_line;
    3081             : } __Pyx_CodeObjectCacheEntry;
    3082             : struct __Pyx_CodeObjectCache {
    3083             :     int count;
    3084             :     int max_count;
    3085             :     __Pyx_CodeObjectCacheEntry* entries;
    3086             : };
    3087             : static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
    3088             : static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
    3089             : static PyCodeObject *__pyx_find_code_object(int code_line);
    3090             : static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);
    3091             : #endif
    3092             : 
    3093             : /* AddTraceback.proto */
    3094             : static void __Pyx_AddTraceback(const char *funcname, int c_line,
    3095             :                                int py_line, const char *filename);
    3096             : 
    3097             : #if PY_MAJOR_VERSION < 3
    3098             :     static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view, int flags);
    3099             :     static void __Pyx_ReleaseBuffer(Py_buffer *view);
    3100             : #else
    3101             :     #define __Pyx_GetBuffer PyObject_GetBuffer
    3102             :     #define __Pyx_ReleaseBuffer PyBuffer_Release
    3103             : #endif
    3104             : 
    3105             : 
    3106             : /* BufferStructDeclare.proto */
    3107             : typedef struct {
    3108             :   Py_ssize_t shape, strides, suboffsets;
    3109             : } __Pyx_Buf_DimInfo;
    3110             : typedef struct {
    3111             :   size_t refcount;
    3112             :   Py_buffer pybuffer;
    3113             : } __Pyx_Buffer;
    3114             : typedef struct {
    3115             :   __Pyx_Buffer *rcbuffer;
    3116             :   char *data;
    3117             :   __Pyx_Buf_DimInfo diminfo[8];
    3118             : } __Pyx_LocalBuf_ND;
    3119             : 
    3120             : /* MemviewSliceIsContig.proto */
    3121             : static int __pyx_memviewslice_is_contig(const __Pyx_memviewslice mvs, char order, int ndim);
    3122             : 
    3123             : /* OverlappingSlices.proto */
    3124             : static int __pyx_slices_overlap(__Pyx_memviewslice *slice1,
    3125             :                                 __Pyx_memviewslice *slice2,
    3126             :                                 int ndim, size_t itemsize);
    3127             : 
    3128             : /* TypeInfoCompare.proto */
    3129             : static int __pyx_typeinfo_cmp(__Pyx_TypeInfo *a, __Pyx_TypeInfo *b);
    3130             : 
    3131             : /* MemviewSliceValidateAndInit.proto */
    3132             : static int __Pyx_ValidateAndInit_memviewslice(
    3133             :                 int *axes_specs,
    3134             :                 int c_or_f_flag,
    3135             :                 int buf_flags,
    3136             :                 int ndim,
    3137             :                 __Pyx_TypeInfo *dtype,
    3138             :                 __Pyx_BufFmt_StackElem stack[],
    3139             :                 __Pyx_memviewslice *memviewslice,
    3140             :                 PyObject *original_obj);
    3141             : 
    3142             : /* ObjectToMemviewSlice.proto */
    3143             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int8_t(PyObject *, int writable_flag);
    3144             : 
    3145             : /* ObjectToMemviewSlice.proto */
    3146             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int16_t(PyObject *, int writable_flag);
    3147             : 
    3148             : /* ObjectToMemviewSlice.proto */
    3149             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int32_t(PyObject *, int writable_flag);
    3150             : 
    3151             : /* ObjectToMemviewSlice.proto */
    3152             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int64_t(PyObject *, int writable_flag);
    3153             : 
    3154             : /* ObjectToMemviewSlice.proto */
    3155             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint8_t(PyObject *, int writable_flag);
    3156             : 
    3157             : /* ObjectToMemviewSlice.proto */
    3158             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint16_t(PyObject *, int writable_flag);
    3159             : 
    3160             : /* ObjectToMemviewSlice.proto */
    3161             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint32_t(PyObject *, int writable_flag);
    3162             : 
    3163             : /* ObjectToMemviewSlice.proto */
    3164             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint64_t(PyObject *, int writable_flag);
    3165             : 
    3166             : /* ObjectToMemviewSlice.proto */
    3167             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float32_t(PyObject *, int writable_flag);
    3168             : 
    3169             : /* ObjectToMemviewSlice.proto */
    3170             : static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float64_t(PyObject *, int writable_flag);
    3171             : 
    3172             : /* PyUCS4InUnicode.proto */
    3173             : static CYTHON_INLINE int __Pyx_UnicodeContainsUCS4(PyObject* unicode, Py_UCS4 character);
    3174             : 
    3175             : /* RealImag.proto */
    3176             : #if CYTHON_CCOMPLEX
    3177             :   #ifdef __cplusplus
    3178             :     #define __Pyx_CREAL(z) ((z).real())
    3179             :     #define __Pyx_CIMAG(z) ((z).imag())
    3180             :   #else
    3181             :     #define __Pyx_CREAL(z) (__real__(z))
    3182             :     #define __Pyx_CIMAG(z) (__imag__(z))
    3183             :   #endif
    3184             : #else
    3185             :     #define __Pyx_CREAL(z) ((z).real)
    3186             :     #define __Pyx_CIMAG(z) ((z).imag)
    3187             : #endif
    3188             : #if defined(__cplusplus) && CYTHON_CCOMPLEX\
    3189             :         && (defined(_WIN32) || defined(__clang__) || (defined(__GNUC__) && (__GNUC__ >= 5 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4 )) || __cplusplus >= 201103)
    3190             :     #define __Pyx_SET_CREAL(z,x) ((z).real(x))
    3191             :     #define __Pyx_SET_CIMAG(z,y) ((z).imag(y))
    3192             : #else
    3193             :     #define __Pyx_SET_CREAL(z,x) __Pyx_CREAL(z) = (x)
    3194             :     #define __Pyx_SET_CIMAG(z,y) __Pyx_CIMAG(z) = (y)
    3195             : #endif
    3196             : 
    3197             : /* Arithmetic.proto */
    3198             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    3199             :     #define __Pyx_c_eq_float(a, b)   ((a)==(b))
    3200             :     #define __Pyx_c_sum_float(a, b)  ((a)+(b))
    3201             :     #define __Pyx_c_diff_float(a, b) ((a)-(b))
    3202             :     #define __Pyx_c_prod_float(a, b) ((a)*(b))
    3203             :     #define __Pyx_c_quot_float(a, b) ((a)/(b))
    3204             :     #define __Pyx_c_neg_float(a)     (-(a))
    3205             :   #ifdef __cplusplus
    3206             :     #define __Pyx_c_is_zero_float(z) ((z)==(float)0)
    3207             :     #define __Pyx_c_conj_float(z)    (::std::conj(z))
    3208             :     #if 1
    3209             :         #define __Pyx_c_abs_float(z)     (::std::abs(z))
    3210             :         #define __Pyx_c_pow_float(a, b)  (::std::pow(a, b))
    3211             :     #endif
    3212             :   #else
    3213             :     #define __Pyx_c_is_zero_float(z) ((z)==0)
    3214             :     #define __Pyx_c_conj_float(z)    (conjf(z))
    3215             :     #if 1
    3216             :         #define __Pyx_c_abs_float(z)     (cabsf(z))
    3217             :         #define __Pyx_c_pow_float(a, b)  (cpowf(a, b))
    3218             :     #endif
    3219             :  #endif
    3220             : #else
    3221             :     static CYTHON_INLINE int __Pyx_c_eq_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3222             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3223             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3224             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3225             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3226             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex);
    3227             :     static CYTHON_INLINE int __Pyx_c_is_zero_float(__pyx_t_float_complex);
    3228             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex);
    3229             :     #if 1
    3230             :         static CYTHON_INLINE float __Pyx_c_abs_float(__pyx_t_float_complex);
    3231             :         static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex, __pyx_t_float_complex);
    3232             :     #endif
    3233             : #endif
    3234             : 
    3235             : /* Arithmetic.proto */
    3236             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    3237             :     #define __Pyx_c_eq_double(a, b)   ((a)==(b))
    3238             :     #define __Pyx_c_sum_double(a, b)  ((a)+(b))
    3239             :     #define __Pyx_c_diff_double(a, b) ((a)-(b))
    3240             :     #define __Pyx_c_prod_double(a, b) ((a)*(b))
    3241             :     #define __Pyx_c_quot_double(a, b) ((a)/(b))
    3242             :     #define __Pyx_c_neg_double(a)     (-(a))
    3243             :   #ifdef __cplusplus
    3244             :     #define __Pyx_c_is_zero_double(z) ((z)==(double)0)
    3245             :     #define __Pyx_c_conj_double(z)    (::std::conj(z))
    3246             :     #if 1
    3247             :         #define __Pyx_c_abs_double(z)     (::std::abs(z))
    3248             :         #define __Pyx_c_pow_double(a, b)  (::std::pow(a, b))
    3249             :     #endif
    3250             :   #else
    3251             :     #define __Pyx_c_is_zero_double(z) ((z)==0)
    3252             :     #define __Pyx_c_conj_double(z)    (conj(z))
    3253             :     #if 1
    3254             :         #define __Pyx_c_abs_double(z)     (cabs(z))
    3255             :         #define __Pyx_c_pow_double(a, b)  (cpow(a, b))
    3256             :     #endif
    3257             :  #endif
    3258             : #else
    3259             :     static CYTHON_INLINE int __Pyx_c_eq_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3260             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3261             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3262             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3263             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3264             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex);
    3265             :     static CYTHON_INLINE int __Pyx_c_is_zero_double(__pyx_t_double_complex);
    3266             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex);
    3267             :     #if 1
    3268             :         static CYTHON_INLINE double __Pyx_c_abs_double(__pyx_t_double_complex);
    3269             :         static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex, __pyx_t_double_complex);
    3270             :     #endif
    3271             : #endif
    3272             : 
    3273             : /* Arithmetic.proto */
    3274             : #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
    3275             :     #define __Pyx_c_eq_long__double(a, b)   ((a)==(b))
    3276             :     #define __Pyx_c_sum_long__double(a, b)  ((a)+(b))
    3277             :     #define __Pyx_c_diff_long__double(a, b) ((a)-(b))
    3278             :     #define __Pyx_c_prod_long__double(a, b) ((a)*(b))
    3279             :     #define __Pyx_c_quot_long__double(a, b) ((a)/(b))
    3280             :     #define __Pyx_c_neg_long__double(a)     (-(a))
    3281             :   #ifdef __cplusplus
    3282             :     #define __Pyx_c_is_zero_long__double(z) ((z)==(long double)0)
    3283             :     #define __Pyx_c_conj_long__double(z)    (::std::conj(z))
    3284             :     #if 1
    3285             :         #define __Pyx_c_abs_long__double(z)     (::std::abs(z))
    3286             :         #define __Pyx_c_pow_long__double(a, b)  (::std::pow(a, b))
    3287             :     #endif
    3288             :   #else
    3289             :     #define __Pyx_c_is_zero_long__double(z) ((z)==0)
    3290             :     #define __Pyx_c_conj_long__double(z)    (conjl(z))
    3291             :     #if 1
    3292             :         #define __Pyx_c_abs_long__double(z)     (cabsl(z))
    3293             :         #define __Pyx_c_pow_long__double(a, b)  (cpowl(a, b))
    3294             :     #endif
    3295             :  #endif
    3296             : #else
    3297             :     static CYTHON_INLINE int __Pyx_c_eq_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3298             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_sum_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3299             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_diff_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3300             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_prod_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3301             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_quot_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3302             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_neg_long__double(__pyx_t_long_double_complex);
    3303             :     static CYTHON_INLINE int __Pyx_c_is_zero_long__double(__pyx_t_long_double_complex);
    3304             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_conj_long__double(__pyx_t_long_double_complex);
    3305             :     #if 1
    3306             :         static CYTHON_INLINE long double __Pyx_c_abs_long__double(__pyx_t_long_double_complex);
    3307             :         static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_pow_long__double(__pyx_t_long_double_complex, __pyx_t_long_double_complex);
    3308             :     #endif
    3309             : #endif
    3310             : 
    3311             : /* MemviewSliceCopyTemplate.proto */
    3312             : static __Pyx_memviewslice
    3313             : __pyx_memoryview_copy_new_contig(const __Pyx_memviewslice *from_mvs,
    3314             :                                  const char *mode, int ndim,
    3315             :                                  size_t sizeof_dtype, int contig_flag,
    3316             :                                  int dtype_is_object);
    3317             : 
    3318             : /* MemviewSliceInit.proto */
    3319             : #define __Pyx_BUF_MAX_NDIMS %(BUF_MAX_NDIMS)d
    3320             : #define __Pyx_MEMVIEW_DIRECT   1
    3321             : #define __Pyx_MEMVIEW_PTR      2
    3322             : #define __Pyx_MEMVIEW_FULL     4
    3323             : #define __Pyx_MEMVIEW_CONTIG   8
    3324             : #define __Pyx_MEMVIEW_STRIDED  16
    3325             : #define __Pyx_MEMVIEW_FOLLOW   32
    3326             : #define __Pyx_IS_C_CONTIG 1
    3327             : #define __Pyx_IS_F_CONTIG 2
    3328             : static int __Pyx_init_memviewslice(
    3329             :                 struct __pyx_memoryview_obj *memview,
    3330             :                 int ndim,
    3331             :                 __Pyx_memviewslice *memviewslice,
    3332             :                 int memview_is_new_reference);
    3333             : static CYTHON_INLINE int __pyx_add_acquisition_count_locked(
    3334             :     __pyx_atomic_int_type *acquisition_count, PyThread_type_lock lock);
    3335             : static CYTHON_INLINE int __pyx_sub_acquisition_count_locked(
    3336             :     __pyx_atomic_int_type *acquisition_count, PyThread_type_lock lock);
    3337             : #define __pyx_get_slice_count_pointer(memview) (&memview->acquisition_count)
    3338             : #define __PYX_INC_MEMVIEW(slice, have_gil) __Pyx_INC_MEMVIEW(slice, have_gil, __LINE__)
    3339             : #define __PYX_XCLEAR_MEMVIEW(slice, have_gil) __Pyx_XCLEAR_MEMVIEW(slice, have_gil, __LINE__)
    3340             : static CYTHON_INLINE void __Pyx_INC_MEMVIEW(__Pyx_memviewslice *, int, int);
    3341             : static CYTHON_INLINE void __Pyx_XCLEAR_MEMVIEW(__Pyx_memviewslice *, int, int);
    3342             : 
    3343             : /* CIntToPy.proto */
    3344             : static CYTHON_INLINE PyObject* __Pyx_PyInt_From_npy_intp(npy_intp value);
    3345             : 
    3346             : /* CIntFromPy.proto */
    3347             : static CYTHON_INLINE npy_intp __Pyx_PyInt_As_npy_intp(PyObject *);
    3348             : 
    3349             : /* CIntToPy.proto */
    3350             : static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);
    3351             : 
    3352             : /* CIntToPy.proto */
    3353             : static CYTHON_INLINE PyObject* __Pyx_PyInt_From_Py_intptr_t(Py_intptr_t value);
    3354             : 
    3355             : /* CIntToPy.proto */
    3356             : static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value);
    3357             : 
    3358             : /* CIntFromPy.proto */
    3359             : static CYTHON_INLINE Py_intptr_t __Pyx_PyInt_As_Py_intptr_t(PyObject *);
    3360             : 
    3361             : /* CIntFromPy.proto */
    3362             : static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);
    3363             : 
    3364             : /* CIntToPy.proto */
    3365             : static CYTHON_INLINE PyObject* __Pyx_PyInt_From_npy_uintp(npy_uintp value);
    3366             : 
    3367             : /* CIntFromPy.proto */
    3368             : static CYTHON_INLINE npy_uintp __Pyx_PyInt_As_npy_uintp(PyObject *);
    3369             : 
    3370             : /* ImportNumPyArray.proto */
    3371             : static PyObject *__pyx_numpy_ndarray = NULL;
    3372             : static PyObject* __Pyx_ImportNumPyArrayTypeIfAvailable(void);
    3373             : 
    3374             : /* CIntFromPy.proto */
    3375             : static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);
    3376             : 
    3377             : /* CIntFromPy.proto */
    3378             : static CYTHON_INLINE char __Pyx_PyInt_As_char(PyObject *);
    3379             : 
    3380             : /* FormatTypeName.proto */
    3381             : #if CYTHON_COMPILING_IN_LIMITED_API
    3382             : typedef PyObject *__Pyx_TypeName;
    3383             : #define __Pyx_FMT_TYPENAME "%U"
    3384             : static __Pyx_TypeName __Pyx_PyType_GetName(PyTypeObject* tp);
    3385             : #define __Pyx_DECREF_TypeName(obj) Py_XDECREF(obj)
    3386             : #else
    3387             : typedef const char *__Pyx_TypeName;
    3388             : #define __Pyx_FMT_TYPENAME "%.200s"
    3389             : #define __Pyx_PyType_GetName(tp) ((tp)->tp_name)
    3390             : #define __Pyx_DECREF_TypeName(obj)
    3391             : #endif
    3392             : 
    3393             : /* CheckBinaryVersion.proto */
    3394             : static unsigned long __Pyx_get_runtime_version(void);
    3395             : static int __Pyx_check_binary_version(unsigned long ct_version, unsigned long rt_version, int allow_newer);
    3396             : 
    3397             : /* InitStrings.proto */
    3398             : static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
    3399             : 
    3400             : /* #### Code section: module_declarations ### */
    3401             : static PyObject *__pyx_array_get_memview(struct __pyx_array_obj *__pyx_v_self); /* proto*/
    3402             : static char *__pyx_memoryview_get_item_pointer(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index); /* proto*/
    3403             : static PyObject *__pyx_memoryview_is_slice(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj); /* proto*/
    3404             : static PyObject *__pyx_memoryview_setitem_slice_assignment(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_dst, PyObject *__pyx_v_src); /* proto*/
    3405             : static PyObject *__pyx_memoryview_setitem_slice_assign_scalar(struct __pyx_memoryview_obj *__pyx_v_self, struct __pyx_memoryview_obj *__pyx_v_dst, PyObject *__pyx_v_value); /* proto*/
    3406             : static PyObject *__pyx_memoryview_setitem_indexed(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value); /* proto*/
    3407             : static PyObject *__pyx_memoryview_convert_item_to_object(struct __pyx_memoryview_obj *__pyx_v_self, char *__pyx_v_itemp); /* proto*/
    3408             : static PyObject *__pyx_memoryview_assign_item_from_object(struct __pyx_memoryview_obj *__pyx_v_self, char *__pyx_v_itemp, PyObject *__pyx_v_value); /* proto*/
    3409             : static PyObject *__pyx_memoryview__get_base(struct __pyx_memoryview_obj *__pyx_v_self); /* proto*/
    3410             : static PyObject *__pyx_memoryviewslice_convert_item_to_object(struct __pyx_memoryviewslice_obj *__pyx_v_self, char *__pyx_v_itemp); /* proto*/
    3411             : static PyObject *__pyx_memoryviewslice_assign_item_from_object(struct __pyx_memoryviewslice_obj *__pyx_v_self, char *__pyx_v_itemp, PyObject *__pyx_v_value); /* proto*/
    3412             : static PyObject *__pyx_memoryviewslice__get_base(struct __pyx_memoryviewslice_obj *__pyx_v_self); /* proto*/
    3413             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_5dtype_8itemsize_itemsize(PyArray_Descr *__pyx_v_self); /* proto*/
    3414             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_5dtype_9alignment_alignment(PyArray_Descr *__pyx_v_self); /* proto*/
    3415             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_5dtype_6fields_fields(PyArray_Descr *__pyx_v_self); /* proto*/
    3416             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_5dtype_5names_names(PyArray_Descr *__pyx_v_self); /* proto*/
    3417             : static CYTHON_INLINE PyArray_ArrayDescr *__pyx_f_5numpy_5dtype_8subarray_subarray(PyArray_Descr *__pyx_v_self); /* proto*/
    3418             : static CYTHON_INLINE npy_uint64 __pyx_f_5numpy_5dtype_5flags_flags(PyArray_Descr *__pyx_v_self); /* proto*/
    3419             : static CYTHON_INLINE int __pyx_f_5numpy_9broadcast_7numiter_numiter(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3420             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_9broadcast_4size_size(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3421             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_9broadcast_5index_index(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3422             : static CYTHON_INLINE int __pyx_f_5numpy_9broadcast_2nd_nd(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3423             : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_9broadcast_10dimensions_dimensions(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3424             : static CYTHON_INLINE void **__pyx_f_5numpy_9broadcast_5iters_iters(PyArrayMultiIterObject *__pyx_v_self); /* proto*/
    3425             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_7ndarray_4base_base(PyArrayObject *__pyx_v_self); /* proto*/
    3426             : static CYTHON_INLINE PyArray_Descr *__pyx_f_5numpy_7ndarray_5descr_descr(PyArrayObject *__pyx_v_self); /* proto*/
    3427             : static CYTHON_INLINE int __pyx_f_5numpy_7ndarray_4ndim_ndim(PyArrayObject *__pyx_v_self); /* proto*/
    3428             : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_7ndarray_5shape_shape(PyArrayObject *__pyx_v_self); /* proto*/
    3429             : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_7ndarray_7strides_strides(PyArrayObject *__pyx_v_self); /* proto*/
    3430             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_7ndarray_4size_size(PyArrayObject *__pyx_v_self); /* proto*/
    3431             : static CYTHON_INLINE char *__pyx_f_5numpy_7ndarray_4data_data(PyArrayObject *__pyx_v_self); /* proto*/
    3432             : 
    3433             : /* Module declarations from "libc.string" */
    3434             : 
    3435             : /* Module declarations from "libc.stdio" */
    3436             : 
    3437             : /* Module declarations from "__builtin__" */
    3438             : 
    3439             : /* Module declarations from "cpython.type" */
    3440             : 
    3441             : /* Module declarations from "cpython" */
    3442             : 
    3443             : /* Module declarations from "cpython.object" */
    3444             : 
    3445             : /* Module declarations from "cpython.ref" */
    3446             : 
    3447             : /* Module declarations from "numpy" */
    3448             : 
    3449             : /* Module declarations from "numpy" */
    3450             : static CYTHON_INLINE int __pyx_f_5numpy_import_array(void); /*proto*/
    3451             : 
    3452             : /* Module declarations from "_ni_label" */
    3453             : static PyObject *__pyx_collections_abc_Sequence = 0;
    3454             : static PyObject *generic = 0;
    3455             : static PyObject *strided = 0;
    3456             : static PyObject *indirect = 0;
    3457             : static PyObject *contiguous = 0;
    3458             : static PyObject *indirect_contiguous = 0;
    3459             : static int __pyx_memoryview_thread_locks_used;
    3460             : static PyThread_type_lock __pyx_memoryview_thread_locks[8];
    3461             : static CYTHON_INLINE __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_mark_for_merge(__pyx_t_5numpy_uintp_t, __pyx_t_5numpy_uintp_t, __pyx_t_5numpy_uintp_t *); /*proto*/
    3462             : static CYTHON_INLINE __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_take_label_or_merge(__pyx_t_5numpy_uintp_t, __pyx_t_5numpy_uintp_t, __pyx_t_5numpy_uintp_t *); /*proto*/
    3463             : static __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_label_line_with_neighbor(__pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_uintp_t *, int, int, int, __pyx_t_5numpy_intp_t, int, int, __pyx_t_5numpy_uintp_t, __pyx_t_5numpy_uintp_t *); /*proto*/
    3464             : static PyObject *__pyx_f_9_ni_label__label(PyArrayObject *, PyArrayObject *, PyArrayObject *, int __pyx_skip_dispatch); /*proto*/
    3465             : static void __pyx_fuse_0__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3466             : static void __pyx_fuse_1__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3467             : static void __pyx_fuse_2__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3468             : static void __pyx_fuse_3__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3469             : static void __pyx_fuse_4__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3470             : static void __pyx_fuse_5__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3471             : static void __pyx_fuse_6__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3472             : static void __pyx_fuse_7__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3473             : static void __pyx_fuse_8__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_float32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3474             : static void __pyx_fuse_9__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_float64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3475             : static void __pyx_fuse_0__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3476             : static void __pyx_fuse_1__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3477             : static void __pyx_fuse_2__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3478             : static void __pyx_fuse_3__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3479             : static void __pyx_fuse_4__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3480             : static void __pyx_fuse_5__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3481             : static void __pyx_fuse_6__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3482             : static void __pyx_fuse_7__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3483             : static void __pyx_fuse_8__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_float32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3484             : static void __pyx_fuse_9__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_float64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3485             : static int __pyx_fuse_0__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3486             : static int __pyx_fuse_1__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3487             : static int __pyx_fuse_2__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3488             : static int __pyx_fuse_3__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3489             : static int __pyx_fuse_4__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint8_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3490             : static int __pyx_fuse_5__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint16_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3491             : static int __pyx_fuse_6__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3492             : static int __pyx_fuse_7__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3493             : static int __pyx_fuse_8__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_float32_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3494             : static int __pyx_fuse_9__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_float64_t *, __pyx_t_5numpy_intp_t, __pyx_t_5numpy_uintp_t *, __pyx_t_5numpy_intp_t); /*proto*/
    3495             : static int __pyx_array_allocate_buffer(struct __pyx_array_obj *); /*proto*/
    3496             : static struct __pyx_array_obj *__pyx_array_new(PyObject *, Py_ssize_t, char *, char *, char *); /*proto*/
    3497             : static PyObject *__pyx_memoryview_new(PyObject *, int, int, __Pyx_TypeInfo *); /*proto*/
    3498             : static CYTHON_INLINE int __pyx_memoryview_check(PyObject *); /*proto*/
    3499             : static PyObject *_unellipsify(PyObject *, int); /*proto*/
    3500             : static int assert_direct_dimensions(Py_ssize_t *, int); /*proto*/
    3501             : static struct __pyx_memoryview_obj *__pyx_memview_slice(struct __pyx_memoryview_obj *, PyObject *); /*proto*/
    3502             : static int __pyx_memoryview_slice_memviewslice(__Pyx_memviewslice *, Py_ssize_t, Py_ssize_t, Py_ssize_t, int, int, int *, Py_ssize_t, Py_ssize_t, Py_ssize_t, int, int, int, int); /*proto*/
    3503             : static char *__pyx_pybuffer_index(Py_buffer *, char *, Py_ssize_t, Py_ssize_t); /*proto*/
    3504             : static int __pyx_memslice_transpose(__Pyx_memviewslice *); /*proto*/
    3505             : static PyObject *__pyx_memoryview_fromslice(__Pyx_memviewslice, int, PyObject *(*)(char *), int (*)(char *, PyObject *), int); /*proto*/
    3506             : static __Pyx_memviewslice *__pyx_memoryview_get_slice_from_memoryview(struct __pyx_memoryview_obj *, __Pyx_memviewslice *); /*proto*/
    3507             : static void __pyx_memoryview_slice_copy(struct __pyx_memoryview_obj *, __Pyx_memviewslice *); /*proto*/
    3508             : static PyObject *__pyx_memoryview_copy_object(struct __pyx_memoryview_obj *); /*proto*/
    3509             : static PyObject *__pyx_memoryview_copy_object_from_slice(struct __pyx_memoryview_obj *, __Pyx_memviewslice *); /*proto*/
    3510             : static Py_ssize_t abs_py_ssize_t(Py_ssize_t); /*proto*/
    3511             : static char __pyx_get_best_slice_order(__Pyx_memviewslice *, int); /*proto*/
    3512             : static void _copy_strided_to_strided(char *, Py_ssize_t *, char *, Py_ssize_t *, Py_ssize_t *, Py_ssize_t *, int, size_t); /*proto*/
    3513             : static void copy_strided_to_strided(__Pyx_memviewslice *, __Pyx_memviewslice *, int, size_t); /*proto*/
    3514             : static Py_ssize_t __pyx_memoryview_slice_get_size(__Pyx_memviewslice *, int); /*proto*/
    3515             : static Py_ssize_t __pyx_fill_contig_strides_array(Py_ssize_t *, Py_ssize_t *, Py_ssize_t, int, char); /*proto*/
    3516             : static void *__pyx_memoryview_copy_data_to_temp(__Pyx_memviewslice *, __Pyx_memviewslice *, char, int); /*proto*/
    3517             : static int __pyx_memoryview_err_extents(int, Py_ssize_t, Py_ssize_t); /*proto*/
    3518             : static int __pyx_memoryview_err_dim(PyObject *, PyObject *, int); /*proto*/
    3519             : static int __pyx_memoryview_err(PyObject *, PyObject *); /*proto*/
    3520             : static int __pyx_memoryview_err_no_memory(void); /*proto*/
    3521             : static int __pyx_memoryview_copy_contents(__Pyx_memviewslice, __Pyx_memviewslice, int, int, int); /*proto*/
    3522             : static void __pyx_memoryview_broadcast_leading(__Pyx_memviewslice *, int, int); /*proto*/
    3523             : static void __pyx_memoryview_refcount_copying(__Pyx_memviewslice *, int, int, int); /*proto*/
    3524             : static void __pyx_memoryview_refcount_objects_in_slice_with_gil(char *, Py_ssize_t *, Py_ssize_t *, int, int); /*proto*/
    3525             : static void __pyx_memoryview_refcount_objects_in_slice(char *, Py_ssize_t *, Py_ssize_t *, int, int); /*proto*/
    3526             : static void __pyx_memoryview_slice_assign_scalar(__Pyx_memviewslice *, int, size_t, void *, int); /*proto*/
    3527             : static void __pyx_memoryview__slice_assign_scalar(char *, Py_ssize_t *, Py_ssize_t *, int, size_t, void *); /*proto*/
    3528             : static PyObject *__pyx_unpickle_Enum__set_state(struct __pyx_MemviewEnum_obj *, PyObject *); /*proto*/
    3529             : /* #### Code section: typeinfo ### */
    3530             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_int8_t = { "int8_t", NULL, sizeof(__pyx_t_5numpy_int8_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_int8_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_int8_t), 0 };
    3531             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_int16_t = { "int16_t", NULL, sizeof(__pyx_t_5numpy_int16_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_int16_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_int16_t), 0 };
    3532             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t = { "int32_t", NULL, sizeof(__pyx_t_5numpy_int32_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_int32_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_int32_t), 0 };
    3533             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t = { "int64_t", NULL, sizeof(__pyx_t_5numpy_int64_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_int64_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_int64_t), 0 };
    3534             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_uint8_t = { "uint8_t", NULL, sizeof(__pyx_t_5numpy_uint8_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint8_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint8_t), 0 };
    3535             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_uint16_t = { "uint16_t", NULL, sizeof(__pyx_t_5numpy_uint16_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint16_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint16_t), 0 };
    3536             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_uint32_t = { "uint32_t", NULL, sizeof(__pyx_t_5numpy_uint32_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint32_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint32_t), 0 };
    3537             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_uint64_t = { "uint64_t", NULL, sizeof(__pyx_t_5numpy_uint64_t), { 0 }, 0, __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint64_t) ? 'U' : 'I', __PYX_IS_UNSIGNED(__pyx_t_5numpy_uint64_t), 0 };
    3538             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t = { "float32_t", NULL, sizeof(__pyx_t_5numpy_float32_t), { 0 }, 0, 'R', 0, 0 };
    3539             : static __Pyx_TypeInfo __Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t = { "float64_t", NULL, sizeof(__pyx_t_5numpy_float64_t), { 0 }, 0, 'R', 0, 0 };
    3540             : /* #### Code section: before_global_var ### */
    3541             : #define __Pyx_MODULE_NAME "_ni_label"
    3542             : extern int __pyx_module_is_main__ni_label;
    3543             : int __pyx_module_is_main__ni_label = 0;
    3544             : 
    3545             : /* Implementation of "_ni_label" */
    3546             : /* #### Code section: global_var ### */
    3547             : static PyObject *__pyx_builtin_range;
    3548             : static PyObject *__pyx_builtin_TypeError;
    3549             : static PyObject *__pyx_builtin_ValueError;
    3550             : static PyObject *__pyx_builtin_AssertionError;
    3551             : static PyObject *__pyx_builtin_MemoryError;
    3552             : static PyObject *__pyx_builtin___import__;
    3553             : static PyObject *__pyx_builtin_enumerate;
    3554             : static PyObject *__pyx_builtin_Ellipsis;
    3555             : static PyObject *__pyx_builtin_id;
    3556             : static PyObject *__pyx_builtin_IndexError;
    3557             : static PyObject *__pyx_builtin_ImportError;
    3558             : /* #### Code section: string_decls ### */
    3559             : static const char __pyx_k_[] = ": ";
    3560             : static const char __pyx_k_O[] = "O";
    3561             : static const char __pyx_k_a[] = "a";
    3562             : static const char __pyx_k_c[] = "c";
    3563             : static const char __pyx_k_s[] = "s_";
    3564             : static const char __pyx_k__2[] = ".";
    3565             : static const char __pyx_k__3[] = "*";
    3566             : static const char __pyx_k__6[] = "'";
    3567             : static const char __pyx_k__7[] = ")";
    3568             : static const char __pyx_k_gc[] = "gc";
    3569             : static const char __pyx_k_id[] = "id";
    3570             : static const char __pyx_k_np[] = "np";
    3571             : static const char __pyx_k__11[] = "";
    3572             : static const char __pyx_k__12[] = "()";
    3573             : static const char __pyx_k__13[] = "|";
    3574             : static const char __pyx_k__34[] = "?";
    3575             : static const char __pyx_k_abc[] = "abc";
    3576             : static const char __pyx_k_all[] = "all";
    3577             : static const char __pyx_k_and[] = " and ";
    3578             : static const char __pyx_k_doc[] = "__doc__";
    3579             : static const char __pyx_k_get[] = "get";
    3580             : static const char __pyx_k_got[] = " (got ";
    3581             : static const char __pyx_k_new[] = "__new__";
    3582             : static const char __pyx_k_obj[] = "obj";
    3583             : static const char __pyx_k_sys[] = "sys";
    3584             : static const char __pyx_k_args[] = "args";
    3585             : static const char __pyx_k_base[] = "base";
    3586             : static const char __pyx_k_bool[] = "bool_";
    3587             : static const char __pyx_k_copy[] = "copy";
    3588             : static const char __pyx_k_dict[] = "__dict__";
    3589             : static const char __pyx_k_kind[] = "kind";
    3590             : static const char __pyx_k_main[] = "__main__";
    3591             : static const char __pyx_k_mode[] = "mode";
    3592             : static const char __pyx_k_name[] = "name";
    3593             : static const char __pyx_k_ndim[] = "ndim";
    3594             : static const char __pyx_k_pack[] = "pack";
    3595             : static const char __pyx_k_size[] = "size";
    3596             : static const char __pyx_k_spec[] = "__spec__";
    3597             : static const char __pyx_k_step[] = "step";
    3598             : static const char __pyx_k_stop[] = "stop";
    3599             : static const char __pyx_k_take[] = "take";
    3600             : static const char __pyx_k_test[] = "__test__";
    3601             : static const char __pyx_k_view[] = "view";
    3602             : static const char __pyx_k_ASCII[] = "ASCII";
    3603             : static const char __pyx_k_class[] = "__class__";
    3604             : static const char __pyx_k_count[] = "count";
    3605             : static const char __pyx_k_dtype[] = "dtype";
    3606             : static const char __pyx_k_empty[] = "empty";
    3607             : static const char __pyx_k_error[] = "error";
    3608             : static const char __pyx_k_flags[] = "flags";
    3609             : static const char __pyx_k_index[] = "index";
    3610             : static const char __pyx_k_input[] = "input";
    3611             : static const char __pyx_k_label[] = "_label";
    3612             : static const char __pyx_k_numpy[] = "numpy";
    3613             : static const char __pyx_k_range[] = "range";
    3614             : static const char __pyx_k_shape[] = "shape";
    3615             : static const char __pyx_k_split[] = "split";
    3616             : static const char __pyx_k_start[] = "start";
    3617             : static const char __pyx_k_strip[] = "strip";
    3618             : static const char __pyx_k_super[] = "super";
    3619             : static const char __pyx_k_uint8[] = "uint8";
    3620             : static const char __pyx_k_uintp[] = "uintp";
    3621             : static const char __pyx_k_enable[] = "enable";
    3622             : static const char __pyx_k_encode[] = "encode";
    3623             : static const char __pyx_k_format[] = "format";
    3624             : static const char __pyx_k_import[] = "__import__";
    3625             : static const char __pyx_k_int8_t[] = "int8_t";
    3626             : static const char __pyx_k_kwargs[] = "kwargs";
    3627             : static const char __pyx_k_module[] = "__module__";
    3628             : static const char __pyx_k_name_2[] = "__name__";
    3629             : static const char __pyx_k_output[] = "output";
    3630             : static const char __pyx_k_pickle[] = "pickle";
    3631             : static const char __pyx_k_reduce[] = "__reduce__";
    3632             : static const char __pyx_k_struct[] = "struct";
    3633             : static const char __pyx_k_unpack[] = "unpack";
    3634             : static const char __pyx_k_update[] = "update";
    3635             : static const char __pyx_k_values[] = "values";
    3636             : static const char __pyx_k_disable[] = "disable";
    3637             : static const char __pyx_k_fortran[] = "fortran";
    3638             : static const char __pyx_k_int16_t[] = "int16_t";
    3639             : static const char __pyx_k_int32_t[] = "int32_t";
    3640             : static const char __pyx_k_int64_t[] = "int64_t";
    3641             : static const char __pyx_k_memview[] = "memview";
    3642             : static const char __pyx_k_prepare[] = "__prepare__";
    3643             : static const char __pyx_k_uint8_t[] = "uint8_t";
    3644             : static const char __pyx_k_Ellipsis[] = "Ellipsis";
    3645             : static const char __pyx_k_Sequence[] = "Sequence";
    3646             : static const char __pyx_k_defaults[] = "defaults";
    3647             : static const char __pyx_k_getstate[] = "__getstate__";
    3648             : static const char __pyx_k_itemsize[] = "itemsize";
    3649             : static const char __pyx_k_ni_label[] = "_ni_label";
    3650             : static const char __pyx_k_pyx_type[] = "__pyx_type";
    3651             : static const char __pyx_k_qualname[] = "__qualname__";
    3652             : static const char __pyx_k_register[] = "register";
    3653             : static const char __pyx_k_set_name[] = "__set_name__";
    3654             : static const char __pyx_k_setstate[] = "__setstate__";
    3655             : static const char __pyx_k_uint16_t[] = "uint16_t";
    3656             : static const char __pyx_k_uint32_t[] = "uint32_t";
    3657             : static const char __pyx_k_uint64_t[] = "uint64_t";
    3658             : static const char __pyx_k_TypeError[] = "TypeError";
    3659             : static const char __pyx_k_enumerate[] = "enumerate";
    3660             : static const char __pyx_k_float32_t[] = "float32_t";
    3661             : static const char __pyx_k_float64_t[] = "float64_t";
    3662             : static const char __pyx_k_isenabled[] = "isenabled";
    3663             : static const char __pyx_k_metaclass[] = "__metaclass__";
    3664             : static const char __pyx_k_pyx_state[] = "__pyx_state";
    3665             : static const char __pyx_k_reduce_ex[] = "__reduce_ex__";
    3666             : static const char __pyx_k_structure[] = "structure";
    3667             : static const char __pyx_k_IndexError[] = "IndexError";
    3668             : static const char __pyx_k_ValueError[] = "ValueError";
    3669             : static const char __pyx_k_asanyarray[] = "asanyarray";
    3670             : static const char __pyx_k_pyx_result[] = "__pyx_result";
    3671             : static const char __pyx_k_pyx_vtable[] = "__pyx_vtable__";
    3672             : static const char __pyx_k_signatures[] = "signatures";
    3673             : static const char __pyx_k_ImportError[] = "ImportError";
    3674             : static const char __pyx_k_MemoryError[] = "MemoryError";
    3675             : static const char __pyx_k_PickleError[] = "PickleError";
    3676             : static const char __pyx_k_collections[] = "collections";
    3677             : static const char __pyx_k_mro_entries[] = "__mro_entries__";
    3678             : static const char __pyx_k_NeedMoreBits[] = "NeedMoreBits";
    3679             : static const char __pyx_k_initializing[] = "_initializing";
    3680             : static const char __pyx_k_is_coroutine[] = "_is_coroutine";
    3681             : static const char __pyx_k_pyx_checksum[] = "__pyx_checksum";
    3682             : static const char __pyx_k_stringsource[] = "<stringsource>";
    3683             : static const char __pyx_k_version_info[] = "version_info";
    3684             : static const char __pyx_k_class_getitem[] = "__class_getitem__";
    3685             : static const char __pyx_k_get_read_line[] = "get_read_line";
    3686             : static const char __pyx_k_init_subclass[] = "__init_subclass__";
    3687             : static const char __pyx_k_reduce_cython[] = "__reduce_cython__";
    3688             : static const char __pyx_k_AssertionError[] = "AssertionError";
    3689             : static const char __pyx_k_fused_sigindex[] = "_fused_sigindex";
    3690             : static const char __pyx_k_get_write_line[] = "get_write_line";
    3691             : static const char __pyx_k_View_MemoryView[] = "View.MemoryView";
    3692             : static const char __pyx_k_allocate_buffer[] = "allocate_buffer";
    3693             : static const char __pyx_k_collections_abc[] = "collections.abc";
    3694             : static const char __pyx_k_dtype_is_object[] = "dtype_is_object";
    3695             : static const char __pyx_k_pyx_PickleError[] = "__pyx_PickleError";
    3696             : static const char __pyx_k_setstate_cython[] = "__setstate_cython__";
    3697             : static const char __pyx_k_get_nonzero_line[] = "get_nonzero_line";
    3698             : static const char __pyx_k_pyx_unpickle_Enum[] = "__pyx_unpickle_Enum";
    3699             : static const char __pyx_k_asyncio_coroutines[] = "asyncio.coroutines";
    3700             : static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback";
    3701             : static const char __pyx_k_strided_and_direct[] = "<strided and direct>";
    3702             : static const char __pyx_k_strided_and_indirect[] = "<strided and indirect>";
    3703             : static const char __pyx_k_Invalid_shape_in_axis[] = "Invalid shape in axis ";
    3704             : static const char __pyx_k_contiguous_and_direct[] = "<contiguous and direct>";
    3705             : static const char __pyx_k_Cannot_index_with_type[] = "Cannot index with type '";
    3706             : static const char __pyx_k_MemoryView_of_r_object[] = "<MemoryView of %r object>";
    3707             : static const char __pyx_k_MemoryView_of_r_at_0x_x[] = "<MemoryView of %r at 0x%x>";
    3708             : static const char __pyx_k_contiguous_and_indirect[] = "<contiguous and indirect>";
    3709             : static const char __pyx_k_Dimension_d_is_not_direct[] = "Dimension %d is not direct";
    3710             : static const char __pyx_k_Index_out_of_bounds_axis_d[] = "Index out of bounds (axis %d)";
    3711             : static const char __pyx_k_No_matching_signature_found[] = "No matching signature found";
    3712             : static const char __pyx_k_Step_may_not_be_zero_axis_d[] = "Step may not be zero (axis %d)";
    3713             : static const char __pyx_k_itemsize_0_for_cython_array[] = "itemsize <= 0 for cython.array";
    3714             : static const char __pyx_k_unable_to_allocate_array_data[] = "unable to allocate array data.";
    3715             : static const char __pyx_k_strided_and_direct_or_indirect[] = "<strided and direct or indirect>";
    3716             : static const char __pyx_k_Shapes_must_match_for_input_and[] = "Shapes must match for input and output,{} != {}";
    3717             : static const char __pyx_k_home_czgdp18079_Quansight_scipy[] = "/home/czgdp18079/Quansight/scipy/scipy/ndimage/src/_ni_label.pyx";
    3718             : static const char __pyx_k_All_dimensions_preceding_dimensi[] = "All dimensions preceding dimension %d must be indexed and not sliced";
    3719             : static const char __pyx_k_Buffer_view_does_not_expose_stri[] = "Buffer view does not expose strides";
    3720             : static const char __pyx_k_Can_only_create_a_buffer_that_is[] = "Can only create a buffer that is contiguous in memory.";
    3721             : static const char __pyx_k_Cannot_assign_to_read_only_memor[] = "Cannot assign to read-only memoryview";
    3722             : static const char __pyx_k_Cannot_create_writable_memory_vi[] = "Cannot create writable memory view from read-only memoryview";
    3723             : static const char __pyx_k_Cannot_label_scalars_or_empty_ar[] = "Cannot label scalars or empty arrays";
    3724             : static const char __pyx_k_Cannot_transpose_memoryview_with[] = "Cannot transpose memoryview with indirect dimensions";
    3725             : static const char __pyx_k_Empty_shape_tuple_for_cython_arr[] = "Empty shape tuple for cython.array";
    3726             : static const char __pyx_k_Expected_at_least_d_argument_s_g[] = "Expected at least %d argument%s, got %d";
    3727             : static const char __pyx_k_Function_call_with_ambiguous_arg[] = "Function call with ambiguous argument types";
    3728             : static const char __pyx_k_Incompatible_checksums_0x_x_vs_0[] = "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))";
    3729             : static const char __pyx_k_Indirect_dimensions_not_supporte[] = "Indirect dimensions not supported";
    3730             : static const char __pyx_k_Invalid_mode_expected_c_or_fortr[] = "Invalid mode, expected 'c' or 'fortran', got ";
    3731             : static const char __pyx_k_Out_of_bounds_on_buffer_access_a[] = "Out of bounds on buffer access (axis ";
    3732             : static const char __pyx_k_Structuring_element_is_not_symme[] = "Structuring element is not symmetric";
    3733             : static const char __pyx_k_Structuring_element_must_be_size[] = "Structuring element must be size 3 in every dimension, was {}";
    3734             : static const char __pyx_k_Structuring_element_must_have_sa[] = "Structuring element must have same # of dimensions as input, {:d} != {:d}";
    3735             : static const char __pyx_k_Unable_to_convert_item_to_object[] = "Unable to convert item to object";
    3736             : static const char __pyx_k_got_differing_extents_in_dimensi[] = "got differing extents in dimension ";
    3737             : static const char __pyx_k_no_default___reduce___due_to_non[] = "no default __reduce__ due to non-trivial __cinit__";
    3738             : static const char __pyx_k_numpy__core_multiarray_failed_to[] = "numpy._core.multiarray failed to import";
    3739             : static const char __pyx_k_numpy__core_umath_failed_to_impo[] = "numpy._core.umath failed to import";
    3740             : static const char __pyx_k_unable_to_allocate_shape_and_str[] = "unable to allocate shape and strides.";
    3741             : /* #### Code section: decls ### */
    3742             : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize, PyObject *__pyx_v_format, PyObject *__pyx_v_mode, int __pyx_v_allocate_buffer); /* proto */
    3743             : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(struct __pyx_array_obj *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /* proto */
    3744             : static void __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(struct __pyx_array_obj *__pyx_v_self); /* proto */
    3745             : static PyObject *__pyx_pf_15View_dot_MemoryView_5array_7memview___get__(struct __pyx_array_obj *__pyx_v_self); /* proto */
    3746             : static Py_ssize_t __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(struct __pyx_array_obj *__pyx_v_self); /* proto */
    3747             : static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_attr); /* proto */
    3748             : static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item); /* proto */
    3749             : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value); /* proto */
    3750             : static PyObject *__pyx_pf___pyx_array___reduce_cython__(CYTHON_UNUSED struct __pyx_array_obj *__pyx_v_self); /* proto */
    3751             : static PyObject *__pyx_pf___pyx_array_2__setstate_cython__(CYTHON_UNUSED struct __pyx_array_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
    3752             : static int __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v_name); /* proto */
    3753             : static PyObject *__pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(struct __pyx_MemviewEnum_obj *__pyx_v_self); /* proto */
    3754             : static PyObject *__pyx_pf___pyx_MemviewEnum___reduce_cython__(struct __pyx_MemviewEnum_obj *__pyx_v_self); /* proto */
    3755             : static PyObject *__pyx_pf___pyx_MemviewEnum_2__setstate_cython__(struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
    3756             : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj, int __pyx_v_flags, int __pyx_v_dtype_is_object); /* proto */
    3757             : static void __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3758             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index); /* proto */
    3759             : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value); /* proto */
    3760             : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(struct __pyx_memoryview_obj *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /* proto */
    3761             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3762             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3763             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3764             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3765             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3766             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3767             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3768             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3769             : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3770             : static Py_ssize_t __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3771             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3772             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3773             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3774             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3775             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3776             : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3777             : static PyObject *__pyx_pf___pyx_memoryview___reduce_cython__(CYTHON_UNUSED struct __pyx_memoryview_obj *__pyx_v_self); /* proto */
    3778             : static PyObject *__pyx_pf___pyx_memoryview_2__setstate_cython__(CYTHON_UNUSED struct __pyx_memoryview_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
    3779             : static void __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(struct __pyx_memoryviewslice_obj *__pyx_v_self); /* proto */
    3780             : static PyObject *__pyx_pf___pyx_memoryviewslice___reduce_cython__(CYTHON_UNUSED struct __pyx_memoryviewslice_obj *__pyx_v_self); /* proto */
    3781             : static PyObject *__pyx_pf___pyx_memoryviewslice_2__setstate_cython__(CYTHON_UNUSED struct __pyx_memoryviewslice_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
    3782             : static PyObject *__pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
    3783             : static PyObject *__pyx_pf_9_ni_label_get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex); /* proto */
    3784             : static PyObject *__pyx_pf_9_ni_label_8get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3785             : static PyObject *__pyx_pf_9_ni_label_10get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3786             : static PyObject *__pyx_pf_9_ni_label_12get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3787             : static PyObject *__pyx_pf_9_ni_label_14get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3788             : static PyObject *__pyx_pf_9_ni_label_16get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3789             : static PyObject *__pyx_pf_9_ni_label_18get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3790             : static PyObject *__pyx_pf_9_ni_label_20get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3791             : static PyObject *__pyx_pf_9_ni_label_22get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3792             : static PyObject *__pyx_pf_9_ni_label_24get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3793             : static PyObject *__pyx_pf_9_ni_label_26get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3794             : static PyObject *__pyx_pf_9_ni_label_2get_read_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex); /* proto */
    3795             : static PyObject *__pyx_pf_9_ni_label_30get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3796             : static PyObject *__pyx_pf_9_ni_label_32get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3797             : static PyObject *__pyx_pf_9_ni_label_34get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3798             : static PyObject *__pyx_pf_9_ni_label_36get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3799             : static PyObject *__pyx_pf_9_ni_label_38get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3800             : static PyObject *__pyx_pf_9_ni_label_40get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3801             : static PyObject *__pyx_pf_9_ni_label_42get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3802             : static PyObject *__pyx_pf_9_ni_label_44get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3803             : static PyObject *__pyx_pf_9_ni_label_46get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3804             : static PyObject *__pyx_pf_9_ni_label_48get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3805             : static PyObject *__pyx_pf_9_ni_label_4get_write_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex); /* proto */
    3806             : static PyObject *__pyx_pf_9_ni_label_52get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3807             : static PyObject *__pyx_pf_9_ni_label_54get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3808             : static PyObject *__pyx_pf_9_ni_label_56get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3809             : static PyObject *__pyx_pf_9_ni_label_58get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3810             : static PyObject *__pyx_pf_9_ni_label_60get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3811             : static PyObject *__pyx_pf_9_ni_label_62get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3812             : static PyObject *__pyx_pf_9_ni_label_64get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3813             : static PyObject *__pyx_pf_9_ni_label_66get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3814             : static PyObject *__pyx_pf_9_ni_label_68get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3815             : static PyObject *__pyx_pf_9_ni_label_70get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a); /* proto */
    3816             : static PyObject *__pyx_pf_9_ni_label_6_label(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_input, PyArrayObject *__pyx_v_structure, PyArrayObject *__pyx_v_output); /* proto */
    3817             : static PyObject *__pyx_tp_new_array(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
    3818             : static PyObject *__pyx_tp_new_Enum(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
    3819             : static PyObject *__pyx_tp_new_memoryview(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
    3820             : static PyObject *__pyx_tp_new__memoryviewslice(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
    3821             : static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_get = {0, 0, 0, 0, 0};
    3822             : static __Pyx_CachedCFunction __pyx_umethod_PyDict_Type_values = {0, 0, 0, 0, 0};
    3823             : /* #### Code section: late_includes ### */
    3824             : /* #### Code section: module_state ### */
    3825             : typedef struct {
    3826             :   PyObject *__pyx_d;
    3827             :   PyObject *__pyx_b;
    3828             :   PyObject *__pyx_cython_runtime;
    3829             :   PyObject *__pyx_empty_tuple;
    3830             :   PyObject *__pyx_empty_bytes;
    3831             :   PyObject *__pyx_empty_unicode;
    3832             :   #ifdef __Pyx_CyFunction_USED
    3833             :   PyTypeObject *__pyx_CyFunctionType;
    3834             :   #endif
    3835             :   #ifdef __Pyx_FusedFunction_USED
    3836             :   PyTypeObject *__pyx_FusedFunctionType;
    3837             :   #endif
    3838             :   #ifdef __Pyx_Generator_USED
    3839             :   PyTypeObject *__pyx_GeneratorType;
    3840             :   #endif
    3841             :   #ifdef __Pyx_IterableCoroutine_USED
    3842             :   PyTypeObject *__pyx_IterableCoroutineType;
    3843             :   #endif
    3844             :   #ifdef __Pyx_Coroutine_USED
    3845             :   PyTypeObject *__pyx_CoroutineAwaitType;
    3846             :   #endif
    3847             :   #ifdef __Pyx_Coroutine_USED
    3848             :   PyTypeObject *__pyx_CoroutineType;
    3849             :   #endif
    3850             :   #if CYTHON_USE_MODULE_STATE
    3851             :   #endif
    3852             :   #if CYTHON_USE_MODULE_STATE
    3853             :   #endif
    3854             :   #if CYTHON_USE_MODULE_STATE
    3855             :   #endif
    3856             :   #if CYTHON_USE_MODULE_STATE
    3857             :   #endif
    3858             :   PyTypeObject *__pyx_ptype_7cpython_4type_type;
    3859             :   #if CYTHON_USE_MODULE_STATE
    3860             :   #endif
    3861             :   #if CYTHON_USE_MODULE_STATE
    3862             :   #endif
    3863             :   #if CYTHON_USE_MODULE_STATE
    3864             :   #endif
    3865             :   #if CYTHON_USE_MODULE_STATE
    3866             :   #endif
    3867             :   #if CYTHON_USE_MODULE_STATE
    3868             :   #endif
    3869             :   PyTypeObject *__pyx_ptype_5numpy_dtype;
    3870             :   PyTypeObject *__pyx_ptype_5numpy_flatiter;
    3871             :   PyTypeObject *__pyx_ptype_5numpy_broadcast;
    3872             :   PyTypeObject *__pyx_ptype_5numpy_ndarray;
    3873             :   PyTypeObject *__pyx_ptype_5numpy_generic;
    3874             :   PyTypeObject *__pyx_ptype_5numpy_number;
    3875             :   PyTypeObject *__pyx_ptype_5numpy_integer;
    3876             :   PyTypeObject *__pyx_ptype_5numpy_signedinteger;
    3877             :   PyTypeObject *__pyx_ptype_5numpy_unsignedinteger;
    3878             :   PyTypeObject *__pyx_ptype_5numpy_inexact;
    3879             :   PyTypeObject *__pyx_ptype_5numpy_floating;
    3880             :   PyTypeObject *__pyx_ptype_5numpy_complexfloating;
    3881             :   PyTypeObject *__pyx_ptype_5numpy_flexible;
    3882             :   PyTypeObject *__pyx_ptype_5numpy_character;
    3883             :   PyTypeObject *__pyx_ptype_5numpy_ufunc;
    3884             :   #if CYTHON_USE_MODULE_STATE
    3885             :   PyObject *__pyx_type___pyx_array;
    3886             :   PyObject *__pyx_type___pyx_MemviewEnum;
    3887             :   PyObject *__pyx_type___pyx_memoryview;
    3888             :   PyObject *__pyx_type___pyx_memoryviewslice;
    3889             :   #endif
    3890             :   PyTypeObject *__pyx_array_type;
    3891             :   PyTypeObject *__pyx_MemviewEnum_type;
    3892             :   PyTypeObject *__pyx_memoryview_type;
    3893             :   PyTypeObject *__pyx_memoryviewslice_type;
    3894             :   PyObject *__pyx_kp_u_;
    3895             :   PyObject *__pyx_n_s_ASCII;
    3896             :   PyObject *__pyx_kp_s_All_dimensions_preceding_dimensi;
    3897             :   PyObject *__pyx_n_s_AssertionError;
    3898             :   PyObject *__pyx_kp_s_Buffer_view_does_not_expose_stri;
    3899             :   PyObject *__pyx_kp_s_Can_only_create_a_buffer_that_is;
    3900             :   PyObject *__pyx_kp_s_Cannot_assign_to_read_only_memor;
    3901             :   PyObject *__pyx_kp_s_Cannot_create_writable_memory_vi;
    3902             :   PyObject *__pyx_kp_u_Cannot_index_with_type;
    3903             :   PyObject *__pyx_kp_u_Cannot_label_scalars_or_empty_ar;
    3904             :   PyObject *__pyx_kp_s_Cannot_transpose_memoryview_with;
    3905             :   PyObject *__pyx_kp_s_Dimension_d_is_not_direct;
    3906             :   PyObject *__pyx_n_s_Ellipsis;
    3907             :   PyObject *__pyx_kp_s_Empty_shape_tuple_for_cython_arr;
    3908             :   PyObject *__pyx_kp_s_Expected_at_least_d_argument_s_g;
    3909             :   PyObject *__pyx_kp_s_Function_call_with_ambiguous_arg;
    3910             :   PyObject *__pyx_n_s_ImportError;
    3911             :   PyObject *__pyx_kp_s_Incompatible_checksums_0x_x_vs_0;
    3912             :   PyObject *__pyx_n_s_IndexError;
    3913             :   PyObject *__pyx_kp_s_Index_out_of_bounds_axis_d;
    3914             :   PyObject *__pyx_kp_s_Indirect_dimensions_not_supporte;
    3915             :   PyObject *__pyx_kp_u_Invalid_mode_expected_c_or_fortr;
    3916             :   PyObject *__pyx_kp_u_Invalid_shape_in_axis;
    3917             :   PyObject *__pyx_n_s_MemoryError;
    3918             :   PyObject *__pyx_kp_s_MemoryView_of_r_at_0x_x;
    3919             :   PyObject *__pyx_kp_s_MemoryView_of_r_object;
    3920             :   PyObject *__pyx_n_s_NeedMoreBits;
    3921             :   PyObject *__pyx_kp_s_No_matching_signature_found;
    3922             :   PyObject *__pyx_n_b_O;
    3923             :   PyObject *__pyx_kp_u_Out_of_bounds_on_buffer_access_a;
    3924             :   PyObject *__pyx_n_s_PickleError;
    3925             :   PyObject *__pyx_n_s_Sequence;
    3926             :   PyObject *__pyx_kp_u_Shapes_must_match_for_input_and;
    3927             :   PyObject *__pyx_kp_s_Step_may_not_be_zero_axis_d;
    3928             :   PyObject *__pyx_kp_u_Structuring_element_is_not_symme;
    3929             :   PyObject *__pyx_kp_u_Structuring_element_must_be_size;
    3930             :   PyObject *__pyx_kp_u_Structuring_element_must_have_sa;
    3931             :   PyObject *__pyx_n_s_TypeError;
    3932             :   PyObject *__pyx_kp_s_Unable_to_convert_item_to_object;
    3933             :   PyObject *__pyx_n_s_ValueError;
    3934             :   PyObject *__pyx_n_s_View_MemoryView;
    3935             :   PyObject *__pyx_kp_s__11;
    3936             :   PyObject *__pyx_kp_s__12;
    3937             :   PyObject *__pyx_kp_s__13;
    3938             :   PyObject *__pyx_kp_u__13;
    3939             :   PyObject *__pyx_kp_u__2;
    3940             :   PyObject *__pyx_n_s__3;
    3941             :   PyObject *__pyx_n_s__34;
    3942             :   PyObject *__pyx_kp_u__6;
    3943             :   PyObject *__pyx_kp_u__7;
    3944             :   PyObject *__pyx_n_s_a;
    3945             :   PyObject *__pyx_n_s_abc;
    3946             :   PyObject *__pyx_n_s_all;
    3947             :   PyObject *__pyx_n_s_allocate_buffer;
    3948             :   PyObject *__pyx_kp_u_and;
    3949             :   PyObject *__pyx_n_s_args;
    3950             :   PyObject *__pyx_n_s_asanyarray;
    3951             :   PyObject *__pyx_n_s_asyncio_coroutines;
    3952             :   PyObject *__pyx_n_s_base;
    3953             :   PyObject *__pyx_n_s_bool;
    3954             :   PyObject *__pyx_n_s_c;
    3955             :   PyObject *__pyx_n_u_c;
    3956             :   PyObject *__pyx_n_s_class;
    3957             :   PyObject *__pyx_n_s_class_getitem;
    3958             :   PyObject *__pyx_n_s_cline_in_traceback;
    3959             :   PyObject *__pyx_n_s_collections;
    3960             :   PyObject *__pyx_kp_s_collections_abc;
    3961             :   PyObject *__pyx_kp_s_contiguous_and_direct;
    3962             :   PyObject *__pyx_kp_s_contiguous_and_indirect;
    3963             :   PyObject *__pyx_n_s_copy;
    3964             :   PyObject *__pyx_n_s_count;
    3965             :   PyObject *__pyx_n_s_defaults;
    3966             :   PyObject *__pyx_n_s_dict;
    3967             :   PyObject *__pyx_kp_u_disable;
    3968             :   PyObject *__pyx_n_s_doc;
    3969             :   PyObject *__pyx_n_s_dtype;
    3970             :   PyObject *__pyx_n_s_dtype_is_object;
    3971             :   PyObject *__pyx_n_s_empty;
    3972             :   PyObject *__pyx_kp_u_enable;
    3973             :   PyObject *__pyx_n_s_encode;
    3974             :   PyObject *__pyx_n_s_enumerate;
    3975             :   PyObject *__pyx_n_s_error;
    3976             :   PyObject *__pyx_n_s_flags;
    3977             :   PyObject *__pyx_n_s_float32_t;
    3978             :   PyObject *__pyx_n_s_float64_t;
    3979             :   PyObject *__pyx_n_s_format;
    3980             :   PyObject *__pyx_n_s_fortran;
    3981             :   PyObject *__pyx_n_u_fortran;
    3982             :   PyObject *__pyx_n_s_fused_sigindex;
    3983             :   PyObject *__pyx_kp_u_gc;
    3984             :   PyObject *__pyx_n_s_get;
    3985             :   PyObject *__pyx_n_s_get_nonzero_line;
    3986             :   PyObject *__pyx_n_s_get_read_line;
    3987             :   PyObject *__pyx_n_s_get_write_line;
    3988             :   PyObject *__pyx_n_s_getstate;
    3989             :   PyObject *__pyx_kp_u_got;
    3990             :   PyObject *__pyx_kp_u_got_differing_extents_in_dimensi;
    3991             :   PyObject *__pyx_kp_s_home_czgdp18079_Quansight_scipy;
    3992             :   PyObject *__pyx_n_s_id;
    3993             :   PyObject *__pyx_n_s_import;
    3994             :   PyObject *__pyx_n_s_index;
    3995             :   PyObject *__pyx_n_s_init_subclass;
    3996             :   PyObject *__pyx_n_s_initializing;
    3997             :   PyObject *__pyx_n_s_input;
    3998             :   PyObject *__pyx_n_s_int16_t;
    3999             :   PyObject *__pyx_n_s_int32_t;
    4000             :   PyObject *__pyx_n_s_int64_t;
    4001             :   PyObject *__pyx_n_s_int8_t;
    4002             :   PyObject *__pyx_n_s_is_coroutine;
    4003             :   PyObject *__pyx_kp_u_isenabled;
    4004             :   PyObject *__pyx_n_s_itemsize;
    4005             :   PyObject *__pyx_kp_s_itemsize_0_for_cython_array;
    4006             :   PyObject *__pyx_n_s_kind;
    4007             :   PyObject *__pyx_n_s_kwargs;
    4008             :   PyObject *__pyx_n_s_label;
    4009             :   PyObject *__pyx_n_s_main;
    4010             :   PyObject *__pyx_n_s_memview;
    4011             :   PyObject *__pyx_n_s_metaclass;
    4012             :   PyObject *__pyx_n_s_mode;
    4013             :   PyObject *__pyx_n_s_module;
    4014             :   PyObject *__pyx_n_s_mro_entries;
    4015             :   PyObject *__pyx_n_s_name;
    4016             :   PyObject *__pyx_n_s_name_2;
    4017             :   PyObject *__pyx_n_s_ndim;
    4018             :   PyObject *__pyx_n_s_new;
    4019             :   PyObject *__pyx_n_s_ni_label;
    4020             :   PyObject *__pyx_kp_s_no_default___reduce___due_to_non;
    4021             :   PyObject *__pyx_n_s_np;
    4022             :   PyObject *__pyx_n_s_numpy;
    4023             :   PyObject *__pyx_kp_u_numpy__core_multiarray_failed_to;
    4024             :   PyObject *__pyx_kp_u_numpy__core_umath_failed_to_impo;
    4025             :   PyObject *__pyx_n_s_obj;
    4026             :   PyObject *__pyx_n_s_output;
    4027             :   PyObject *__pyx_n_s_pack;
    4028             :   PyObject *__pyx_n_s_pickle;
    4029             :   PyObject *__pyx_n_s_prepare;
    4030             :   PyObject *__pyx_n_s_pyx_PickleError;
    4031             :   PyObject *__pyx_n_s_pyx_checksum;
    4032             :   PyObject *__pyx_n_s_pyx_result;
    4033             :   PyObject *__pyx_n_s_pyx_state;
    4034             :   PyObject *__pyx_n_s_pyx_type;
    4035             :   PyObject *__pyx_n_s_pyx_unpickle_Enum;
    4036             :   PyObject *__pyx_n_s_pyx_vtable;
    4037             :   PyObject *__pyx_n_s_qualname;
    4038             :   PyObject *__pyx_n_s_range;
    4039             :   PyObject *__pyx_n_s_reduce;
    4040             :   PyObject *__pyx_n_s_reduce_cython;
    4041             :   PyObject *__pyx_n_s_reduce_ex;
    4042             :   PyObject *__pyx_n_s_register;
    4043             :   PyObject *__pyx_n_s_s;
    4044             :   PyObject *__pyx_n_s_set_name;
    4045             :   PyObject *__pyx_n_s_setstate;
    4046             :   PyObject *__pyx_n_s_setstate_cython;
    4047             :   PyObject *__pyx_n_s_shape;
    4048             :   PyObject *__pyx_n_s_signatures;
    4049             :   PyObject *__pyx_n_s_size;
    4050             :   PyObject *__pyx_n_s_spec;
    4051             :   PyObject *__pyx_n_s_split;
    4052             :   PyObject *__pyx_n_s_start;
    4053             :   PyObject *__pyx_n_s_step;
    4054             :   PyObject *__pyx_n_s_stop;
    4055             :   PyObject *__pyx_kp_s_strided_and_direct;
    4056             :   PyObject *__pyx_kp_s_strided_and_direct_or_indirect;
    4057             :   PyObject *__pyx_kp_s_strided_and_indirect;
    4058             :   PyObject *__pyx_kp_s_stringsource;
    4059             :   PyObject *__pyx_n_s_strip;
    4060             :   PyObject *__pyx_n_s_struct;
    4061             :   PyObject *__pyx_n_s_structure;
    4062             :   PyObject *__pyx_n_s_super;
    4063             :   PyObject *__pyx_n_s_sys;
    4064             :   PyObject *__pyx_n_s_take;
    4065             :   PyObject *__pyx_n_s_test;
    4066             :   PyObject *__pyx_n_s_uint16_t;
    4067             :   PyObject *__pyx_n_s_uint32_t;
    4068             :   PyObject *__pyx_n_s_uint64_t;
    4069             :   PyObject *__pyx_n_s_uint8;
    4070             :   PyObject *__pyx_n_s_uint8_t;
    4071             :   PyObject *__pyx_n_s_uintp;
    4072             :   PyObject *__pyx_kp_s_unable_to_allocate_array_data;
    4073             :   PyObject *__pyx_kp_s_unable_to_allocate_shape_and_str;
    4074             :   PyObject *__pyx_n_s_unpack;
    4075             :   PyObject *__pyx_n_s_update;
    4076             :   PyObject *__pyx_n_s_values;
    4077             :   PyObject *__pyx_n_s_version_info;
    4078             :   PyObject *__pyx_n_s_view;
    4079             :   PyObject *__pyx_int_0;
    4080             :   PyObject *__pyx_int_1;
    4081             :   PyObject *__pyx_int_3;
    4082             :   PyObject *__pyx_int_112105877;
    4083             :   PyObject *__pyx_int_136983863;
    4084             :   PyObject *__pyx_int_184977713;
    4085             :   PyObject *__pyx_int_neg_1;
    4086             :   PyObject *__pyx_slice__5;
    4087             :   PyObject *__pyx_tuple__4;
    4088             :   PyObject *__pyx_tuple__8;
    4089             :   PyObject *__pyx_tuple__9;
    4090             :   PyObject *__pyx_slice__16;
    4091             :   PyObject *__pyx_tuple__10;
    4092             :   PyObject *__pyx_tuple__14;
    4093             :   PyObject *__pyx_tuple__15;
    4094             :   PyObject *__pyx_tuple__17;
    4095             :   PyObject *__pyx_tuple__18;
    4096             :   PyObject *__pyx_tuple__19;
    4097             :   PyObject *__pyx_tuple__20;
    4098             :   PyObject *__pyx_tuple__21;
    4099             :   PyObject *__pyx_tuple__22;
    4100             :   PyObject *__pyx_tuple__23;
    4101             :   PyObject *__pyx_tuple__24;
    4102             :   PyObject *__pyx_tuple__25;
    4103             :   PyObject *__pyx_tuple__26;
    4104             :   PyObject *__pyx_tuple__28;
    4105             :   PyObject *__pyx_tuple__32;
    4106             :   PyObject *__pyx_codeobj__27;
    4107             :   PyObject *__pyx_codeobj__29;
    4108             :   PyObject *__pyx_codeobj__30;
    4109             :   PyObject *__pyx_codeobj__31;
    4110             :   PyObject *__pyx_codeobj__33;
    4111             : } __pyx_mstate;
    4112             : 
    4113             : #if CYTHON_USE_MODULE_STATE
    4114             : #ifdef __cplusplus
    4115             : namespace {
    4116             :   extern struct PyModuleDef __pyx_moduledef;
    4117             : } /* anonymous namespace */
    4118             : #else
    4119             : static struct PyModuleDef __pyx_moduledef;
    4120             : #endif
    4121             : 
    4122             : #define __pyx_mstate(o) ((__pyx_mstate *)__Pyx_PyModule_GetState(o))
    4123             : 
    4124             : #define __pyx_mstate_global (__pyx_mstate(PyState_FindModule(&__pyx_moduledef)))
    4125             : 
    4126             : #define __pyx_m (PyState_FindModule(&__pyx_moduledef))
    4127             : #else
    4128             : static __pyx_mstate __pyx_mstate_global_static =
    4129             : #ifdef __cplusplus
    4130             :     {};
    4131             : #else
    4132             :     {0};
    4133             : #endif
    4134             : static __pyx_mstate *__pyx_mstate_global = &__pyx_mstate_global_static;
    4135             : #endif
    4136             : /* #### Code section: module_state_clear ### */
    4137             : #if CYTHON_USE_MODULE_STATE
    4138             : static int __pyx_m_clear(PyObject *m) {
    4139             :   __pyx_mstate *clear_module_state = __pyx_mstate(m);
    4140             :   if (!clear_module_state) return 0;
    4141             :   Py_CLEAR(clear_module_state->__pyx_d);
    4142             :   Py_CLEAR(clear_module_state->__pyx_b);
    4143             :   Py_CLEAR(clear_module_state->__pyx_cython_runtime);
    4144             :   Py_CLEAR(clear_module_state->__pyx_empty_tuple);
    4145             :   Py_CLEAR(clear_module_state->__pyx_empty_bytes);
    4146             :   Py_CLEAR(clear_module_state->__pyx_empty_unicode);
    4147             :   #ifdef __Pyx_CyFunction_USED
    4148             :   Py_CLEAR(clear_module_state->__pyx_CyFunctionType);
    4149             :   #endif
    4150             :   #ifdef __Pyx_FusedFunction_USED
    4151             :   Py_CLEAR(clear_module_state->__pyx_FusedFunctionType);
    4152             :   #endif
    4153             :   Py_CLEAR(clear_module_state->__pyx_ptype_7cpython_4type_type);
    4154             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_dtype);
    4155             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_flatiter);
    4156             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_broadcast);
    4157             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_ndarray);
    4158             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_generic);
    4159             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_number);
    4160             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_integer);
    4161             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_signedinteger);
    4162             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_unsignedinteger);
    4163             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_inexact);
    4164             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_floating);
    4165             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_complexfloating);
    4166             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_flexible);
    4167             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_character);
    4168             :   Py_CLEAR(clear_module_state->__pyx_ptype_5numpy_ufunc);
    4169             :   Py_CLEAR(clear_module_state->__pyx_array_type);
    4170             :   Py_CLEAR(clear_module_state->__pyx_type___pyx_array);
    4171             :   Py_CLEAR(clear_module_state->__pyx_MemviewEnum_type);
    4172             :   Py_CLEAR(clear_module_state->__pyx_type___pyx_MemviewEnum);
    4173             :   Py_CLEAR(clear_module_state->__pyx_memoryview_type);
    4174             :   Py_CLEAR(clear_module_state->__pyx_type___pyx_memoryview);
    4175             :   Py_CLEAR(clear_module_state->__pyx_memoryviewslice_type);
    4176             :   Py_CLEAR(clear_module_state->__pyx_type___pyx_memoryviewslice);
    4177             :   Py_CLEAR(clear_module_state->__pyx_kp_u_);
    4178             :   Py_CLEAR(clear_module_state->__pyx_n_s_ASCII);
    4179             :   Py_CLEAR(clear_module_state->__pyx_kp_s_All_dimensions_preceding_dimensi);
    4180             :   Py_CLEAR(clear_module_state->__pyx_n_s_AssertionError);
    4181             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Buffer_view_does_not_expose_stri);
    4182             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Can_only_create_a_buffer_that_is);
    4183             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Cannot_assign_to_read_only_memor);
    4184             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Cannot_create_writable_memory_vi);
    4185             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Cannot_index_with_type);
    4186             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Cannot_label_scalars_or_empty_ar);
    4187             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Cannot_transpose_memoryview_with);
    4188             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Dimension_d_is_not_direct);
    4189             :   Py_CLEAR(clear_module_state->__pyx_n_s_Ellipsis);
    4190             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Empty_shape_tuple_for_cython_arr);
    4191             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Expected_at_least_d_argument_s_g);
    4192             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Function_call_with_ambiguous_arg);
    4193             :   Py_CLEAR(clear_module_state->__pyx_n_s_ImportError);
    4194             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Incompatible_checksums_0x_x_vs_0);
    4195             :   Py_CLEAR(clear_module_state->__pyx_n_s_IndexError);
    4196             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Index_out_of_bounds_axis_d);
    4197             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Indirect_dimensions_not_supporte);
    4198             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Invalid_mode_expected_c_or_fortr);
    4199             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Invalid_shape_in_axis);
    4200             :   Py_CLEAR(clear_module_state->__pyx_n_s_MemoryError);
    4201             :   Py_CLEAR(clear_module_state->__pyx_kp_s_MemoryView_of_r_at_0x_x);
    4202             :   Py_CLEAR(clear_module_state->__pyx_kp_s_MemoryView_of_r_object);
    4203             :   Py_CLEAR(clear_module_state->__pyx_n_s_NeedMoreBits);
    4204             :   Py_CLEAR(clear_module_state->__pyx_kp_s_No_matching_signature_found);
    4205             :   Py_CLEAR(clear_module_state->__pyx_n_b_O);
    4206             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
    4207             :   Py_CLEAR(clear_module_state->__pyx_n_s_PickleError);
    4208             :   Py_CLEAR(clear_module_state->__pyx_n_s_Sequence);
    4209             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Shapes_must_match_for_input_and);
    4210             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Step_may_not_be_zero_axis_d);
    4211             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Structuring_element_is_not_symme);
    4212             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Structuring_element_must_be_size);
    4213             :   Py_CLEAR(clear_module_state->__pyx_kp_u_Structuring_element_must_have_sa);
    4214             :   Py_CLEAR(clear_module_state->__pyx_n_s_TypeError);
    4215             :   Py_CLEAR(clear_module_state->__pyx_kp_s_Unable_to_convert_item_to_object);
    4216             :   Py_CLEAR(clear_module_state->__pyx_n_s_ValueError);
    4217             :   Py_CLEAR(clear_module_state->__pyx_n_s_View_MemoryView);
    4218             :   Py_CLEAR(clear_module_state->__pyx_kp_s__11);
    4219             :   Py_CLEAR(clear_module_state->__pyx_kp_s__12);
    4220             :   Py_CLEAR(clear_module_state->__pyx_kp_s__13);
    4221             :   Py_CLEAR(clear_module_state->__pyx_kp_u__13);
    4222             :   Py_CLEAR(clear_module_state->__pyx_kp_u__2);
    4223             :   Py_CLEAR(clear_module_state->__pyx_n_s__3);
    4224             :   Py_CLEAR(clear_module_state->__pyx_n_s__34);
    4225             :   Py_CLEAR(clear_module_state->__pyx_kp_u__6);
    4226             :   Py_CLEAR(clear_module_state->__pyx_kp_u__7);
    4227             :   Py_CLEAR(clear_module_state->__pyx_n_s_a);
    4228             :   Py_CLEAR(clear_module_state->__pyx_n_s_abc);
    4229             :   Py_CLEAR(clear_module_state->__pyx_n_s_all);
    4230             :   Py_CLEAR(clear_module_state->__pyx_n_s_allocate_buffer);
    4231             :   Py_CLEAR(clear_module_state->__pyx_kp_u_and);
    4232             :   Py_CLEAR(clear_module_state->__pyx_n_s_args);
    4233             :   Py_CLEAR(clear_module_state->__pyx_n_s_asanyarray);
    4234             :   Py_CLEAR(clear_module_state->__pyx_n_s_asyncio_coroutines);
    4235             :   Py_CLEAR(clear_module_state->__pyx_n_s_base);
    4236             :   Py_CLEAR(clear_module_state->__pyx_n_s_bool);
    4237             :   Py_CLEAR(clear_module_state->__pyx_n_s_c);
    4238             :   Py_CLEAR(clear_module_state->__pyx_n_u_c);
    4239             :   Py_CLEAR(clear_module_state->__pyx_n_s_class);
    4240             :   Py_CLEAR(clear_module_state->__pyx_n_s_class_getitem);
    4241             :   Py_CLEAR(clear_module_state->__pyx_n_s_cline_in_traceback);
    4242             :   Py_CLEAR(clear_module_state->__pyx_n_s_collections);
    4243             :   Py_CLEAR(clear_module_state->__pyx_kp_s_collections_abc);
    4244             :   Py_CLEAR(clear_module_state->__pyx_kp_s_contiguous_and_direct);
    4245             :   Py_CLEAR(clear_module_state->__pyx_kp_s_contiguous_and_indirect);
    4246             :   Py_CLEAR(clear_module_state->__pyx_n_s_copy);
    4247             :   Py_CLEAR(clear_module_state->__pyx_n_s_count);
    4248             :   Py_CLEAR(clear_module_state->__pyx_n_s_defaults);
    4249             :   Py_CLEAR(clear_module_state->__pyx_n_s_dict);
    4250             :   Py_CLEAR(clear_module_state->__pyx_kp_u_disable);
    4251             :   Py_CLEAR(clear_module_state->__pyx_n_s_doc);
    4252             :   Py_CLEAR(clear_module_state->__pyx_n_s_dtype);
    4253             :   Py_CLEAR(clear_module_state->__pyx_n_s_dtype_is_object);
    4254             :   Py_CLEAR(clear_module_state->__pyx_n_s_empty);
    4255             :   Py_CLEAR(clear_module_state->__pyx_kp_u_enable);
    4256             :   Py_CLEAR(clear_module_state->__pyx_n_s_encode);
    4257             :   Py_CLEAR(clear_module_state->__pyx_n_s_enumerate);
    4258             :   Py_CLEAR(clear_module_state->__pyx_n_s_error);
    4259             :   Py_CLEAR(clear_module_state->__pyx_n_s_flags);
    4260             :   Py_CLEAR(clear_module_state->__pyx_n_s_float32_t);
    4261             :   Py_CLEAR(clear_module_state->__pyx_n_s_float64_t);
    4262             :   Py_CLEAR(clear_module_state->__pyx_n_s_format);
    4263             :   Py_CLEAR(clear_module_state->__pyx_n_s_fortran);
    4264             :   Py_CLEAR(clear_module_state->__pyx_n_u_fortran);
    4265             :   Py_CLEAR(clear_module_state->__pyx_n_s_fused_sigindex);
    4266             :   Py_CLEAR(clear_module_state->__pyx_kp_u_gc);
    4267             :   Py_CLEAR(clear_module_state->__pyx_n_s_get);
    4268             :   Py_CLEAR(clear_module_state->__pyx_n_s_get_nonzero_line);
    4269             :   Py_CLEAR(clear_module_state->__pyx_n_s_get_read_line);
    4270             :   Py_CLEAR(clear_module_state->__pyx_n_s_get_write_line);
    4271             :   Py_CLEAR(clear_module_state->__pyx_n_s_getstate);
    4272             :   Py_CLEAR(clear_module_state->__pyx_kp_u_got);
    4273             :   Py_CLEAR(clear_module_state->__pyx_kp_u_got_differing_extents_in_dimensi);
    4274             :   Py_CLEAR(clear_module_state->__pyx_kp_s_home_czgdp18079_Quansight_scipy);
    4275             :   Py_CLEAR(clear_module_state->__pyx_n_s_id);
    4276             :   Py_CLEAR(clear_module_state->__pyx_n_s_import);
    4277             :   Py_CLEAR(clear_module_state->__pyx_n_s_index);
    4278             :   Py_CLEAR(clear_module_state->__pyx_n_s_init_subclass);
    4279             :   Py_CLEAR(clear_module_state->__pyx_n_s_initializing);
    4280             :   Py_CLEAR(clear_module_state->__pyx_n_s_input);
    4281             :   Py_CLEAR(clear_module_state->__pyx_n_s_int16_t);
    4282             :   Py_CLEAR(clear_module_state->__pyx_n_s_int32_t);
    4283             :   Py_CLEAR(clear_module_state->__pyx_n_s_int64_t);
    4284             :   Py_CLEAR(clear_module_state->__pyx_n_s_int8_t);
    4285             :   Py_CLEAR(clear_module_state->__pyx_n_s_is_coroutine);
    4286             :   Py_CLEAR(clear_module_state->__pyx_kp_u_isenabled);
    4287             :   Py_CLEAR(clear_module_state->__pyx_n_s_itemsize);
    4288             :   Py_CLEAR(clear_module_state->__pyx_kp_s_itemsize_0_for_cython_array);
    4289             :   Py_CLEAR(clear_module_state->__pyx_n_s_kind);
    4290             :   Py_CLEAR(clear_module_state->__pyx_n_s_kwargs);
    4291             :   Py_CLEAR(clear_module_state->__pyx_n_s_label);
    4292             :   Py_CLEAR(clear_module_state->__pyx_n_s_main);
    4293             :   Py_CLEAR(clear_module_state->__pyx_n_s_memview);
    4294             :   Py_CLEAR(clear_module_state->__pyx_n_s_metaclass);
    4295             :   Py_CLEAR(clear_module_state->__pyx_n_s_mode);
    4296             :   Py_CLEAR(clear_module_state->__pyx_n_s_module);
    4297             :   Py_CLEAR(clear_module_state->__pyx_n_s_mro_entries);
    4298             :   Py_CLEAR(clear_module_state->__pyx_n_s_name);
    4299             :   Py_CLEAR(clear_module_state->__pyx_n_s_name_2);
    4300             :   Py_CLEAR(clear_module_state->__pyx_n_s_ndim);
    4301             :   Py_CLEAR(clear_module_state->__pyx_n_s_new);
    4302             :   Py_CLEAR(clear_module_state->__pyx_n_s_ni_label);
    4303             :   Py_CLEAR(clear_module_state->__pyx_kp_s_no_default___reduce___due_to_non);
    4304             :   Py_CLEAR(clear_module_state->__pyx_n_s_np);
    4305             :   Py_CLEAR(clear_module_state->__pyx_n_s_numpy);
    4306             :   Py_CLEAR(clear_module_state->__pyx_kp_u_numpy__core_multiarray_failed_to);
    4307             :   Py_CLEAR(clear_module_state->__pyx_kp_u_numpy__core_umath_failed_to_impo);
    4308             :   Py_CLEAR(clear_module_state->__pyx_n_s_obj);
    4309             :   Py_CLEAR(clear_module_state->__pyx_n_s_output);
    4310             :   Py_CLEAR(clear_module_state->__pyx_n_s_pack);
    4311             :   Py_CLEAR(clear_module_state->__pyx_n_s_pickle);
    4312             :   Py_CLEAR(clear_module_state->__pyx_n_s_prepare);
    4313             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_PickleError);
    4314             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_checksum);
    4315             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_result);
    4316             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_state);
    4317             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_type);
    4318             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_unpickle_Enum);
    4319             :   Py_CLEAR(clear_module_state->__pyx_n_s_pyx_vtable);
    4320             :   Py_CLEAR(clear_module_state->__pyx_n_s_qualname);
    4321             :   Py_CLEAR(clear_module_state->__pyx_n_s_range);
    4322             :   Py_CLEAR(clear_module_state->__pyx_n_s_reduce);
    4323             :   Py_CLEAR(clear_module_state->__pyx_n_s_reduce_cython);
    4324             :   Py_CLEAR(clear_module_state->__pyx_n_s_reduce_ex);
    4325             :   Py_CLEAR(clear_module_state->__pyx_n_s_register);
    4326             :   Py_CLEAR(clear_module_state->__pyx_n_s_s);
    4327             :   Py_CLEAR(clear_module_state->__pyx_n_s_set_name);
    4328             :   Py_CLEAR(clear_module_state->__pyx_n_s_setstate);
    4329             :   Py_CLEAR(clear_module_state->__pyx_n_s_setstate_cython);
    4330             :   Py_CLEAR(clear_module_state->__pyx_n_s_shape);
    4331             :   Py_CLEAR(clear_module_state->__pyx_n_s_signatures);
    4332             :   Py_CLEAR(clear_module_state->__pyx_n_s_size);
    4333             :   Py_CLEAR(clear_module_state->__pyx_n_s_spec);
    4334             :   Py_CLEAR(clear_module_state->__pyx_n_s_split);
    4335             :   Py_CLEAR(clear_module_state->__pyx_n_s_start);
    4336             :   Py_CLEAR(clear_module_state->__pyx_n_s_step);
    4337             :   Py_CLEAR(clear_module_state->__pyx_n_s_stop);
    4338             :   Py_CLEAR(clear_module_state->__pyx_kp_s_strided_and_direct);
    4339             :   Py_CLEAR(clear_module_state->__pyx_kp_s_strided_and_direct_or_indirect);
    4340             :   Py_CLEAR(clear_module_state->__pyx_kp_s_strided_and_indirect);
    4341             :   Py_CLEAR(clear_module_state->__pyx_kp_s_stringsource);
    4342             :   Py_CLEAR(clear_module_state->__pyx_n_s_strip);
    4343             :   Py_CLEAR(clear_module_state->__pyx_n_s_struct);
    4344             :   Py_CLEAR(clear_module_state->__pyx_n_s_structure);
    4345             :   Py_CLEAR(clear_module_state->__pyx_n_s_super);
    4346             :   Py_CLEAR(clear_module_state->__pyx_n_s_sys);
    4347             :   Py_CLEAR(clear_module_state->__pyx_n_s_take);
    4348             :   Py_CLEAR(clear_module_state->__pyx_n_s_test);
    4349             :   Py_CLEAR(clear_module_state->__pyx_n_s_uint16_t);
    4350             :   Py_CLEAR(clear_module_state->__pyx_n_s_uint32_t);
    4351             :   Py_CLEAR(clear_module_state->__pyx_n_s_uint64_t);
    4352             :   Py_CLEAR(clear_module_state->__pyx_n_s_uint8);
    4353             :   Py_CLEAR(clear_module_state->__pyx_n_s_uint8_t);
    4354             :   Py_CLEAR(clear_module_state->__pyx_n_s_uintp);
    4355             :   Py_CLEAR(clear_module_state->__pyx_kp_s_unable_to_allocate_array_data);
    4356             :   Py_CLEAR(clear_module_state->__pyx_kp_s_unable_to_allocate_shape_and_str);
    4357             :   Py_CLEAR(clear_module_state->__pyx_n_s_unpack);
    4358             :   Py_CLEAR(clear_module_state->__pyx_n_s_update);
    4359             :   Py_CLEAR(clear_module_state->__pyx_n_s_values);
    4360             :   Py_CLEAR(clear_module_state->__pyx_n_s_version_info);
    4361             :   Py_CLEAR(clear_module_state->__pyx_n_s_view);
    4362             :   Py_CLEAR(clear_module_state->__pyx_int_0);
    4363             :   Py_CLEAR(clear_module_state->__pyx_int_1);
    4364             :   Py_CLEAR(clear_module_state->__pyx_int_3);
    4365             :   Py_CLEAR(clear_module_state->__pyx_int_112105877);
    4366             :   Py_CLEAR(clear_module_state->__pyx_int_136983863);
    4367             :   Py_CLEAR(clear_module_state->__pyx_int_184977713);
    4368             :   Py_CLEAR(clear_module_state->__pyx_int_neg_1);
    4369             :   Py_CLEAR(clear_module_state->__pyx_slice__5);
    4370             :   Py_CLEAR(clear_module_state->__pyx_tuple__4);
    4371             :   Py_CLEAR(clear_module_state->__pyx_tuple__8);
    4372             :   Py_CLEAR(clear_module_state->__pyx_tuple__9);
    4373             :   Py_CLEAR(clear_module_state->__pyx_slice__16);
    4374             :   Py_CLEAR(clear_module_state->__pyx_tuple__10);
    4375             :   Py_CLEAR(clear_module_state->__pyx_tuple__14);
    4376             :   Py_CLEAR(clear_module_state->__pyx_tuple__15);
    4377             :   Py_CLEAR(clear_module_state->__pyx_tuple__17);
    4378             :   Py_CLEAR(clear_module_state->__pyx_tuple__18);
    4379             :   Py_CLEAR(clear_module_state->__pyx_tuple__19);
    4380             :   Py_CLEAR(clear_module_state->__pyx_tuple__20);
    4381             :   Py_CLEAR(clear_module_state->__pyx_tuple__21);
    4382             :   Py_CLEAR(clear_module_state->__pyx_tuple__22);
    4383             :   Py_CLEAR(clear_module_state->__pyx_tuple__23);
    4384             :   Py_CLEAR(clear_module_state->__pyx_tuple__24);
    4385             :   Py_CLEAR(clear_module_state->__pyx_tuple__25);
    4386             :   Py_CLEAR(clear_module_state->__pyx_tuple__26);
    4387             :   Py_CLEAR(clear_module_state->__pyx_tuple__28);
    4388             :   Py_CLEAR(clear_module_state->__pyx_tuple__32);
    4389             :   Py_CLEAR(clear_module_state->__pyx_codeobj__27);
    4390             :   Py_CLEAR(clear_module_state->__pyx_codeobj__29);
    4391             :   Py_CLEAR(clear_module_state->__pyx_codeobj__30);
    4392             :   Py_CLEAR(clear_module_state->__pyx_codeobj__31);
    4393             :   Py_CLEAR(clear_module_state->__pyx_codeobj__33);
    4394             :   return 0;
    4395             : }
    4396             : #endif
    4397             : /* #### Code section: module_state_traverse ### */
    4398             : #if CYTHON_USE_MODULE_STATE
    4399             : static int __pyx_m_traverse(PyObject *m, visitproc visit, void *arg) {
    4400             :   __pyx_mstate *traverse_module_state = __pyx_mstate(m);
    4401             :   if (!traverse_module_state) return 0;
    4402             :   Py_VISIT(traverse_module_state->__pyx_d);
    4403             :   Py_VISIT(traverse_module_state->__pyx_b);
    4404             :   Py_VISIT(traverse_module_state->__pyx_cython_runtime);
    4405             :   Py_VISIT(traverse_module_state->__pyx_empty_tuple);
    4406             :   Py_VISIT(traverse_module_state->__pyx_empty_bytes);
    4407             :   Py_VISIT(traverse_module_state->__pyx_empty_unicode);
    4408             :   #ifdef __Pyx_CyFunction_USED
    4409             :   Py_VISIT(traverse_module_state->__pyx_CyFunctionType);
    4410             :   #endif
    4411             :   #ifdef __Pyx_FusedFunction_USED
    4412             :   Py_VISIT(traverse_module_state->__pyx_FusedFunctionType);
    4413             :   #endif
    4414             :   Py_VISIT(traverse_module_state->__pyx_ptype_7cpython_4type_type);
    4415             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_dtype);
    4416             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_flatiter);
    4417             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_broadcast);
    4418             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_ndarray);
    4419             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_generic);
    4420             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_number);
    4421             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_integer);
    4422             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_signedinteger);
    4423             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_unsignedinteger);
    4424             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_inexact);
    4425             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_floating);
    4426             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_complexfloating);
    4427             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_flexible);
    4428             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_character);
    4429             :   Py_VISIT(traverse_module_state->__pyx_ptype_5numpy_ufunc);
    4430             :   Py_VISIT(traverse_module_state->__pyx_array_type);
    4431             :   Py_VISIT(traverse_module_state->__pyx_type___pyx_array);
    4432             :   Py_VISIT(traverse_module_state->__pyx_MemviewEnum_type);
    4433             :   Py_VISIT(traverse_module_state->__pyx_type___pyx_MemviewEnum);
    4434             :   Py_VISIT(traverse_module_state->__pyx_memoryview_type);
    4435             :   Py_VISIT(traverse_module_state->__pyx_type___pyx_memoryview);
    4436             :   Py_VISIT(traverse_module_state->__pyx_memoryviewslice_type);
    4437             :   Py_VISIT(traverse_module_state->__pyx_type___pyx_memoryviewslice);
    4438             :   Py_VISIT(traverse_module_state->__pyx_kp_u_);
    4439             :   Py_VISIT(traverse_module_state->__pyx_n_s_ASCII);
    4440             :   Py_VISIT(traverse_module_state->__pyx_kp_s_All_dimensions_preceding_dimensi);
    4441             :   Py_VISIT(traverse_module_state->__pyx_n_s_AssertionError);
    4442             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Buffer_view_does_not_expose_stri);
    4443             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Can_only_create_a_buffer_that_is);
    4444             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Cannot_assign_to_read_only_memor);
    4445             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Cannot_create_writable_memory_vi);
    4446             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Cannot_index_with_type);
    4447             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Cannot_label_scalars_or_empty_ar);
    4448             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Cannot_transpose_memoryview_with);
    4449             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Dimension_d_is_not_direct);
    4450             :   Py_VISIT(traverse_module_state->__pyx_n_s_Ellipsis);
    4451             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Empty_shape_tuple_for_cython_arr);
    4452             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Expected_at_least_d_argument_s_g);
    4453             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Function_call_with_ambiguous_arg);
    4454             :   Py_VISIT(traverse_module_state->__pyx_n_s_ImportError);
    4455             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Incompatible_checksums_0x_x_vs_0);
    4456             :   Py_VISIT(traverse_module_state->__pyx_n_s_IndexError);
    4457             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Index_out_of_bounds_axis_d);
    4458             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Indirect_dimensions_not_supporte);
    4459             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Invalid_mode_expected_c_or_fortr);
    4460             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Invalid_shape_in_axis);
    4461             :   Py_VISIT(traverse_module_state->__pyx_n_s_MemoryError);
    4462             :   Py_VISIT(traverse_module_state->__pyx_kp_s_MemoryView_of_r_at_0x_x);
    4463             :   Py_VISIT(traverse_module_state->__pyx_kp_s_MemoryView_of_r_object);
    4464             :   Py_VISIT(traverse_module_state->__pyx_n_s_NeedMoreBits);
    4465             :   Py_VISIT(traverse_module_state->__pyx_kp_s_No_matching_signature_found);
    4466             :   Py_VISIT(traverse_module_state->__pyx_n_b_O);
    4467             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
    4468             :   Py_VISIT(traverse_module_state->__pyx_n_s_PickleError);
    4469             :   Py_VISIT(traverse_module_state->__pyx_n_s_Sequence);
    4470             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Shapes_must_match_for_input_and);
    4471             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Step_may_not_be_zero_axis_d);
    4472             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Structuring_element_is_not_symme);
    4473             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Structuring_element_must_be_size);
    4474             :   Py_VISIT(traverse_module_state->__pyx_kp_u_Structuring_element_must_have_sa);
    4475             :   Py_VISIT(traverse_module_state->__pyx_n_s_TypeError);
    4476             :   Py_VISIT(traverse_module_state->__pyx_kp_s_Unable_to_convert_item_to_object);
    4477             :   Py_VISIT(traverse_module_state->__pyx_n_s_ValueError);
    4478             :   Py_VISIT(traverse_module_state->__pyx_n_s_View_MemoryView);
    4479             :   Py_VISIT(traverse_module_state->__pyx_kp_s__11);
    4480             :   Py_VISIT(traverse_module_state->__pyx_kp_s__12);
    4481             :   Py_VISIT(traverse_module_state->__pyx_kp_s__13);
    4482             :   Py_VISIT(traverse_module_state->__pyx_kp_u__13);
    4483             :   Py_VISIT(traverse_module_state->__pyx_kp_u__2);
    4484             :   Py_VISIT(traverse_module_state->__pyx_n_s__3);
    4485             :   Py_VISIT(traverse_module_state->__pyx_n_s__34);
    4486             :   Py_VISIT(traverse_module_state->__pyx_kp_u__6);
    4487             :   Py_VISIT(traverse_module_state->__pyx_kp_u__7);
    4488             :   Py_VISIT(traverse_module_state->__pyx_n_s_a);
    4489             :   Py_VISIT(traverse_module_state->__pyx_n_s_abc);
    4490             :   Py_VISIT(traverse_module_state->__pyx_n_s_all);
    4491             :   Py_VISIT(traverse_module_state->__pyx_n_s_allocate_buffer);
    4492             :   Py_VISIT(traverse_module_state->__pyx_kp_u_and);
    4493             :   Py_VISIT(traverse_module_state->__pyx_n_s_args);
    4494             :   Py_VISIT(traverse_module_state->__pyx_n_s_asanyarray);
    4495             :   Py_VISIT(traverse_module_state->__pyx_n_s_asyncio_coroutines);
    4496             :   Py_VISIT(traverse_module_state->__pyx_n_s_base);
    4497             :   Py_VISIT(traverse_module_state->__pyx_n_s_bool);
    4498             :   Py_VISIT(traverse_module_state->__pyx_n_s_c);
    4499             :   Py_VISIT(traverse_module_state->__pyx_n_u_c);
    4500             :   Py_VISIT(traverse_module_state->__pyx_n_s_class);
    4501             :   Py_VISIT(traverse_module_state->__pyx_n_s_class_getitem);
    4502             :   Py_VISIT(traverse_module_state->__pyx_n_s_cline_in_traceback);
    4503             :   Py_VISIT(traverse_module_state->__pyx_n_s_collections);
    4504             :   Py_VISIT(traverse_module_state->__pyx_kp_s_collections_abc);
    4505             :   Py_VISIT(traverse_module_state->__pyx_kp_s_contiguous_and_direct);
    4506             :   Py_VISIT(traverse_module_state->__pyx_kp_s_contiguous_and_indirect);
    4507             :   Py_VISIT(traverse_module_state->__pyx_n_s_copy);
    4508             :   Py_VISIT(traverse_module_state->__pyx_n_s_count);
    4509             :   Py_VISIT(traverse_module_state->__pyx_n_s_defaults);
    4510             :   Py_VISIT(traverse_module_state->__pyx_n_s_dict);
    4511             :   Py_VISIT(traverse_module_state->__pyx_kp_u_disable);
    4512             :   Py_VISIT(traverse_module_state->__pyx_n_s_doc);
    4513             :   Py_VISIT(traverse_module_state->__pyx_n_s_dtype);
    4514             :   Py_VISIT(traverse_module_state->__pyx_n_s_dtype_is_object);
    4515             :   Py_VISIT(traverse_module_state->__pyx_n_s_empty);
    4516             :   Py_VISIT(traverse_module_state->__pyx_kp_u_enable);
    4517             :   Py_VISIT(traverse_module_state->__pyx_n_s_encode);
    4518             :   Py_VISIT(traverse_module_state->__pyx_n_s_enumerate);
    4519             :   Py_VISIT(traverse_module_state->__pyx_n_s_error);
    4520             :   Py_VISIT(traverse_module_state->__pyx_n_s_flags);
    4521             :   Py_VISIT(traverse_module_state->__pyx_n_s_float32_t);
    4522             :   Py_VISIT(traverse_module_state->__pyx_n_s_float64_t);
    4523             :   Py_VISIT(traverse_module_state->__pyx_n_s_format);
    4524             :   Py_VISIT(traverse_module_state->__pyx_n_s_fortran);
    4525             :   Py_VISIT(traverse_module_state->__pyx_n_u_fortran);
    4526             :   Py_VISIT(traverse_module_state->__pyx_n_s_fused_sigindex);
    4527             :   Py_VISIT(traverse_module_state->__pyx_kp_u_gc);
    4528             :   Py_VISIT(traverse_module_state->__pyx_n_s_get);
    4529             :   Py_VISIT(traverse_module_state->__pyx_n_s_get_nonzero_line);
    4530             :   Py_VISIT(traverse_module_state->__pyx_n_s_get_read_line);
    4531             :   Py_VISIT(traverse_module_state->__pyx_n_s_get_write_line);
    4532             :   Py_VISIT(traverse_module_state->__pyx_n_s_getstate);
    4533             :   Py_VISIT(traverse_module_state->__pyx_kp_u_got);
    4534             :   Py_VISIT(traverse_module_state->__pyx_kp_u_got_differing_extents_in_dimensi);
    4535             :   Py_VISIT(traverse_module_state->__pyx_kp_s_home_czgdp18079_Quansight_scipy);
    4536             :   Py_VISIT(traverse_module_state->__pyx_n_s_id);
    4537             :   Py_VISIT(traverse_module_state->__pyx_n_s_import);
    4538             :   Py_VISIT(traverse_module_state->__pyx_n_s_index);
    4539             :   Py_VISIT(traverse_module_state->__pyx_n_s_init_subclass);
    4540             :   Py_VISIT(traverse_module_state->__pyx_n_s_initializing);
    4541             :   Py_VISIT(traverse_module_state->__pyx_n_s_input);
    4542             :   Py_VISIT(traverse_module_state->__pyx_n_s_int16_t);
    4543             :   Py_VISIT(traverse_module_state->__pyx_n_s_int32_t);
    4544             :   Py_VISIT(traverse_module_state->__pyx_n_s_int64_t);
    4545             :   Py_VISIT(traverse_module_state->__pyx_n_s_int8_t);
    4546             :   Py_VISIT(traverse_module_state->__pyx_n_s_is_coroutine);
    4547             :   Py_VISIT(traverse_module_state->__pyx_kp_u_isenabled);
    4548             :   Py_VISIT(traverse_module_state->__pyx_n_s_itemsize);
    4549             :   Py_VISIT(traverse_module_state->__pyx_kp_s_itemsize_0_for_cython_array);
    4550             :   Py_VISIT(traverse_module_state->__pyx_n_s_kind);
    4551             :   Py_VISIT(traverse_module_state->__pyx_n_s_kwargs);
    4552             :   Py_VISIT(traverse_module_state->__pyx_n_s_label);
    4553             :   Py_VISIT(traverse_module_state->__pyx_n_s_main);
    4554             :   Py_VISIT(traverse_module_state->__pyx_n_s_memview);
    4555             :   Py_VISIT(traverse_module_state->__pyx_n_s_metaclass);
    4556             :   Py_VISIT(traverse_module_state->__pyx_n_s_mode);
    4557             :   Py_VISIT(traverse_module_state->__pyx_n_s_module);
    4558             :   Py_VISIT(traverse_module_state->__pyx_n_s_mro_entries);
    4559             :   Py_VISIT(traverse_module_state->__pyx_n_s_name);
    4560             :   Py_VISIT(traverse_module_state->__pyx_n_s_name_2);
    4561             :   Py_VISIT(traverse_module_state->__pyx_n_s_ndim);
    4562             :   Py_VISIT(traverse_module_state->__pyx_n_s_new);
    4563             :   Py_VISIT(traverse_module_state->__pyx_n_s_ni_label);
    4564             :   Py_VISIT(traverse_module_state->__pyx_kp_s_no_default___reduce___due_to_non);
    4565             :   Py_VISIT(traverse_module_state->__pyx_n_s_np);
    4566             :   Py_VISIT(traverse_module_state->__pyx_n_s_numpy);
    4567             :   Py_VISIT(traverse_module_state->__pyx_kp_u_numpy__core_multiarray_failed_to);
    4568             :   Py_VISIT(traverse_module_state->__pyx_kp_u_numpy__core_umath_failed_to_impo);
    4569             :   Py_VISIT(traverse_module_state->__pyx_n_s_obj);
    4570             :   Py_VISIT(traverse_module_state->__pyx_n_s_output);
    4571             :   Py_VISIT(traverse_module_state->__pyx_n_s_pack);
    4572             :   Py_VISIT(traverse_module_state->__pyx_n_s_pickle);
    4573             :   Py_VISIT(traverse_module_state->__pyx_n_s_prepare);
    4574             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_PickleError);
    4575             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_checksum);
    4576             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_result);
    4577             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_state);
    4578             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_type);
    4579             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_unpickle_Enum);
    4580             :   Py_VISIT(traverse_module_state->__pyx_n_s_pyx_vtable);
    4581             :   Py_VISIT(traverse_module_state->__pyx_n_s_qualname);
    4582             :   Py_VISIT(traverse_module_state->__pyx_n_s_range);
    4583             :   Py_VISIT(traverse_module_state->__pyx_n_s_reduce);
    4584             :   Py_VISIT(traverse_module_state->__pyx_n_s_reduce_cython);
    4585             :   Py_VISIT(traverse_module_state->__pyx_n_s_reduce_ex);
    4586             :   Py_VISIT(traverse_module_state->__pyx_n_s_register);
    4587             :   Py_VISIT(traverse_module_state->__pyx_n_s_s);
    4588             :   Py_VISIT(traverse_module_state->__pyx_n_s_set_name);
    4589             :   Py_VISIT(traverse_module_state->__pyx_n_s_setstate);
    4590             :   Py_VISIT(traverse_module_state->__pyx_n_s_setstate_cython);
    4591             :   Py_VISIT(traverse_module_state->__pyx_n_s_shape);
    4592             :   Py_VISIT(traverse_module_state->__pyx_n_s_signatures);
    4593             :   Py_VISIT(traverse_module_state->__pyx_n_s_size);
    4594             :   Py_VISIT(traverse_module_state->__pyx_n_s_spec);
    4595             :   Py_VISIT(traverse_module_state->__pyx_n_s_split);
    4596             :   Py_VISIT(traverse_module_state->__pyx_n_s_start);
    4597             :   Py_VISIT(traverse_module_state->__pyx_n_s_step);
    4598             :   Py_VISIT(traverse_module_state->__pyx_n_s_stop);
    4599             :   Py_VISIT(traverse_module_state->__pyx_kp_s_strided_and_direct);
    4600             :   Py_VISIT(traverse_module_state->__pyx_kp_s_strided_and_direct_or_indirect);
    4601             :   Py_VISIT(traverse_module_state->__pyx_kp_s_strided_and_indirect);
    4602             :   Py_VISIT(traverse_module_state->__pyx_kp_s_stringsource);
    4603             :   Py_VISIT(traverse_module_state->__pyx_n_s_strip);
    4604             :   Py_VISIT(traverse_module_state->__pyx_n_s_struct);
    4605             :   Py_VISIT(traverse_module_state->__pyx_n_s_structure);
    4606             :   Py_VISIT(traverse_module_state->__pyx_n_s_super);
    4607             :   Py_VISIT(traverse_module_state->__pyx_n_s_sys);
    4608             :   Py_VISIT(traverse_module_state->__pyx_n_s_take);
    4609             :   Py_VISIT(traverse_module_state->__pyx_n_s_test);
    4610             :   Py_VISIT(traverse_module_state->__pyx_n_s_uint16_t);
    4611             :   Py_VISIT(traverse_module_state->__pyx_n_s_uint32_t);
    4612             :   Py_VISIT(traverse_module_state->__pyx_n_s_uint64_t);
    4613             :   Py_VISIT(traverse_module_state->__pyx_n_s_uint8);
    4614             :   Py_VISIT(traverse_module_state->__pyx_n_s_uint8_t);
    4615             :   Py_VISIT(traverse_module_state->__pyx_n_s_uintp);
    4616             :   Py_VISIT(traverse_module_state->__pyx_kp_s_unable_to_allocate_array_data);
    4617             :   Py_VISIT(traverse_module_state->__pyx_kp_s_unable_to_allocate_shape_and_str);
    4618             :   Py_VISIT(traverse_module_state->__pyx_n_s_unpack);
    4619             :   Py_VISIT(traverse_module_state->__pyx_n_s_update);
    4620             :   Py_VISIT(traverse_module_state->__pyx_n_s_values);
    4621             :   Py_VISIT(traverse_module_state->__pyx_n_s_version_info);
    4622             :   Py_VISIT(traverse_module_state->__pyx_n_s_view);
    4623             :   Py_VISIT(traverse_module_state->__pyx_int_0);
    4624             :   Py_VISIT(traverse_module_state->__pyx_int_1);
    4625             :   Py_VISIT(traverse_module_state->__pyx_int_3);
    4626             :   Py_VISIT(traverse_module_state->__pyx_int_112105877);
    4627             :   Py_VISIT(traverse_module_state->__pyx_int_136983863);
    4628             :   Py_VISIT(traverse_module_state->__pyx_int_184977713);
    4629             :   Py_VISIT(traverse_module_state->__pyx_int_neg_1);
    4630             :   Py_VISIT(traverse_module_state->__pyx_slice__5);
    4631             :   Py_VISIT(traverse_module_state->__pyx_tuple__4);
    4632             :   Py_VISIT(traverse_module_state->__pyx_tuple__8);
    4633             :   Py_VISIT(traverse_module_state->__pyx_tuple__9);
    4634             :   Py_VISIT(traverse_module_state->__pyx_slice__16);
    4635             :   Py_VISIT(traverse_module_state->__pyx_tuple__10);
    4636             :   Py_VISIT(traverse_module_state->__pyx_tuple__14);
    4637             :   Py_VISIT(traverse_module_state->__pyx_tuple__15);
    4638             :   Py_VISIT(traverse_module_state->__pyx_tuple__17);
    4639             :   Py_VISIT(traverse_module_state->__pyx_tuple__18);
    4640             :   Py_VISIT(traverse_module_state->__pyx_tuple__19);
    4641             :   Py_VISIT(traverse_module_state->__pyx_tuple__20);
    4642             :   Py_VISIT(traverse_module_state->__pyx_tuple__21);
    4643             :   Py_VISIT(traverse_module_state->__pyx_tuple__22);
    4644             :   Py_VISIT(traverse_module_state->__pyx_tuple__23);
    4645             :   Py_VISIT(traverse_module_state->__pyx_tuple__24);
    4646             :   Py_VISIT(traverse_module_state->__pyx_tuple__25);
    4647             :   Py_VISIT(traverse_module_state->__pyx_tuple__26);
    4648             :   Py_VISIT(traverse_module_state->__pyx_tuple__28);
    4649             :   Py_VISIT(traverse_module_state->__pyx_tuple__32);
    4650             :   Py_VISIT(traverse_module_state->__pyx_codeobj__27);
    4651             :   Py_VISIT(traverse_module_state->__pyx_codeobj__29);
    4652             :   Py_VISIT(traverse_module_state->__pyx_codeobj__30);
    4653             :   Py_VISIT(traverse_module_state->__pyx_codeobj__31);
    4654             :   Py_VISIT(traverse_module_state->__pyx_codeobj__33);
    4655             :   return 0;
    4656             : }
    4657             : #endif
    4658             : /* #### Code section: module_state_defines ### */
    4659             : #define __pyx_d __pyx_mstate_global->__pyx_d
    4660             : #define __pyx_b __pyx_mstate_global->__pyx_b
    4661             : #define __pyx_cython_runtime __pyx_mstate_global->__pyx_cython_runtime
    4662             : #define __pyx_empty_tuple __pyx_mstate_global->__pyx_empty_tuple
    4663             : #define __pyx_empty_bytes __pyx_mstate_global->__pyx_empty_bytes
    4664             : #define __pyx_empty_unicode __pyx_mstate_global->__pyx_empty_unicode
    4665             : #ifdef __Pyx_CyFunction_USED
    4666             : #define __pyx_CyFunctionType __pyx_mstate_global->__pyx_CyFunctionType
    4667             : #endif
    4668             : #ifdef __Pyx_FusedFunction_USED
    4669             : #define __pyx_FusedFunctionType __pyx_mstate_global->__pyx_FusedFunctionType
    4670             : #endif
    4671             : #ifdef __Pyx_Generator_USED
    4672             : #define __pyx_GeneratorType __pyx_mstate_global->__pyx_GeneratorType
    4673             : #endif
    4674             : #ifdef __Pyx_IterableCoroutine_USED
    4675             : #define __pyx_IterableCoroutineType __pyx_mstate_global->__pyx_IterableCoroutineType
    4676             : #endif
    4677             : #ifdef __Pyx_Coroutine_USED
    4678             : #define __pyx_CoroutineAwaitType __pyx_mstate_global->__pyx_CoroutineAwaitType
    4679             : #endif
    4680             : #ifdef __Pyx_Coroutine_USED
    4681             : #define __pyx_CoroutineType __pyx_mstate_global->__pyx_CoroutineType
    4682             : #endif
    4683             : #if CYTHON_USE_MODULE_STATE
    4684             : #endif
    4685             : #if CYTHON_USE_MODULE_STATE
    4686             : #endif
    4687             : #if CYTHON_USE_MODULE_STATE
    4688             : #endif
    4689             : #if CYTHON_USE_MODULE_STATE
    4690             : #endif
    4691             : #define __pyx_ptype_7cpython_4type_type __pyx_mstate_global->__pyx_ptype_7cpython_4type_type
    4692             : #if CYTHON_USE_MODULE_STATE
    4693             : #endif
    4694             : #if CYTHON_USE_MODULE_STATE
    4695             : #endif
    4696             : #if CYTHON_USE_MODULE_STATE
    4697             : #endif
    4698             : #if CYTHON_USE_MODULE_STATE
    4699             : #endif
    4700             : #if CYTHON_USE_MODULE_STATE
    4701             : #endif
    4702             : #define __pyx_ptype_5numpy_dtype __pyx_mstate_global->__pyx_ptype_5numpy_dtype
    4703             : #define __pyx_ptype_5numpy_flatiter __pyx_mstate_global->__pyx_ptype_5numpy_flatiter
    4704             : #define __pyx_ptype_5numpy_broadcast __pyx_mstate_global->__pyx_ptype_5numpy_broadcast
    4705             : #define __pyx_ptype_5numpy_ndarray __pyx_mstate_global->__pyx_ptype_5numpy_ndarray
    4706             : #define __pyx_ptype_5numpy_generic __pyx_mstate_global->__pyx_ptype_5numpy_generic
    4707             : #define __pyx_ptype_5numpy_number __pyx_mstate_global->__pyx_ptype_5numpy_number
    4708             : #define __pyx_ptype_5numpy_integer __pyx_mstate_global->__pyx_ptype_5numpy_integer
    4709             : #define __pyx_ptype_5numpy_signedinteger __pyx_mstate_global->__pyx_ptype_5numpy_signedinteger
    4710             : #define __pyx_ptype_5numpy_unsignedinteger __pyx_mstate_global->__pyx_ptype_5numpy_unsignedinteger
    4711             : #define __pyx_ptype_5numpy_inexact __pyx_mstate_global->__pyx_ptype_5numpy_inexact
    4712             : #define __pyx_ptype_5numpy_floating __pyx_mstate_global->__pyx_ptype_5numpy_floating
    4713             : #define __pyx_ptype_5numpy_complexfloating __pyx_mstate_global->__pyx_ptype_5numpy_complexfloating
    4714             : #define __pyx_ptype_5numpy_flexible __pyx_mstate_global->__pyx_ptype_5numpy_flexible
    4715             : #define __pyx_ptype_5numpy_character __pyx_mstate_global->__pyx_ptype_5numpy_character
    4716             : #define __pyx_ptype_5numpy_ufunc __pyx_mstate_global->__pyx_ptype_5numpy_ufunc
    4717             : #if CYTHON_USE_MODULE_STATE
    4718             : #define __pyx_type___pyx_array __pyx_mstate_global->__pyx_type___pyx_array
    4719             : #define __pyx_type___pyx_MemviewEnum __pyx_mstate_global->__pyx_type___pyx_MemviewEnum
    4720             : #define __pyx_type___pyx_memoryview __pyx_mstate_global->__pyx_type___pyx_memoryview
    4721             : #define __pyx_type___pyx_memoryviewslice __pyx_mstate_global->__pyx_type___pyx_memoryviewslice
    4722             : #endif
    4723             : #define __pyx_array_type __pyx_mstate_global->__pyx_array_type
    4724             : #define __pyx_MemviewEnum_type __pyx_mstate_global->__pyx_MemviewEnum_type
    4725             : #define __pyx_memoryview_type __pyx_mstate_global->__pyx_memoryview_type
    4726             : #define __pyx_memoryviewslice_type __pyx_mstate_global->__pyx_memoryviewslice_type
    4727             : #define __pyx_kp_u_ __pyx_mstate_global->__pyx_kp_u_
    4728             : #define __pyx_n_s_ASCII __pyx_mstate_global->__pyx_n_s_ASCII
    4729             : #define __pyx_kp_s_All_dimensions_preceding_dimensi __pyx_mstate_global->__pyx_kp_s_All_dimensions_preceding_dimensi
    4730             : #define __pyx_n_s_AssertionError __pyx_mstate_global->__pyx_n_s_AssertionError
    4731             : #define __pyx_kp_s_Buffer_view_does_not_expose_stri __pyx_mstate_global->__pyx_kp_s_Buffer_view_does_not_expose_stri
    4732             : #define __pyx_kp_s_Can_only_create_a_buffer_that_is __pyx_mstate_global->__pyx_kp_s_Can_only_create_a_buffer_that_is
    4733             : #define __pyx_kp_s_Cannot_assign_to_read_only_memor __pyx_mstate_global->__pyx_kp_s_Cannot_assign_to_read_only_memor
    4734             : #define __pyx_kp_s_Cannot_create_writable_memory_vi __pyx_mstate_global->__pyx_kp_s_Cannot_create_writable_memory_vi
    4735             : #define __pyx_kp_u_Cannot_index_with_type __pyx_mstate_global->__pyx_kp_u_Cannot_index_with_type
    4736             : #define __pyx_kp_u_Cannot_label_scalars_or_empty_ar __pyx_mstate_global->__pyx_kp_u_Cannot_label_scalars_or_empty_ar
    4737             : #define __pyx_kp_s_Cannot_transpose_memoryview_with __pyx_mstate_global->__pyx_kp_s_Cannot_transpose_memoryview_with
    4738             : #define __pyx_kp_s_Dimension_d_is_not_direct __pyx_mstate_global->__pyx_kp_s_Dimension_d_is_not_direct
    4739             : #define __pyx_n_s_Ellipsis __pyx_mstate_global->__pyx_n_s_Ellipsis
    4740             : #define __pyx_kp_s_Empty_shape_tuple_for_cython_arr __pyx_mstate_global->__pyx_kp_s_Empty_shape_tuple_for_cython_arr
    4741             : #define __pyx_kp_s_Expected_at_least_d_argument_s_g __pyx_mstate_global->__pyx_kp_s_Expected_at_least_d_argument_s_g
    4742             : #define __pyx_kp_s_Function_call_with_ambiguous_arg __pyx_mstate_global->__pyx_kp_s_Function_call_with_ambiguous_arg
    4743             : #define __pyx_n_s_ImportError __pyx_mstate_global->__pyx_n_s_ImportError
    4744             : #define __pyx_kp_s_Incompatible_checksums_0x_x_vs_0 __pyx_mstate_global->__pyx_kp_s_Incompatible_checksums_0x_x_vs_0
    4745             : #define __pyx_n_s_IndexError __pyx_mstate_global->__pyx_n_s_IndexError
    4746             : #define __pyx_kp_s_Index_out_of_bounds_axis_d __pyx_mstate_global->__pyx_kp_s_Index_out_of_bounds_axis_d
    4747             : #define __pyx_kp_s_Indirect_dimensions_not_supporte __pyx_mstate_global->__pyx_kp_s_Indirect_dimensions_not_supporte
    4748             : #define __pyx_kp_u_Invalid_mode_expected_c_or_fortr __pyx_mstate_global->__pyx_kp_u_Invalid_mode_expected_c_or_fortr
    4749             : #define __pyx_kp_u_Invalid_shape_in_axis __pyx_mstate_global->__pyx_kp_u_Invalid_shape_in_axis
    4750             : #define __pyx_n_s_MemoryError __pyx_mstate_global->__pyx_n_s_MemoryError
    4751             : #define __pyx_kp_s_MemoryView_of_r_at_0x_x __pyx_mstate_global->__pyx_kp_s_MemoryView_of_r_at_0x_x
    4752             : #define __pyx_kp_s_MemoryView_of_r_object __pyx_mstate_global->__pyx_kp_s_MemoryView_of_r_object
    4753             : #define __pyx_n_s_NeedMoreBits __pyx_mstate_global->__pyx_n_s_NeedMoreBits
    4754             : #define __pyx_kp_s_No_matching_signature_found __pyx_mstate_global->__pyx_kp_s_No_matching_signature_found
    4755             : #define __pyx_n_b_O __pyx_mstate_global->__pyx_n_b_O
    4756             : #define __pyx_kp_u_Out_of_bounds_on_buffer_access_a __pyx_mstate_global->__pyx_kp_u_Out_of_bounds_on_buffer_access_a
    4757             : #define __pyx_n_s_PickleError __pyx_mstate_global->__pyx_n_s_PickleError
    4758             : #define __pyx_n_s_Sequence __pyx_mstate_global->__pyx_n_s_Sequence
    4759             : #define __pyx_kp_u_Shapes_must_match_for_input_and __pyx_mstate_global->__pyx_kp_u_Shapes_must_match_for_input_and
    4760             : #define __pyx_kp_s_Step_may_not_be_zero_axis_d __pyx_mstate_global->__pyx_kp_s_Step_may_not_be_zero_axis_d
    4761             : #define __pyx_kp_u_Structuring_element_is_not_symme __pyx_mstate_global->__pyx_kp_u_Structuring_element_is_not_symme
    4762             : #define __pyx_kp_u_Structuring_element_must_be_size __pyx_mstate_global->__pyx_kp_u_Structuring_element_must_be_size
    4763             : #define __pyx_kp_u_Structuring_element_must_have_sa __pyx_mstate_global->__pyx_kp_u_Structuring_element_must_have_sa
    4764             : #define __pyx_n_s_TypeError __pyx_mstate_global->__pyx_n_s_TypeError
    4765             : #define __pyx_kp_s_Unable_to_convert_item_to_object __pyx_mstate_global->__pyx_kp_s_Unable_to_convert_item_to_object
    4766             : #define __pyx_n_s_ValueError __pyx_mstate_global->__pyx_n_s_ValueError
    4767             : #define __pyx_n_s_View_MemoryView __pyx_mstate_global->__pyx_n_s_View_MemoryView
    4768             : #define __pyx_kp_s__11 __pyx_mstate_global->__pyx_kp_s__11
    4769             : #define __pyx_kp_s__12 __pyx_mstate_global->__pyx_kp_s__12
    4770             : #define __pyx_kp_s__13 __pyx_mstate_global->__pyx_kp_s__13
    4771             : #define __pyx_kp_u__13 __pyx_mstate_global->__pyx_kp_u__13
    4772             : #define __pyx_kp_u__2 __pyx_mstate_global->__pyx_kp_u__2
    4773             : #define __pyx_n_s__3 __pyx_mstate_global->__pyx_n_s__3
    4774             : #define __pyx_n_s__34 __pyx_mstate_global->__pyx_n_s__34
    4775             : #define __pyx_kp_u__6 __pyx_mstate_global->__pyx_kp_u__6
    4776             : #define __pyx_kp_u__7 __pyx_mstate_global->__pyx_kp_u__7
    4777             : #define __pyx_n_s_a __pyx_mstate_global->__pyx_n_s_a
    4778             : #define __pyx_n_s_abc __pyx_mstate_global->__pyx_n_s_abc
    4779             : #define __pyx_n_s_all __pyx_mstate_global->__pyx_n_s_all
    4780             : #define __pyx_n_s_allocate_buffer __pyx_mstate_global->__pyx_n_s_allocate_buffer
    4781             : #define __pyx_kp_u_and __pyx_mstate_global->__pyx_kp_u_and
    4782             : #define __pyx_n_s_args __pyx_mstate_global->__pyx_n_s_args
    4783             : #define __pyx_n_s_asanyarray __pyx_mstate_global->__pyx_n_s_asanyarray
    4784             : #define __pyx_n_s_asyncio_coroutines __pyx_mstate_global->__pyx_n_s_asyncio_coroutines
    4785             : #define __pyx_n_s_base __pyx_mstate_global->__pyx_n_s_base
    4786             : #define __pyx_n_s_bool __pyx_mstate_global->__pyx_n_s_bool
    4787             : #define __pyx_n_s_c __pyx_mstate_global->__pyx_n_s_c
    4788             : #define __pyx_n_u_c __pyx_mstate_global->__pyx_n_u_c
    4789             : #define __pyx_n_s_class __pyx_mstate_global->__pyx_n_s_class
    4790             : #define __pyx_n_s_class_getitem __pyx_mstate_global->__pyx_n_s_class_getitem
    4791             : #define __pyx_n_s_cline_in_traceback __pyx_mstate_global->__pyx_n_s_cline_in_traceback
    4792             : #define __pyx_n_s_collections __pyx_mstate_global->__pyx_n_s_collections
    4793             : #define __pyx_kp_s_collections_abc __pyx_mstate_global->__pyx_kp_s_collections_abc
    4794             : #define __pyx_kp_s_contiguous_and_direct __pyx_mstate_global->__pyx_kp_s_contiguous_and_direct
    4795             : #define __pyx_kp_s_contiguous_and_indirect __pyx_mstate_global->__pyx_kp_s_contiguous_and_indirect
    4796             : #define __pyx_n_s_copy __pyx_mstate_global->__pyx_n_s_copy
    4797             : #define __pyx_n_s_count __pyx_mstate_global->__pyx_n_s_count
    4798             : #define __pyx_n_s_defaults __pyx_mstate_global->__pyx_n_s_defaults
    4799             : #define __pyx_n_s_dict __pyx_mstate_global->__pyx_n_s_dict
    4800             : #define __pyx_kp_u_disable __pyx_mstate_global->__pyx_kp_u_disable
    4801             : #define __pyx_n_s_doc __pyx_mstate_global->__pyx_n_s_doc
    4802             : #define __pyx_n_s_dtype __pyx_mstate_global->__pyx_n_s_dtype
    4803             : #define __pyx_n_s_dtype_is_object __pyx_mstate_global->__pyx_n_s_dtype_is_object
    4804             : #define __pyx_n_s_empty __pyx_mstate_global->__pyx_n_s_empty
    4805             : #define __pyx_kp_u_enable __pyx_mstate_global->__pyx_kp_u_enable
    4806             : #define __pyx_n_s_encode __pyx_mstate_global->__pyx_n_s_encode
    4807             : #define __pyx_n_s_enumerate __pyx_mstate_global->__pyx_n_s_enumerate
    4808             : #define __pyx_n_s_error __pyx_mstate_global->__pyx_n_s_error
    4809             : #define __pyx_n_s_flags __pyx_mstate_global->__pyx_n_s_flags
    4810             : #define __pyx_n_s_float32_t __pyx_mstate_global->__pyx_n_s_float32_t
    4811             : #define __pyx_n_s_float64_t __pyx_mstate_global->__pyx_n_s_float64_t
    4812             : #define __pyx_n_s_format __pyx_mstate_global->__pyx_n_s_format
    4813             : #define __pyx_n_s_fortran __pyx_mstate_global->__pyx_n_s_fortran
    4814             : #define __pyx_n_u_fortran __pyx_mstate_global->__pyx_n_u_fortran
    4815             : #define __pyx_n_s_fused_sigindex __pyx_mstate_global->__pyx_n_s_fused_sigindex
    4816             : #define __pyx_kp_u_gc __pyx_mstate_global->__pyx_kp_u_gc
    4817             : #define __pyx_n_s_get __pyx_mstate_global->__pyx_n_s_get
    4818             : #define __pyx_n_s_get_nonzero_line __pyx_mstate_global->__pyx_n_s_get_nonzero_line
    4819             : #define __pyx_n_s_get_read_line __pyx_mstate_global->__pyx_n_s_get_read_line
    4820             : #define __pyx_n_s_get_write_line __pyx_mstate_global->__pyx_n_s_get_write_line
    4821             : #define __pyx_n_s_getstate __pyx_mstate_global->__pyx_n_s_getstate
    4822             : #define __pyx_kp_u_got __pyx_mstate_global->__pyx_kp_u_got
    4823             : #define __pyx_kp_u_got_differing_extents_in_dimensi __pyx_mstate_global->__pyx_kp_u_got_differing_extents_in_dimensi
    4824             : #define __pyx_kp_s_home_czgdp18079_Quansight_scipy __pyx_mstate_global->__pyx_kp_s_home_czgdp18079_Quansight_scipy
    4825             : #define __pyx_n_s_id __pyx_mstate_global->__pyx_n_s_id
    4826             : #define __pyx_n_s_import __pyx_mstate_global->__pyx_n_s_import
    4827             : #define __pyx_n_s_index __pyx_mstate_global->__pyx_n_s_index
    4828             : #define __pyx_n_s_init_subclass __pyx_mstate_global->__pyx_n_s_init_subclass
    4829             : #define __pyx_n_s_initializing __pyx_mstate_global->__pyx_n_s_initializing
    4830             : #define __pyx_n_s_input __pyx_mstate_global->__pyx_n_s_input
    4831             : #define __pyx_n_s_int16_t __pyx_mstate_global->__pyx_n_s_int16_t
    4832             : #define __pyx_n_s_int32_t __pyx_mstate_global->__pyx_n_s_int32_t
    4833             : #define __pyx_n_s_int64_t __pyx_mstate_global->__pyx_n_s_int64_t
    4834             : #define __pyx_n_s_int8_t __pyx_mstate_global->__pyx_n_s_int8_t
    4835             : #define __pyx_n_s_is_coroutine __pyx_mstate_global->__pyx_n_s_is_coroutine
    4836             : #define __pyx_kp_u_isenabled __pyx_mstate_global->__pyx_kp_u_isenabled
    4837             : #define __pyx_n_s_itemsize __pyx_mstate_global->__pyx_n_s_itemsize
    4838             : #define __pyx_kp_s_itemsize_0_for_cython_array __pyx_mstate_global->__pyx_kp_s_itemsize_0_for_cython_array
    4839             : #define __pyx_n_s_kind __pyx_mstate_global->__pyx_n_s_kind
    4840             : #define __pyx_n_s_kwargs __pyx_mstate_global->__pyx_n_s_kwargs
    4841             : #define __pyx_n_s_label __pyx_mstate_global->__pyx_n_s_label
    4842             : #define __pyx_n_s_main __pyx_mstate_global->__pyx_n_s_main
    4843             : #define __pyx_n_s_memview __pyx_mstate_global->__pyx_n_s_memview
    4844             : #define __pyx_n_s_metaclass __pyx_mstate_global->__pyx_n_s_metaclass
    4845             : #define __pyx_n_s_mode __pyx_mstate_global->__pyx_n_s_mode
    4846             : #define __pyx_n_s_module __pyx_mstate_global->__pyx_n_s_module
    4847             : #define __pyx_n_s_mro_entries __pyx_mstate_global->__pyx_n_s_mro_entries
    4848             : #define __pyx_n_s_name __pyx_mstate_global->__pyx_n_s_name
    4849             : #define __pyx_n_s_name_2 __pyx_mstate_global->__pyx_n_s_name_2
    4850             : #define __pyx_n_s_ndim __pyx_mstate_global->__pyx_n_s_ndim
    4851             : #define __pyx_n_s_new __pyx_mstate_global->__pyx_n_s_new
    4852             : #define __pyx_n_s_ni_label __pyx_mstate_global->__pyx_n_s_ni_label
    4853             : #define __pyx_kp_s_no_default___reduce___due_to_non __pyx_mstate_global->__pyx_kp_s_no_default___reduce___due_to_non
    4854             : #define __pyx_n_s_np __pyx_mstate_global->__pyx_n_s_np
    4855             : #define __pyx_n_s_numpy __pyx_mstate_global->__pyx_n_s_numpy
    4856             : #define __pyx_kp_u_numpy__core_multiarray_failed_to __pyx_mstate_global->__pyx_kp_u_numpy__core_multiarray_failed_to
    4857             : #define __pyx_kp_u_numpy__core_umath_failed_to_impo __pyx_mstate_global->__pyx_kp_u_numpy__core_umath_failed_to_impo
    4858             : #define __pyx_n_s_obj __pyx_mstate_global->__pyx_n_s_obj
    4859             : #define __pyx_n_s_output __pyx_mstate_global->__pyx_n_s_output
    4860             : #define __pyx_n_s_pack __pyx_mstate_global->__pyx_n_s_pack
    4861             : #define __pyx_n_s_pickle __pyx_mstate_global->__pyx_n_s_pickle
    4862             : #define __pyx_n_s_prepare __pyx_mstate_global->__pyx_n_s_prepare
    4863             : #define __pyx_n_s_pyx_PickleError __pyx_mstate_global->__pyx_n_s_pyx_PickleError
    4864             : #define __pyx_n_s_pyx_checksum __pyx_mstate_global->__pyx_n_s_pyx_checksum
    4865             : #define __pyx_n_s_pyx_result __pyx_mstate_global->__pyx_n_s_pyx_result
    4866             : #define __pyx_n_s_pyx_state __pyx_mstate_global->__pyx_n_s_pyx_state
    4867             : #define __pyx_n_s_pyx_type __pyx_mstate_global->__pyx_n_s_pyx_type
    4868             : #define __pyx_n_s_pyx_unpickle_Enum __pyx_mstate_global->__pyx_n_s_pyx_unpickle_Enum
    4869             : #define __pyx_n_s_pyx_vtable __pyx_mstate_global->__pyx_n_s_pyx_vtable
    4870             : #define __pyx_n_s_qualname __pyx_mstate_global->__pyx_n_s_qualname
    4871             : #define __pyx_n_s_range __pyx_mstate_global->__pyx_n_s_range
    4872             : #define __pyx_n_s_reduce __pyx_mstate_global->__pyx_n_s_reduce
    4873             : #define __pyx_n_s_reduce_cython __pyx_mstate_global->__pyx_n_s_reduce_cython
    4874             : #define __pyx_n_s_reduce_ex __pyx_mstate_global->__pyx_n_s_reduce_ex
    4875             : #define __pyx_n_s_register __pyx_mstate_global->__pyx_n_s_register
    4876             : #define __pyx_n_s_s __pyx_mstate_global->__pyx_n_s_s
    4877             : #define __pyx_n_s_set_name __pyx_mstate_global->__pyx_n_s_set_name
    4878             : #define __pyx_n_s_setstate __pyx_mstate_global->__pyx_n_s_setstate
    4879             : #define __pyx_n_s_setstate_cython __pyx_mstate_global->__pyx_n_s_setstate_cython
    4880             : #define __pyx_n_s_shape __pyx_mstate_global->__pyx_n_s_shape
    4881             : #define __pyx_n_s_signatures __pyx_mstate_global->__pyx_n_s_signatures
    4882             : #define __pyx_n_s_size __pyx_mstate_global->__pyx_n_s_size
    4883             : #define __pyx_n_s_spec __pyx_mstate_global->__pyx_n_s_spec
    4884             : #define __pyx_n_s_split __pyx_mstate_global->__pyx_n_s_split
    4885             : #define __pyx_n_s_start __pyx_mstate_global->__pyx_n_s_start
    4886             : #define __pyx_n_s_step __pyx_mstate_global->__pyx_n_s_step
    4887             : #define __pyx_n_s_stop __pyx_mstate_global->__pyx_n_s_stop
    4888             : #define __pyx_kp_s_strided_and_direct __pyx_mstate_global->__pyx_kp_s_strided_and_direct
    4889             : #define __pyx_kp_s_strided_and_direct_or_indirect __pyx_mstate_global->__pyx_kp_s_strided_and_direct_or_indirect
    4890             : #define __pyx_kp_s_strided_and_indirect __pyx_mstate_global->__pyx_kp_s_strided_and_indirect
    4891             : #define __pyx_kp_s_stringsource __pyx_mstate_global->__pyx_kp_s_stringsource
    4892             : #define __pyx_n_s_strip __pyx_mstate_global->__pyx_n_s_strip
    4893             : #define __pyx_n_s_struct __pyx_mstate_global->__pyx_n_s_struct
    4894             : #define __pyx_n_s_structure __pyx_mstate_global->__pyx_n_s_structure
    4895             : #define __pyx_n_s_super __pyx_mstate_global->__pyx_n_s_super
    4896             : #define __pyx_n_s_sys __pyx_mstate_global->__pyx_n_s_sys
    4897             : #define __pyx_n_s_take __pyx_mstate_global->__pyx_n_s_take
    4898             : #define __pyx_n_s_test __pyx_mstate_global->__pyx_n_s_test
    4899             : #define __pyx_n_s_uint16_t __pyx_mstate_global->__pyx_n_s_uint16_t
    4900             : #define __pyx_n_s_uint32_t __pyx_mstate_global->__pyx_n_s_uint32_t
    4901             : #define __pyx_n_s_uint64_t __pyx_mstate_global->__pyx_n_s_uint64_t
    4902             : #define __pyx_n_s_uint8 __pyx_mstate_global->__pyx_n_s_uint8
    4903             : #define __pyx_n_s_uint8_t __pyx_mstate_global->__pyx_n_s_uint8_t
    4904             : #define __pyx_n_s_uintp __pyx_mstate_global->__pyx_n_s_uintp
    4905             : #define __pyx_kp_s_unable_to_allocate_array_data __pyx_mstate_global->__pyx_kp_s_unable_to_allocate_array_data
    4906             : #define __pyx_kp_s_unable_to_allocate_shape_and_str __pyx_mstate_global->__pyx_kp_s_unable_to_allocate_shape_and_str
    4907             : #define __pyx_n_s_unpack __pyx_mstate_global->__pyx_n_s_unpack
    4908             : #define __pyx_n_s_update __pyx_mstate_global->__pyx_n_s_update
    4909             : #define __pyx_n_s_values __pyx_mstate_global->__pyx_n_s_values
    4910             : #define __pyx_n_s_version_info __pyx_mstate_global->__pyx_n_s_version_info
    4911             : #define __pyx_n_s_view __pyx_mstate_global->__pyx_n_s_view
    4912             : #define __pyx_int_0 __pyx_mstate_global->__pyx_int_0
    4913             : #define __pyx_int_1 __pyx_mstate_global->__pyx_int_1
    4914             : #define __pyx_int_3 __pyx_mstate_global->__pyx_int_3
    4915             : #define __pyx_int_112105877 __pyx_mstate_global->__pyx_int_112105877
    4916             : #define __pyx_int_136983863 __pyx_mstate_global->__pyx_int_136983863
    4917             : #define __pyx_int_184977713 __pyx_mstate_global->__pyx_int_184977713
    4918             : #define __pyx_int_neg_1 __pyx_mstate_global->__pyx_int_neg_1
    4919             : #define __pyx_slice__5 __pyx_mstate_global->__pyx_slice__5
    4920             : #define __pyx_tuple__4 __pyx_mstate_global->__pyx_tuple__4
    4921             : #define __pyx_tuple__8 __pyx_mstate_global->__pyx_tuple__8
    4922             : #define __pyx_tuple__9 __pyx_mstate_global->__pyx_tuple__9
    4923             : #define __pyx_slice__16 __pyx_mstate_global->__pyx_slice__16
    4924             : #define __pyx_tuple__10 __pyx_mstate_global->__pyx_tuple__10
    4925             : #define __pyx_tuple__14 __pyx_mstate_global->__pyx_tuple__14
    4926             : #define __pyx_tuple__15 __pyx_mstate_global->__pyx_tuple__15
    4927             : #define __pyx_tuple__17 __pyx_mstate_global->__pyx_tuple__17
    4928             : #define __pyx_tuple__18 __pyx_mstate_global->__pyx_tuple__18
    4929             : #define __pyx_tuple__19 __pyx_mstate_global->__pyx_tuple__19
    4930             : #define __pyx_tuple__20 __pyx_mstate_global->__pyx_tuple__20
    4931             : #define __pyx_tuple__21 __pyx_mstate_global->__pyx_tuple__21
    4932             : #define __pyx_tuple__22 __pyx_mstate_global->__pyx_tuple__22
    4933             : #define __pyx_tuple__23 __pyx_mstate_global->__pyx_tuple__23
    4934             : #define __pyx_tuple__24 __pyx_mstate_global->__pyx_tuple__24
    4935             : #define __pyx_tuple__25 __pyx_mstate_global->__pyx_tuple__25
    4936             : #define __pyx_tuple__26 __pyx_mstate_global->__pyx_tuple__26
    4937             : #define __pyx_tuple__28 __pyx_mstate_global->__pyx_tuple__28
    4938             : #define __pyx_tuple__32 __pyx_mstate_global->__pyx_tuple__32
    4939             : #define __pyx_codeobj__27 __pyx_mstate_global->__pyx_codeobj__27
    4940             : #define __pyx_codeobj__29 __pyx_mstate_global->__pyx_codeobj__29
    4941             : #define __pyx_codeobj__30 __pyx_mstate_global->__pyx_codeobj__30
    4942             : #define __pyx_codeobj__31 __pyx_mstate_global->__pyx_codeobj__31
    4943             : #define __pyx_codeobj__33 __pyx_mstate_global->__pyx_codeobj__33
    4944             : /* #### Code section: module_code ### */
    4945             : 
    4946             : /* "View.MemoryView":131
    4947             :  *         cdef bint dtype_is_object
    4948             :  * 
    4949             :  *     def __cinit__(array self, tuple shape, Py_ssize_t itemsize, format not None,             # <<<<<<<<<<<<<<
    4950             :  *                   mode="c", bint allocate_buffer=True):
    4951             :  * 
    4952             :  */
    4953             : 
    4954             : /* Python wrapper */
    4955             : static int __pyx_array___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
    4956           0 : static int __pyx_array___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
    4957           0 :   PyObject *__pyx_v_shape = 0;
    4958           0 :   Py_ssize_t __pyx_v_itemsize;
    4959           0 :   PyObject *__pyx_v_format = 0;
    4960           0 :   PyObject *__pyx_v_mode = 0;
    4961           0 :   int __pyx_v_allocate_buffer;
    4962           0 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    4963           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    4964           0 :   PyObject* values[5] = {0,0,0,0,0};
    4965           0 :   int __pyx_lineno = 0;
    4966           0 :   const char *__pyx_filename = NULL;
    4967           0 :   int __pyx_clineno = 0;
    4968           0 :   int __pyx_r;
    4969             :   __Pyx_RefNannyDeclarations
    4970           0 :   __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0);
    4971             :   #if CYTHON_ASSUME_SAFE_MACROS
    4972           0 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    4973             :   #else
    4974             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return -1;
    4975             :   #endif
    4976           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    4977             :   {
    4978           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_shape,&__pyx_n_s_itemsize,&__pyx_n_s_format,&__pyx_n_s_mode,&__pyx_n_s_allocate_buffer,0};
    4979           0 :     values[3] = __Pyx_Arg_NewRef_VARARGS(((PyObject *)__pyx_n_s_c));
    4980           0 :     if (__pyx_kwds) {
    4981           0 :       Py_ssize_t kw_args;
    4982           0 :       switch (__pyx_nargs) {
    4983           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
    4984           0 :         CYTHON_FALLTHROUGH;
    4985           0 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
    4986           0 :         CYTHON_FALLTHROUGH;
    4987           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
    4988           0 :         CYTHON_FALLTHROUGH;
    4989           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
    4990           0 :         CYTHON_FALLTHROUGH;
    4991           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    4992           0 :         CYTHON_FALLTHROUGH;
    4993           0 :         case  0: break;
    4994           0 :         default: goto __pyx_L5_argtuple_error;
    4995             :       }
    4996           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
    4997           0 :       switch (__pyx_nargs) {
    4998           0 :         case  0:
    4999           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_shape)) != 0)) {
    5000           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
    5001           0 :           kw_args--;
    5002             :         }
    5003           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5004           0 :         else goto __pyx_L5_argtuple_error;
    5005           0 :         CYTHON_FALLTHROUGH;
    5006             :         case  1:
    5007           0 :         if (likely((values[1] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_itemsize)) != 0)) {
    5008           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[1]);
    5009           0 :           kw_args--;
    5010             :         }
    5011           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5012             :         else {
    5013           0 :           __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 3, 5, 1); __PYX_ERR(1, 131, __pyx_L3_error)
    5014             :         }
    5015           0 :         CYTHON_FALLTHROUGH;
    5016             :         case  2:
    5017           0 :         if (likely((values[2] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_format)) != 0)) {
    5018           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[2]);
    5019           0 :           kw_args--;
    5020             :         }
    5021           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5022             :         else {
    5023           0 :           __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 3, 5, 2); __PYX_ERR(1, 131, __pyx_L3_error)
    5024             :         }
    5025           0 :         CYTHON_FALLTHROUGH;
    5026             :         case  3:
    5027           0 :         if (kw_args > 0) {
    5028           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_mode);
    5029           0 :           if (value) { values[3] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
    5030           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5031             :         }
    5032           0 :         CYTHON_FALLTHROUGH;
    5033             :         case  4:
    5034           0 :         if (kw_args > 0) {
    5035           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_allocate_buffer);
    5036           0 :           if (value) { values[4] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
    5037           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5038             :         }
    5039             :       }
    5040           0 :       if (unlikely(kw_args > 0)) {
    5041           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
    5042           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__cinit__") < 0)) __PYX_ERR(1, 131, __pyx_L3_error)
    5043             :       }
    5044             :     } else {
    5045           0 :       switch (__pyx_nargs) {
    5046           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
    5047           0 :         CYTHON_FALLTHROUGH;
    5048           0 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
    5049           0 :         CYTHON_FALLTHROUGH;
    5050           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
    5051           0 :         values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
    5052           0 :         values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    5053           0 :         break;
    5054           0 :         default: goto __pyx_L5_argtuple_error;
    5055             :       }
    5056             :     }
    5057           0 :     __pyx_v_shape = ((PyObject*)values[0]);
    5058           0 :     __pyx_v_itemsize = __Pyx_PyIndex_AsSsize_t(values[1]); if (unlikely((__pyx_v_itemsize == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 131, __pyx_L3_error)
    5059           0 :     __pyx_v_format = values[2];
    5060           0 :     __pyx_v_mode = values[3];
    5061           0 :     if (values[4]) {
    5062           0 :       __pyx_v_allocate_buffer = __Pyx_PyObject_IsTrue(values[4]); if (unlikely((__pyx_v_allocate_buffer == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 132, __pyx_L3_error)
    5063             :     } else {
    5064             : 
    5065             :       /* "View.MemoryView":132
    5066             :  * 
    5067             :  *     def __cinit__(array self, tuple shape, Py_ssize_t itemsize, format not None,
    5068             :  *                   mode="c", bint allocate_buffer=True):             # <<<<<<<<<<<<<<
    5069             :  * 
    5070             :  *         cdef int idx
    5071             :  */
    5072             :       __pyx_v_allocate_buffer = ((int)1);
    5073             :     }
    5074             :   }
    5075           0 :   goto __pyx_L6_skip;
    5076           0 :   __pyx_L5_argtuple_error:;
    5077           0 :   __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 3, 5, __pyx_nargs); __PYX_ERR(1, 131, __pyx_L3_error)
    5078           0 :   __pyx_L6_skip:;
    5079           0 :   goto __pyx_L4_argument_unpacking_done;
    5080           0 :   __pyx_L3_error:;
    5081             :   {
    5082           0 :     Py_ssize_t __pyx_temp;
    5083           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    5084             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    5085             :     }
    5086             :   }
    5087           0 :   __Pyx_AddTraceback("View.MemoryView.array.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    5088           0 :   __Pyx_RefNannyFinishContext();
    5089           0 :   return -1;
    5090           0 :   __pyx_L4_argument_unpacking_done:;
    5091           0 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shape), (&PyTuple_Type), 1, "shape", 1))) __PYX_ERR(1, 131, __pyx_L1_error)
    5092           0 :   if (unlikely(((PyObject *)__pyx_v_format) == Py_None)) {
    5093           0 :     PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "format"); __PYX_ERR(1, 131, __pyx_L1_error)
    5094             :   }
    5095           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(((struct __pyx_array_obj *)__pyx_v_self), __pyx_v_shape, __pyx_v_itemsize, __pyx_v_format, __pyx_v_mode, __pyx_v_allocate_buffer);
    5096             : 
    5097             :   /* "View.MemoryView":131
    5098             :  *         cdef bint dtype_is_object
    5099             :  * 
    5100             :  *     def __cinit__(array self, tuple shape, Py_ssize_t itemsize, format not None,             # <<<<<<<<<<<<<<
    5101             :  *                   mode="c", bint allocate_buffer=True):
    5102             :  * 
    5103             :  */
    5104             : 
    5105             :   /* function exit code */
    5106           0 :   goto __pyx_L0;
    5107             :   __pyx_L1_error:;
    5108             :   __pyx_r = -1;
    5109           0 :   __pyx_L0:;
    5110             :   {
    5111           0 :     Py_ssize_t __pyx_temp;
    5112           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    5113             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    5114             :     }
    5115             :   }
    5116             :   __Pyx_RefNannyFinishContext();
    5117             :   return __pyx_r;
    5118             : }
    5119             : 
    5120           0 : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize, PyObject *__pyx_v_format, PyObject *__pyx_v_mode, int __pyx_v_allocate_buffer) {
    5121           0 :   int __pyx_v_idx;
    5122           0 :   Py_ssize_t __pyx_v_dim;
    5123           0 :   char __pyx_v_order;
    5124           0 :   int __pyx_r;
    5125             :   __Pyx_RefNannyDeclarations
    5126           0 :   Py_ssize_t __pyx_t_1;
    5127           0 :   int __pyx_t_2;
    5128           0 :   int __pyx_t_3;
    5129           0 :   PyObject *__pyx_t_4 = NULL;
    5130           0 :   PyObject *__pyx_t_5 = NULL;
    5131           0 :   PyObject *__pyx_t_6 = NULL;
    5132           0 :   unsigned int __pyx_t_7;
    5133           0 :   char *__pyx_t_8;
    5134           0 :   int __pyx_t_9;
    5135           0 :   Py_ssize_t __pyx_t_10;
    5136           0 :   Py_UCS4 __pyx_t_11;
    5137           0 :   int __pyx_lineno = 0;
    5138           0 :   const char *__pyx_filename = NULL;
    5139           0 :   int __pyx_clineno = 0;
    5140           0 :   __Pyx_RefNannySetupContext("__cinit__", 0);
    5141           0 :   __Pyx_INCREF(__pyx_v_format);
    5142             : 
    5143             :   /* "View.MemoryView":137
    5144             :  *         cdef Py_ssize_t dim
    5145             :  * 
    5146             :  *         self.ndim = <int> len(shape)             # <<<<<<<<<<<<<<
    5147             :  *         self.itemsize = itemsize
    5148             :  * 
    5149             :  */
    5150           0 :   if (unlikely(__pyx_v_shape == Py_None)) {
    5151           0 :     PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    5152           0 :     __PYX_ERR(1, 137, __pyx_L1_error)
    5153             :   }
    5154           0 :   __pyx_t_1 = __Pyx_PyTuple_GET_SIZE(__pyx_v_shape); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(1, 137, __pyx_L1_error)
    5155           0 :   __pyx_v_self->ndim = ((int)__pyx_t_1);
    5156             : 
    5157             :   /* "View.MemoryView":138
    5158             :  * 
    5159             :  *         self.ndim = <int> len(shape)
    5160             :  *         self.itemsize = itemsize             # <<<<<<<<<<<<<<
    5161             :  * 
    5162             :  *         if not self.ndim:
    5163             :  */
    5164           0 :   __pyx_v_self->itemsize = __pyx_v_itemsize;
    5165             : 
    5166             :   /* "View.MemoryView":140
    5167             :  *         self.itemsize = itemsize
    5168             :  * 
    5169             :  *         if not self.ndim:             # <<<<<<<<<<<<<<
    5170             :  *             raise ValueError, "Empty shape tuple for cython.array"
    5171             :  * 
    5172             :  */
    5173           0 :   __pyx_t_2 = (!(__pyx_v_self->ndim != 0));
    5174           0 :   if (unlikely(__pyx_t_2)) {
    5175             : 
    5176             :     /* "View.MemoryView":141
    5177             :  * 
    5178             :  *         if not self.ndim:
    5179             :  *             raise ValueError, "Empty shape tuple for cython.array"             # <<<<<<<<<<<<<<
    5180             :  * 
    5181             :  *         if itemsize <= 0:
    5182             :  */
    5183           0 :     __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Empty_shape_tuple_for_cython_arr, 0, 0);
    5184           0 :     __PYX_ERR(1, 141, __pyx_L1_error)
    5185             : 
    5186             :     /* "View.MemoryView":140
    5187             :  *         self.itemsize = itemsize
    5188             :  * 
    5189             :  *         if not self.ndim:             # <<<<<<<<<<<<<<
    5190             :  *             raise ValueError, "Empty shape tuple for cython.array"
    5191             :  * 
    5192             :  */
    5193             :   }
    5194             : 
    5195             :   /* "View.MemoryView":143
    5196             :  *             raise ValueError, "Empty shape tuple for cython.array"
    5197             :  * 
    5198             :  *         if itemsize <= 0:             # <<<<<<<<<<<<<<
    5199             :  *             raise ValueError, "itemsize <= 0 for cython.array"
    5200             :  * 
    5201             :  */
    5202           0 :   __pyx_t_2 = (__pyx_v_itemsize <= 0);
    5203           0 :   if (unlikely(__pyx_t_2)) {
    5204             : 
    5205             :     /* "View.MemoryView":144
    5206             :  * 
    5207             :  *         if itemsize <= 0:
    5208             :  *             raise ValueError, "itemsize <= 0 for cython.array"             # <<<<<<<<<<<<<<
    5209             :  * 
    5210             :  *         if not isinstance(format, bytes):
    5211             :  */
    5212           0 :     __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_itemsize_0_for_cython_array, 0, 0);
    5213           0 :     __PYX_ERR(1, 144, __pyx_L1_error)
    5214             : 
    5215             :     /* "View.MemoryView":143
    5216             :  *             raise ValueError, "Empty shape tuple for cython.array"
    5217             :  * 
    5218             :  *         if itemsize <= 0:             # <<<<<<<<<<<<<<
    5219             :  *             raise ValueError, "itemsize <= 0 for cython.array"
    5220             :  * 
    5221             :  */
    5222             :   }
    5223             : 
    5224             :   /* "View.MemoryView":146
    5225             :  *             raise ValueError, "itemsize <= 0 for cython.array"
    5226             :  * 
    5227             :  *         if not isinstance(format, bytes):             # <<<<<<<<<<<<<<
    5228             :  *             format = format.encode('ASCII')
    5229             :  *         self._format = format  # keep a reference to the byte string
    5230             :  */
    5231           0 :   __pyx_t_2 = PyBytes_Check(__pyx_v_format); 
    5232           0 :   __pyx_t_3 = (!__pyx_t_2);
    5233           0 :   if (__pyx_t_3) {
    5234             : 
    5235             :     /* "View.MemoryView":147
    5236             :  * 
    5237             :  *         if not isinstance(format, bytes):
    5238             :  *             format = format.encode('ASCII')             # <<<<<<<<<<<<<<
    5239             :  *         self._format = format  # keep a reference to the byte string
    5240             :  *         self.format = self._format
    5241             :  */
    5242           0 :     __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_format, __pyx_n_s_encode); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 147, __pyx_L1_error)
    5243           0 :     __Pyx_GOTREF(__pyx_t_5);
    5244           0 :     __pyx_t_6 = NULL;
    5245           0 :     __pyx_t_7 = 0;
    5246             :     #if CYTHON_UNPACK_METHODS
    5247           0 :     if (likely(PyMethod_Check(__pyx_t_5))) {
    5248           0 :       __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
    5249           0 :       if (likely(__pyx_t_6)) {
    5250           0 :         PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
    5251           0 :         __Pyx_INCREF(__pyx_t_6);
    5252           0 :         __Pyx_INCREF(function);
    5253           0 :         __Pyx_DECREF_SET(__pyx_t_5, function);
    5254             :         __pyx_t_7 = 1;
    5255             :       }
    5256             :     }
    5257             :     #endif
    5258             :     {
    5259           0 :       PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_n_s_ASCII};
    5260           0 :       __pyx_t_4 = __Pyx_PyObject_FastCall(__pyx_t_5, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
    5261           0 :       __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
    5262           0 :       if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 147, __pyx_L1_error)
    5263           0 :       __Pyx_GOTREF(__pyx_t_4);
    5264           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    5265             :     }
    5266           0 :     __Pyx_DECREF_SET(__pyx_v_format, __pyx_t_4);
    5267             :     __pyx_t_4 = 0;
    5268             : 
    5269             :     /* "View.MemoryView":146
    5270             :  *             raise ValueError, "itemsize <= 0 for cython.array"
    5271             :  * 
    5272             :  *         if not isinstance(format, bytes):             # <<<<<<<<<<<<<<
    5273             :  *             format = format.encode('ASCII')
    5274             :  *         self._format = format  # keep a reference to the byte string
    5275             :  */
    5276             :   }
    5277             : 
    5278             :   /* "View.MemoryView":148
    5279             :  *         if not isinstance(format, bytes):
    5280             :  *             format = format.encode('ASCII')
    5281             :  *         self._format = format  # keep a reference to the byte string             # <<<<<<<<<<<<<<
    5282             :  *         self.format = self._format
    5283             :  * 
    5284             :  */
    5285           0 :   if (!(likely(PyBytes_CheckExact(__pyx_v_format))||((__pyx_v_format) == Py_None) || __Pyx_RaiseUnexpectedTypeError("bytes", __pyx_v_format))) __PYX_ERR(1, 148, __pyx_L1_error)
    5286           0 :   __pyx_t_4 = __pyx_v_format;
    5287           0 :   __Pyx_INCREF(__pyx_t_4);
    5288           0 :   __Pyx_GIVEREF(__pyx_t_4);
    5289           0 :   __Pyx_GOTREF(__pyx_v_self->_format);
    5290           0 :   __Pyx_DECREF(__pyx_v_self->_format);
    5291           0 :   __pyx_v_self->_format = ((PyObject*)__pyx_t_4);
    5292           0 :   __pyx_t_4 = 0;
    5293             : 
    5294             :   /* "View.MemoryView":149
    5295             :  *             format = format.encode('ASCII')
    5296             :  *         self._format = format  # keep a reference to the byte string
    5297             :  *         self.format = self._format             # <<<<<<<<<<<<<<
    5298             :  * 
    5299             :  * 
    5300             :  */
    5301           0 :   if (unlikely(__pyx_v_self->_format == Py_None)) {
    5302           0 :     PyErr_SetString(PyExc_TypeError, "expected bytes, NoneType found");
    5303           0 :     __PYX_ERR(1, 149, __pyx_L1_error)
    5304             :   }
    5305           0 :   __pyx_t_8 = __Pyx_PyBytes_AsWritableString(__pyx_v_self->_format); if (unlikely((!__pyx_t_8) && PyErr_Occurred())) __PYX_ERR(1, 149, __pyx_L1_error)
    5306           0 :   __pyx_v_self->format = __pyx_t_8;
    5307             : 
    5308             :   /* "View.MemoryView":152
    5309             :  * 
    5310             :  * 
    5311             :  *         self._shape = <Py_ssize_t *> PyObject_Malloc(sizeof(Py_ssize_t)*self.ndim*2)             # <<<<<<<<<<<<<<
    5312             :  *         self._strides = self._shape + self.ndim
    5313             :  * 
    5314             :  */
    5315           0 :   __pyx_v_self->_shape = ((Py_ssize_t *)PyObject_Malloc((((sizeof(Py_ssize_t)) * __pyx_v_self->ndim) * 2)));
    5316             : 
    5317             :   /* "View.MemoryView":153
    5318             :  * 
    5319             :  *         self._shape = <Py_ssize_t *> PyObject_Malloc(sizeof(Py_ssize_t)*self.ndim*2)
    5320             :  *         self._strides = self._shape + self.ndim             # <<<<<<<<<<<<<<
    5321             :  * 
    5322             :  *         if not self._shape:
    5323             :  */
    5324           0 :   __pyx_v_self->_strides = (__pyx_v_self->_shape + __pyx_v_self->ndim);
    5325             : 
    5326             :   /* "View.MemoryView":155
    5327             :  *         self._strides = self._shape + self.ndim
    5328             :  * 
    5329             :  *         if not self._shape:             # <<<<<<<<<<<<<<
    5330             :  *             raise MemoryError, "unable to allocate shape and strides."
    5331             :  * 
    5332             :  */
    5333           0 :   __pyx_t_3 = (!(__pyx_v_self->_shape != 0));
    5334           0 :   if (unlikely(__pyx_t_3)) {
    5335             : 
    5336             :     /* "View.MemoryView":156
    5337             :  * 
    5338             :  *         if not self._shape:
    5339             :  *             raise MemoryError, "unable to allocate shape and strides."             # <<<<<<<<<<<<<<
    5340             :  * 
    5341             :  * 
    5342             :  */
    5343           0 :     __Pyx_Raise(__pyx_builtin_MemoryError, __pyx_kp_s_unable_to_allocate_shape_and_str, 0, 0);
    5344           0 :     __PYX_ERR(1, 156, __pyx_L1_error)
    5345             : 
    5346             :     /* "View.MemoryView":155
    5347             :  *         self._strides = self._shape + self.ndim
    5348             :  * 
    5349             :  *         if not self._shape:             # <<<<<<<<<<<<<<
    5350             :  *             raise MemoryError, "unable to allocate shape and strides."
    5351             :  * 
    5352             :  */
    5353             :   }
    5354             : 
    5355             :   /* "View.MemoryView":159
    5356             :  * 
    5357             :  * 
    5358             :  *         for idx, dim in enumerate(shape):             # <<<<<<<<<<<<<<
    5359             :  *             if dim <= 0:
    5360             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."
    5361             :  */
    5362           0 :   __pyx_t_9 = 0;
    5363           0 :   __pyx_t_4 = __pyx_v_shape; __Pyx_INCREF(__pyx_t_4);
    5364             :   __pyx_t_1 = 0;
    5365           0 :   for (;;) {
    5366           0 :     {
    5367           0 :       Py_ssize_t __pyx_temp = __Pyx_PyTuple_GET_SIZE(__pyx_t_4);
    5368             :       #if !CYTHON_ASSUME_SAFE_MACROS
    5369             :       if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 159, __pyx_L1_error)
    5370             :       #endif
    5371           0 :       if (__pyx_t_1 >= __pyx_temp) break;
    5372             :     }
    5373             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    5374           0 :     __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_1); __Pyx_INCREF(__pyx_t_5); __pyx_t_1++; if (unlikely((0 < 0))) __PYX_ERR(1, 159, __pyx_L1_error)
    5375             :     #else
    5376             :     __pyx_t_5 = __Pyx_PySequence_ITEM(__pyx_t_4, __pyx_t_1); __pyx_t_1++; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 159, __pyx_L1_error)
    5377             :     __Pyx_GOTREF(__pyx_t_5);
    5378             :     #endif
    5379           0 :     __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5); if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 159, __pyx_L1_error)
    5380           0 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    5381           0 :     __pyx_v_dim = __pyx_t_10;
    5382           0 :     __pyx_v_idx = __pyx_t_9;
    5383           0 :     __pyx_t_9 = (__pyx_t_9 + 1);
    5384             : 
    5385             :     /* "View.MemoryView":160
    5386             :  * 
    5387             :  *         for idx, dim in enumerate(shape):
    5388             :  *             if dim <= 0:             # <<<<<<<<<<<<<<
    5389             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."
    5390             :  *             self._shape[idx] = dim
    5391             :  */
    5392           0 :     __pyx_t_3 = (__pyx_v_dim <= 0);
    5393           0 :     if (unlikely(__pyx_t_3)) {
    5394             : 
    5395             :       /* "View.MemoryView":161
    5396             :  *         for idx, dim in enumerate(shape):
    5397             :  *             if dim <= 0:
    5398             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."             # <<<<<<<<<<<<<<
    5399             :  *             self._shape[idx] = dim
    5400             :  * 
    5401             :  */
    5402           0 :       __pyx_t_5 = PyTuple_New(5); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 161, __pyx_L1_error)
    5403           0 :       __Pyx_GOTREF(__pyx_t_5);
    5404           0 :       __pyx_t_10 = 0;
    5405           0 :       __pyx_t_11 = 127;
    5406           0 :       __Pyx_INCREF(__pyx_kp_u_Invalid_shape_in_axis);
    5407           0 :       __pyx_t_10 += 22;
    5408           0 :       __Pyx_GIVEREF(__pyx_kp_u_Invalid_shape_in_axis);
    5409           0 :       PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_kp_u_Invalid_shape_in_axis);
    5410           0 :       __pyx_t_6 = __Pyx_PyUnicode_From_int(__pyx_v_idx, 0, ' ', 'd'); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 161, __pyx_L1_error)
    5411           0 :       __Pyx_GOTREF(__pyx_t_6);
    5412           0 :       __pyx_t_10 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_6);
    5413           0 :       __Pyx_GIVEREF(__pyx_t_6);
    5414           0 :       PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_6);
    5415           0 :       __pyx_t_6 = 0;
    5416           0 :       __Pyx_INCREF(__pyx_kp_u_);
    5417           0 :       __pyx_t_10 += 2;
    5418           0 :       __Pyx_GIVEREF(__pyx_kp_u_);
    5419           0 :       PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_kp_u_);
    5420           0 :       __pyx_t_6 = __Pyx_PyUnicode_From_Py_ssize_t(__pyx_v_dim, 0, ' ', 'd'); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 161, __pyx_L1_error)
    5421           0 :       __Pyx_GOTREF(__pyx_t_6);
    5422           0 :       __pyx_t_10 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_6);
    5423           0 :       __Pyx_GIVEREF(__pyx_t_6);
    5424           0 :       PyTuple_SET_ITEM(__pyx_t_5, 3, __pyx_t_6);
    5425           0 :       __pyx_t_6 = 0;
    5426           0 :       __Pyx_INCREF(__pyx_kp_u__2);
    5427           0 :       __pyx_t_10 += 1;
    5428           0 :       __Pyx_GIVEREF(__pyx_kp_u__2);
    5429           0 :       PyTuple_SET_ITEM(__pyx_t_5, 4, __pyx_kp_u__2);
    5430           0 :       __pyx_t_6 = __Pyx_PyUnicode_Join(__pyx_t_5, 5, __pyx_t_10, __pyx_t_11); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 161, __pyx_L1_error)
    5431           0 :       __Pyx_GOTREF(__pyx_t_6);
    5432           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    5433           0 :       __Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_6, 0, 0);
    5434           0 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    5435           0 :       __PYX_ERR(1, 161, __pyx_L1_error)
    5436             : 
    5437             :       /* "View.MemoryView":160
    5438             :  * 
    5439             :  *         for idx, dim in enumerate(shape):
    5440             :  *             if dim <= 0:             # <<<<<<<<<<<<<<
    5441             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."
    5442             :  *             self._shape[idx] = dim
    5443             :  */
    5444             :     }
    5445             : 
    5446             :     /* "View.MemoryView":162
    5447             :  *             if dim <= 0:
    5448             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."
    5449             :  *             self._shape[idx] = dim             # <<<<<<<<<<<<<<
    5450             :  * 
    5451             :  *         cdef char order
    5452             :  */
    5453           0 :     (__pyx_v_self->_shape[__pyx_v_idx]) = __pyx_v_dim;
    5454             : 
    5455             :     /* "View.MemoryView":159
    5456             :  * 
    5457             :  * 
    5458             :  *         for idx, dim in enumerate(shape):             # <<<<<<<<<<<<<<
    5459             :  *             if dim <= 0:
    5460             :  *                 raise ValueError, f"Invalid shape in axis {idx}: {dim}."
    5461             :  */
    5462             :   }
    5463           0 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    5464             : 
    5465             :   /* "View.MemoryView":165
    5466             :  * 
    5467             :  *         cdef char order
    5468             :  *         if mode == 'c':             # <<<<<<<<<<<<<<
    5469             :  *             order = b'C'
    5470             :  *             self.mode = u'c'
    5471             :  */
    5472           0 :   __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_mode, __pyx_n_s_c, Py_EQ)); if (unlikely((__pyx_t_3 < 0))) __PYX_ERR(1, 165, __pyx_L1_error)
    5473           0 :   if (__pyx_t_3) {
    5474             : 
    5475             :     /* "View.MemoryView":166
    5476             :  *         cdef char order
    5477             :  *         if mode == 'c':
    5478             :  *             order = b'C'             # <<<<<<<<<<<<<<
    5479             :  *             self.mode = u'c'
    5480             :  *         elif mode == 'fortran':
    5481             :  */
    5482           0 :     __pyx_v_order = 'C';
    5483             : 
    5484             :     /* "View.MemoryView":167
    5485             :  *         if mode == 'c':
    5486             :  *             order = b'C'
    5487             :  *             self.mode = u'c'             # <<<<<<<<<<<<<<
    5488             :  *         elif mode == 'fortran':
    5489             :  *             order = b'F'
    5490             :  */
    5491           0 :     __Pyx_INCREF(__pyx_n_u_c);
    5492           0 :     __Pyx_GIVEREF(__pyx_n_u_c);
    5493           0 :     __Pyx_GOTREF(__pyx_v_self->mode);
    5494           0 :     __Pyx_DECREF(__pyx_v_self->mode);
    5495           0 :     __pyx_v_self->mode = __pyx_n_u_c;
    5496             : 
    5497             :     /* "View.MemoryView":165
    5498             :  * 
    5499             :  *         cdef char order
    5500             :  *         if mode == 'c':             # <<<<<<<<<<<<<<
    5501             :  *             order = b'C'
    5502             :  *             self.mode = u'c'
    5503             :  */
    5504           0 :     goto __pyx_L11;
    5505             :   }
    5506             : 
    5507             :   /* "View.MemoryView":168
    5508             :  *             order = b'C'
    5509             :  *             self.mode = u'c'
    5510             :  *         elif mode == 'fortran':             # <<<<<<<<<<<<<<
    5511             :  *             order = b'F'
    5512             :  *             self.mode = u'fortran'
    5513             :  */
    5514           0 :   __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_mode, __pyx_n_s_fortran, Py_EQ)); if (unlikely((__pyx_t_3 < 0))) __PYX_ERR(1, 168, __pyx_L1_error)
    5515           0 :   if (likely(__pyx_t_3)) {
    5516             : 
    5517             :     /* "View.MemoryView":169
    5518             :  *             self.mode = u'c'
    5519             :  *         elif mode == 'fortran':
    5520             :  *             order = b'F'             # <<<<<<<<<<<<<<
    5521             :  *             self.mode = u'fortran'
    5522             :  *         else:
    5523             :  */
    5524           0 :     __pyx_v_order = 'F';
    5525             : 
    5526             :     /* "View.MemoryView":170
    5527             :  *         elif mode == 'fortran':
    5528             :  *             order = b'F'
    5529             :  *             self.mode = u'fortran'             # <<<<<<<<<<<<<<
    5530             :  *         else:
    5531             :  *             raise ValueError, f"Invalid mode, expected 'c' or 'fortran', got {mode}"
    5532             :  */
    5533           0 :     __Pyx_INCREF(__pyx_n_u_fortran);
    5534           0 :     __Pyx_GIVEREF(__pyx_n_u_fortran);
    5535           0 :     __Pyx_GOTREF(__pyx_v_self->mode);
    5536           0 :     __Pyx_DECREF(__pyx_v_self->mode);
    5537           0 :     __pyx_v_self->mode = __pyx_n_u_fortran;
    5538             : 
    5539             :     /* "View.MemoryView":168
    5540             :  *             order = b'C'
    5541             :  *             self.mode = u'c'
    5542             :  *         elif mode == 'fortran':             # <<<<<<<<<<<<<<
    5543             :  *             order = b'F'
    5544             :  *             self.mode = u'fortran'
    5545             :  */
    5546           0 :     goto __pyx_L11;
    5547             :   }
    5548             : 
    5549             :   /* "View.MemoryView":172
    5550             :  *             self.mode = u'fortran'
    5551             :  *         else:
    5552             :  *             raise ValueError, f"Invalid mode, expected 'c' or 'fortran', got {mode}"             # <<<<<<<<<<<<<<
    5553             :  * 
    5554             :  *         self.len = fill_contig_strides_array(self._shape, self._strides, itemsize, self.ndim, order)
    5555             :  */
    5556             :   /*else*/ {
    5557           0 :     __pyx_t_4 = __Pyx_PyObject_FormatSimple(__pyx_v_mode, __pyx_empty_unicode); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 172, __pyx_L1_error)
    5558           0 :     __Pyx_GOTREF(__pyx_t_4);
    5559           0 :     __pyx_t_6 = __Pyx_PyUnicode_Concat(__pyx_kp_u_Invalid_mode_expected_c_or_fortr, __pyx_t_4); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 172, __pyx_L1_error)
    5560           0 :     __Pyx_GOTREF(__pyx_t_6);
    5561           0 :     __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    5562           0 :     __Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_6, 0, 0);
    5563           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    5564           0 :     __PYX_ERR(1, 172, __pyx_L1_error)
    5565             :   }
    5566           0 :   __pyx_L11:;
    5567             : 
    5568             :   /* "View.MemoryView":174
    5569             :  *             raise ValueError, f"Invalid mode, expected 'c' or 'fortran', got {mode}"
    5570             :  * 
    5571             :  *         self.len = fill_contig_strides_array(self._shape, self._strides, itemsize, self.ndim, order)             # <<<<<<<<<<<<<<
    5572             :  * 
    5573             :  *         self.free_data = allocate_buffer
    5574             :  */
    5575           0 :   __pyx_v_self->len = __pyx_fill_contig_strides_array(__pyx_v_self->_shape, __pyx_v_self->_strides, __pyx_v_itemsize, __pyx_v_self->ndim, __pyx_v_order);
    5576             : 
    5577             :   /* "View.MemoryView":176
    5578             :  *         self.len = fill_contig_strides_array(self._shape, self._strides, itemsize, self.ndim, order)
    5579             :  * 
    5580             :  *         self.free_data = allocate_buffer             # <<<<<<<<<<<<<<
    5581             :  *         self.dtype_is_object = format == b'O'
    5582             :  * 
    5583             :  */
    5584           0 :   __pyx_v_self->free_data = __pyx_v_allocate_buffer;
    5585             : 
    5586             :   /* "View.MemoryView":177
    5587             :  * 
    5588             :  *         self.free_data = allocate_buffer
    5589             :  *         self.dtype_is_object = format == b'O'             # <<<<<<<<<<<<<<
    5590             :  * 
    5591             :  *         if allocate_buffer:
    5592             :  */
    5593           0 :   __pyx_t_6 = PyObject_RichCompare(__pyx_v_format, __pyx_n_b_O, Py_EQ); __Pyx_XGOTREF(__pyx_t_6); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 177, __pyx_L1_error)
    5594           0 :   __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 177, __pyx_L1_error)
    5595           0 :   __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    5596           0 :   __pyx_v_self->dtype_is_object = __pyx_t_3;
    5597             : 
    5598             :   /* "View.MemoryView":179
    5599             :  *         self.dtype_is_object = format == b'O'
    5600             :  * 
    5601             :  *         if allocate_buffer:             # <<<<<<<<<<<<<<
    5602             :  *             _allocate_buffer(self)
    5603             :  * 
    5604             :  */
    5605           0 :   if (__pyx_v_allocate_buffer) {
    5606             : 
    5607             :     /* "View.MemoryView":180
    5608             :  * 
    5609             :  *         if allocate_buffer:
    5610             :  *             _allocate_buffer(self)             # <<<<<<<<<<<<<<
    5611             :  * 
    5612             :  *     @cname('getbuffer')
    5613             :  */
    5614           0 :     __pyx_t_9 = __pyx_array_allocate_buffer(__pyx_v_self); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(1, 180, __pyx_L1_error)
    5615             : 
    5616             :     /* "View.MemoryView":179
    5617             :  *         self.dtype_is_object = format == b'O'
    5618             :  * 
    5619             :  *         if allocate_buffer:             # <<<<<<<<<<<<<<
    5620             :  *             _allocate_buffer(self)
    5621             :  * 
    5622             :  */
    5623             :   }
    5624             : 
    5625             :   /* "View.MemoryView":131
    5626             :  *         cdef bint dtype_is_object
    5627             :  * 
    5628             :  *     def __cinit__(array self, tuple shape, Py_ssize_t itemsize, format not None,             # <<<<<<<<<<<<<<
    5629             :  *                   mode="c", bint allocate_buffer=True):
    5630             :  * 
    5631             :  */
    5632             : 
    5633             :   /* function exit code */
    5634           0 :   __pyx_r = 0;
    5635           0 :   goto __pyx_L0;
    5636           0 :   __pyx_L1_error:;
    5637           0 :   __Pyx_XDECREF(__pyx_t_4);
    5638           0 :   __Pyx_XDECREF(__pyx_t_5);
    5639           0 :   __Pyx_XDECREF(__pyx_t_6);
    5640           0 :   __Pyx_AddTraceback("View.MemoryView.array.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    5641           0 :   __pyx_r = -1;
    5642           0 :   __pyx_L0:;
    5643           0 :   __Pyx_XDECREF(__pyx_v_format);
    5644           0 :   __Pyx_RefNannyFinishContext();
    5645           0 :   return __pyx_r;
    5646             : }
    5647             : 
    5648             : /* "View.MemoryView":182
    5649             :  *             _allocate_buffer(self)
    5650             :  * 
    5651             :  *     @cname('getbuffer')             # <<<<<<<<<<<<<<
    5652             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    5653             :  *         cdef int bufmode = -1
    5654             :  */
    5655             : 
    5656             : /* Python wrapper */
    5657             : CYTHON_UNUSED static int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
    5658           0 : CYTHON_UNUSED static int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
    5659           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    5660           0 :   int __pyx_r;
    5661             :   __Pyx_RefNannyDeclarations
    5662           0 :   __Pyx_RefNannySetupContext("__getbuffer__ (wrapper)", 0);
    5663           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    5664           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(((struct __pyx_array_obj *)__pyx_v_self), ((Py_buffer *)__pyx_v_info), ((int)__pyx_v_flags));
    5665             : 
    5666             :   /* function exit code */
    5667           0 :   __Pyx_RefNannyFinishContext();
    5668           0 :   return __pyx_r;
    5669             : }
    5670             : 
    5671           0 : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(struct __pyx_array_obj *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
    5672           0 :   int __pyx_v_bufmode;
    5673           0 :   int __pyx_r;
    5674             :   __Pyx_RefNannyDeclarations
    5675           0 :   int __pyx_t_1;
    5676           0 :   char *__pyx_t_2;
    5677           0 :   Py_ssize_t __pyx_t_3;
    5678           0 :   int __pyx_t_4;
    5679           0 :   Py_ssize_t *__pyx_t_5;
    5680           0 :   int __pyx_lineno = 0;
    5681           0 :   const char *__pyx_filename = NULL;
    5682           0 :   int __pyx_clineno = 0;
    5683           0 :   if (unlikely(__pyx_v_info == NULL)) {
    5684           0 :     PyErr_SetString(PyExc_BufferError, "PyObject_GetBuffer: view==NULL argument is obsolete");
    5685           0 :     return -1;
    5686             :   }
    5687           0 :   __Pyx_RefNannySetupContext("__getbuffer__", 0);
    5688           0 :   __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
    5689           0 :   __Pyx_GIVEREF(__pyx_v_info->obj);
    5690             : 
    5691             :   /* "View.MemoryView":184
    5692             :  *     @cname('getbuffer')
    5693             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    5694             :  *         cdef int bufmode = -1             # <<<<<<<<<<<<<<
    5695             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):
    5696             :  *             if self.mode == u"c":
    5697             :  */
    5698           0 :   __pyx_v_bufmode = -1;
    5699             : 
    5700             :   /* "View.MemoryView":185
    5701             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    5702             :  *         cdef int bufmode = -1
    5703             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):             # <<<<<<<<<<<<<<
    5704             :  *             if self.mode == u"c":
    5705             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5706             :  */
    5707           0 :   __pyx_t_1 = ((__pyx_v_flags & ((PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS) | PyBUF_ANY_CONTIGUOUS)) != 0);
    5708           0 :   if (__pyx_t_1) {
    5709             : 
    5710             :     /* "View.MemoryView":186
    5711             :  *         cdef int bufmode = -1
    5712             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):
    5713             :  *             if self.mode == u"c":             # <<<<<<<<<<<<<<
    5714             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5715             :  *             elif self.mode == u"fortran":
    5716             :  */
    5717           0 :     __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_self->mode, __pyx_n_u_c, Py_EQ)); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 186, __pyx_L1_error)
    5718           0 :     if (__pyx_t_1) {
    5719             : 
    5720             :       /* "View.MemoryView":187
    5721             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):
    5722             :  *             if self.mode == u"c":
    5723             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS             # <<<<<<<<<<<<<<
    5724             :  *             elif self.mode == u"fortran":
    5725             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5726             :  */
    5727           0 :       __pyx_v_bufmode = (PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS);
    5728             : 
    5729             :       /* "View.MemoryView":186
    5730             :  *         cdef int bufmode = -1
    5731             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):
    5732             :  *             if self.mode == u"c":             # <<<<<<<<<<<<<<
    5733             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5734             :  *             elif self.mode == u"fortran":
    5735             :  */
    5736           0 :       goto __pyx_L4;
    5737             :     }
    5738             : 
    5739             :     /* "View.MemoryView":188
    5740             :  *             if self.mode == u"c":
    5741             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5742             :  *             elif self.mode == u"fortran":             # <<<<<<<<<<<<<<
    5743             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5744             :  *             if not (flags & bufmode):
    5745             :  */
    5746           0 :     __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_self->mode, __pyx_n_u_fortran, Py_EQ)); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 188, __pyx_L1_error)
    5747           0 :     if (__pyx_t_1) {
    5748             : 
    5749             :       /* "View.MemoryView":189
    5750             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5751             :  *             elif self.mode == u"fortran":
    5752             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS             # <<<<<<<<<<<<<<
    5753             :  *             if not (flags & bufmode):
    5754             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."
    5755             :  */
    5756           0 :       __pyx_v_bufmode = (PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS);
    5757             : 
    5758             :       /* "View.MemoryView":188
    5759             :  *             if self.mode == u"c":
    5760             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5761             :  *             elif self.mode == u"fortran":             # <<<<<<<<<<<<<<
    5762             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5763             :  *             if not (flags & bufmode):
    5764             :  */
    5765             :     }
    5766           0 :     __pyx_L4:;
    5767             : 
    5768             :     /* "View.MemoryView":190
    5769             :  *             elif self.mode == u"fortran":
    5770             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5771             :  *             if not (flags & bufmode):             # <<<<<<<<<<<<<<
    5772             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."
    5773             :  *         info.buf = self.data
    5774             :  */
    5775           0 :     __pyx_t_1 = (!((__pyx_v_flags & __pyx_v_bufmode) != 0));
    5776           0 :     if (unlikely(__pyx_t_1)) {
    5777             : 
    5778             :       /* "View.MemoryView":191
    5779             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5780             :  *             if not (flags & bufmode):
    5781             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."             # <<<<<<<<<<<<<<
    5782             :  *         info.buf = self.data
    5783             :  *         info.len = self.len
    5784             :  */
    5785           0 :       __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Can_only_create_a_buffer_that_is, 0, 0);
    5786           0 :       __PYX_ERR(1, 191, __pyx_L1_error)
    5787             : 
    5788             :       /* "View.MemoryView":190
    5789             :  *             elif self.mode == u"fortran":
    5790             :  *                 bufmode = PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5791             :  *             if not (flags & bufmode):             # <<<<<<<<<<<<<<
    5792             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."
    5793             :  *         info.buf = self.data
    5794             :  */
    5795             :     }
    5796             : 
    5797             :     /* "View.MemoryView":185
    5798             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    5799             :  *         cdef int bufmode = -1
    5800             :  *         if flags & (PyBUF_C_CONTIGUOUS | PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS):             # <<<<<<<<<<<<<<
    5801             :  *             if self.mode == u"c":
    5802             :  *                 bufmode = PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS
    5803             :  */
    5804             :   }
    5805             : 
    5806             :   /* "View.MemoryView":192
    5807             :  *             if not (flags & bufmode):
    5808             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."
    5809             :  *         info.buf = self.data             # <<<<<<<<<<<<<<
    5810             :  *         info.len = self.len
    5811             :  * 
    5812             :  */
    5813           0 :   __pyx_t_2 = __pyx_v_self->data;
    5814           0 :   __pyx_v_info->buf = __pyx_t_2;
    5815             : 
    5816             :   /* "View.MemoryView":193
    5817             :  *                 raise ValueError, "Can only create a buffer that is contiguous in memory."
    5818             :  *         info.buf = self.data
    5819             :  *         info.len = self.len             # <<<<<<<<<<<<<<
    5820             :  * 
    5821             :  *         if flags & PyBUF_STRIDES:
    5822             :  */
    5823           0 :   __pyx_t_3 = __pyx_v_self->len;
    5824           0 :   __pyx_v_info->len = __pyx_t_3;
    5825             : 
    5826             :   /* "View.MemoryView":195
    5827             :  *         info.len = self.len
    5828             :  * 
    5829             :  *         if flags & PyBUF_STRIDES:             # <<<<<<<<<<<<<<
    5830             :  *             info.ndim = self.ndim
    5831             :  *             info.shape = self._shape
    5832             :  */
    5833           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_STRIDES) != 0);
    5834           0 :   if (__pyx_t_1) {
    5835             : 
    5836             :     /* "View.MemoryView":196
    5837             :  * 
    5838             :  *         if flags & PyBUF_STRIDES:
    5839             :  *             info.ndim = self.ndim             # <<<<<<<<<<<<<<
    5840             :  *             info.shape = self._shape
    5841             :  *             info.strides = self._strides
    5842             :  */
    5843           0 :     __pyx_t_4 = __pyx_v_self->ndim;
    5844           0 :     __pyx_v_info->ndim = __pyx_t_4;
    5845             : 
    5846             :     /* "View.MemoryView":197
    5847             :  *         if flags & PyBUF_STRIDES:
    5848             :  *             info.ndim = self.ndim
    5849             :  *             info.shape = self._shape             # <<<<<<<<<<<<<<
    5850             :  *             info.strides = self._strides
    5851             :  *         else:
    5852             :  */
    5853           0 :     __pyx_t_5 = __pyx_v_self->_shape;
    5854           0 :     __pyx_v_info->shape = __pyx_t_5;
    5855             : 
    5856             :     /* "View.MemoryView":198
    5857             :  *             info.ndim = self.ndim
    5858             :  *             info.shape = self._shape
    5859             :  *             info.strides = self._strides             # <<<<<<<<<<<<<<
    5860             :  *         else:
    5861             :  *             info.ndim = 1
    5862             :  */
    5863           0 :     __pyx_t_5 = __pyx_v_self->_strides;
    5864           0 :     __pyx_v_info->strides = __pyx_t_5;
    5865             : 
    5866             :     /* "View.MemoryView":195
    5867             :  *         info.len = self.len
    5868             :  * 
    5869             :  *         if flags & PyBUF_STRIDES:             # <<<<<<<<<<<<<<
    5870             :  *             info.ndim = self.ndim
    5871             :  *             info.shape = self._shape
    5872             :  */
    5873           0 :     goto __pyx_L6;
    5874             :   }
    5875             : 
    5876             :   /* "View.MemoryView":200
    5877             :  *             info.strides = self._strides
    5878             :  *         else:
    5879             :  *             info.ndim = 1             # <<<<<<<<<<<<<<
    5880             :  *             info.shape = &self.len if flags & PyBUF_ND else NULL
    5881             :  *             info.strides = NULL
    5882             :  */
    5883             :   /*else*/ {
    5884           0 :     __pyx_v_info->ndim = 1;
    5885             : 
    5886             :     /* "View.MemoryView":201
    5887             :  *         else:
    5888             :  *             info.ndim = 1
    5889             :  *             info.shape = &self.len if flags & PyBUF_ND else NULL             # <<<<<<<<<<<<<<
    5890             :  *             info.strides = NULL
    5891             :  * 
    5892             :  */
    5893           0 :     __pyx_t_1 = ((__pyx_v_flags & PyBUF_ND) != 0);
    5894           0 :     if (__pyx_t_1) {
    5895             :       __pyx_t_5 = (&__pyx_v_self->len);
    5896             :     } else {
    5897             :       __pyx_t_5 = NULL;
    5898             :     }
    5899           0 :     __pyx_v_info->shape = __pyx_t_5;
    5900             : 
    5901             :     /* "View.MemoryView":202
    5902             :  *             info.ndim = 1
    5903             :  *             info.shape = &self.len if flags & PyBUF_ND else NULL
    5904             :  *             info.strides = NULL             # <<<<<<<<<<<<<<
    5905             :  * 
    5906             :  *         info.suboffsets = NULL
    5907             :  */
    5908           0 :     __pyx_v_info->strides = NULL;
    5909             :   }
    5910           0 :   __pyx_L6:;
    5911             : 
    5912             :   /* "View.MemoryView":204
    5913             :  *             info.strides = NULL
    5914             :  * 
    5915             :  *         info.suboffsets = NULL             # <<<<<<<<<<<<<<
    5916             :  *         info.itemsize = self.itemsize
    5917             :  *         info.readonly = 0
    5918             :  */
    5919           0 :   __pyx_v_info->suboffsets = NULL;
    5920             : 
    5921             :   /* "View.MemoryView":205
    5922             :  * 
    5923             :  *         info.suboffsets = NULL
    5924             :  *         info.itemsize = self.itemsize             # <<<<<<<<<<<<<<
    5925             :  *         info.readonly = 0
    5926             :  *         info.format = self.format if flags & PyBUF_FORMAT else NULL
    5927             :  */
    5928           0 :   __pyx_t_3 = __pyx_v_self->itemsize;
    5929           0 :   __pyx_v_info->itemsize = __pyx_t_3;
    5930             : 
    5931             :   /* "View.MemoryView":206
    5932             :  *         info.suboffsets = NULL
    5933             :  *         info.itemsize = self.itemsize
    5934             :  *         info.readonly = 0             # <<<<<<<<<<<<<<
    5935             :  *         info.format = self.format if flags & PyBUF_FORMAT else NULL
    5936             :  *         info.obj = self
    5937             :  */
    5938           0 :   __pyx_v_info->readonly = 0;
    5939             : 
    5940             :   /* "View.MemoryView":207
    5941             :  *         info.itemsize = self.itemsize
    5942             :  *         info.readonly = 0
    5943             :  *         info.format = self.format if flags & PyBUF_FORMAT else NULL             # <<<<<<<<<<<<<<
    5944             :  *         info.obj = self
    5945             :  * 
    5946             :  */
    5947           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
    5948           0 :   if (__pyx_t_1) {
    5949           0 :     __pyx_t_2 = __pyx_v_self->format;
    5950             :   } else {
    5951             :     __pyx_t_2 = NULL;
    5952             :   }
    5953           0 :   __pyx_v_info->format = __pyx_t_2;
    5954             : 
    5955             :   /* "View.MemoryView":208
    5956             :  *         info.readonly = 0
    5957             :  *         info.format = self.format if flags & PyBUF_FORMAT else NULL
    5958             :  *         info.obj = self             # <<<<<<<<<<<<<<
    5959             :  * 
    5960             :  *     def __dealloc__(array self):
    5961             :  */
    5962           0 :   __Pyx_INCREF((PyObject *)__pyx_v_self);
    5963           0 :   __Pyx_GIVEREF((PyObject *)__pyx_v_self);
    5964           0 :   __Pyx_GOTREF(__pyx_v_info->obj);
    5965           0 :   __Pyx_DECREF(__pyx_v_info->obj);
    5966           0 :   __pyx_v_info->obj = ((PyObject *)__pyx_v_self);
    5967             : 
    5968             :   /* "View.MemoryView":182
    5969             :  *             _allocate_buffer(self)
    5970             :  * 
    5971             :  *     @cname('getbuffer')             # <<<<<<<<<<<<<<
    5972             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    5973             :  *         cdef int bufmode = -1
    5974             :  */
    5975             : 
    5976             :   /* function exit code */
    5977           0 :   __pyx_r = 0;
    5978           0 :   goto __pyx_L0;
    5979           0 :   __pyx_L1_error:;
    5980           0 :   __Pyx_AddTraceback("View.MemoryView.array.__getbuffer__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    5981           0 :   __pyx_r = -1;
    5982           0 :   if (__pyx_v_info->obj != NULL) {
    5983           0 :     __Pyx_GOTREF(__pyx_v_info->obj);
    5984           0 :     __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
    5985             :   }
    5986           0 :   goto __pyx_L2;
    5987           0 :   __pyx_L0:;
    5988           0 :   if (__pyx_v_info->obj == Py_None) {
    5989           0 :     __Pyx_GOTREF(__pyx_v_info->obj);
    5990           0 :     __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
    5991             :   }
    5992           0 :   __pyx_L2:;
    5993             :   __Pyx_RefNannyFinishContext();
    5994             :   return __pyx_r;
    5995             : }
    5996             : 
    5997             : /* "View.MemoryView":210
    5998             :  *         info.obj = self
    5999             :  * 
    6000             :  *     def __dealloc__(array self):             # <<<<<<<<<<<<<<
    6001             :  *         if self.callback_free_data != NULL:
    6002             :  *             self.callback_free_data(self.data)
    6003             :  */
    6004             : 
    6005             : /* Python wrapper */
    6006             : static void __pyx_array___dealloc__(PyObject *__pyx_v_self); /*proto*/
    6007           0 : static void __pyx_array___dealloc__(PyObject *__pyx_v_self) {
    6008           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6009             :   __Pyx_RefNannyDeclarations
    6010           0 :   __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
    6011           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6012           0 :   __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(((struct __pyx_array_obj *)__pyx_v_self));
    6013             : 
    6014             :   /* function exit code */
    6015           0 :   __Pyx_RefNannyFinishContext();
    6016             : }
    6017             : 
    6018           0 : static void __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(struct __pyx_array_obj *__pyx_v_self) {
    6019           0 :   int __pyx_t_1;
    6020           0 :   int __pyx_t_2;
    6021             : 
    6022             :   /* "View.MemoryView":211
    6023             :  * 
    6024             :  *     def __dealloc__(array self):
    6025             :  *         if self.callback_free_data != NULL:             # <<<<<<<<<<<<<<
    6026             :  *             self.callback_free_data(self.data)
    6027             :  *         elif self.free_data and self.data is not NULL:
    6028             :  */
    6029           0 :   __pyx_t_1 = (__pyx_v_self->callback_free_data != NULL);
    6030           0 :   if (__pyx_t_1) {
    6031             : 
    6032             :     /* "View.MemoryView":212
    6033             :  *     def __dealloc__(array self):
    6034             :  *         if self.callback_free_data != NULL:
    6035             :  *             self.callback_free_data(self.data)             # <<<<<<<<<<<<<<
    6036             :  *         elif self.free_data and self.data is not NULL:
    6037             :  *             if self.dtype_is_object:
    6038             :  */
    6039           0 :     __pyx_v_self->callback_free_data(__pyx_v_self->data);
    6040             : 
    6041             :     /* "View.MemoryView":211
    6042             :  * 
    6043             :  *     def __dealloc__(array self):
    6044             :  *         if self.callback_free_data != NULL:             # <<<<<<<<<<<<<<
    6045             :  *             self.callback_free_data(self.data)
    6046             :  *         elif self.free_data and self.data is not NULL:
    6047             :  */
    6048           0 :     goto __pyx_L3;
    6049             :   }
    6050             : 
    6051             :   /* "View.MemoryView":213
    6052             :  *         if self.callback_free_data != NULL:
    6053             :  *             self.callback_free_data(self.data)
    6054             :  *         elif self.free_data and self.data is not NULL:             # <<<<<<<<<<<<<<
    6055             :  *             if self.dtype_is_object:
    6056             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6057             :  */
    6058           0 :   if (__pyx_v_self->free_data) {
    6059           0 :   } else {
    6060           0 :     __pyx_t_1 = __pyx_v_self->free_data;
    6061           0 :     goto __pyx_L4_bool_binop_done;
    6062             :   }
    6063           0 :   __pyx_t_2 = (__pyx_v_self->data != NULL);
    6064           0 :   __pyx_t_1 = __pyx_t_2;
    6065           0 :   __pyx_L4_bool_binop_done:;
    6066           0 :   if (__pyx_t_1) {
    6067             : 
    6068             :     /* "View.MemoryView":214
    6069             :  *             self.callback_free_data(self.data)
    6070             :  *         elif self.free_data and self.data is not NULL:
    6071             :  *             if self.dtype_is_object:             # <<<<<<<<<<<<<<
    6072             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6073             :  *             free(self.data)
    6074             :  */
    6075           0 :     if (__pyx_v_self->dtype_is_object) {
    6076             : 
    6077             :       /* "View.MemoryView":215
    6078             :  *         elif self.free_data and self.data is not NULL:
    6079             :  *             if self.dtype_is_object:
    6080             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)             # <<<<<<<<<<<<<<
    6081             :  *             free(self.data)
    6082             :  *         PyObject_Free(self._shape)
    6083             :  */
    6084           0 :       __pyx_memoryview_refcount_objects_in_slice(__pyx_v_self->data, __pyx_v_self->_shape, __pyx_v_self->_strides, __pyx_v_self->ndim, 0);
    6085             : 
    6086             :       /* "View.MemoryView":214
    6087             :  *             self.callback_free_data(self.data)
    6088             :  *         elif self.free_data and self.data is not NULL:
    6089             :  *             if self.dtype_is_object:             # <<<<<<<<<<<<<<
    6090             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6091             :  *             free(self.data)
    6092             :  */
    6093             :     }
    6094             : 
    6095             :     /* "View.MemoryView":216
    6096             :  *             if self.dtype_is_object:
    6097             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6098             :  *             free(self.data)             # <<<<<<<<<<<<<<
    6099             :  *         PyObject_Free(self._shape)
    6100             :  * 
    6101             :  */
    6102           0 :     free(__pyx_v_self->data);
    6103             : 
    6104             :     /* "View.MemoryView":213
    6105             :  *         if self.callback_free_data != NULL:
    6106             :  *             self.callback_free_data(self.data)
    6107             :  *         elif self.free_data and self.data is not NULL:             # <<<<<<<<<<<<<<
    6108             :  *             if self.dtype_is_object:
    6109             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6110             :  */
    6111             :   }
    6112           0 :   __pyx_L3:;
    6113             : 
    6114             :   /* "View.MemoryView":217
    6115             :  *                 refcount_objects_in_slice(self.data, self._shape, self._strides, self.ndim, inc=False)
    6116             :  *             free(self.data)
    6117             :  *         PyObject_Free(self._shape)             # <<<<<<<<<<<<<<
    6118             :  * 
    6119             :  *     @property
    6120             :  */
    6121           0 :   PyObject_Free(__pyx_v_self->_shape);
    6122             : 
    6123             :   /* "View.MemoryView":210
    6124             :  *         info.obj = self
    6125             :  * 
    6126             :  *     def __dealloc__(array self):             # <<<<<<<<<<<<<<
    6127             :  *         if self.callback_free_data != NULL:
    6128             :  *             self.callback_free_data(self.data)
    6129             :  */
    6130             : 
    6131             :   /* function exit code */
    6132           0 : }
    6133             : 
    6134             : /* "View.MemoryView":219
    6135             :  *         PyObject_Free(self._shape)
    6136             :  * 
    6137             :  *     @property             # <<<<<<<<<<<<<<
    6138             :  *     def memview(self):
    6139             :  *         return self.get_memview()
    6140             :  */
    6141             : 
    6142             : /* Python wrapper */
    6143             : static PyObject *__pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(PyObject *__pyx_v_self); /*proto*/
    6144           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(PyObject *__pyx_v_self) {
    6145           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6146           0 :   PyObject *__pyx_r = 0;
    6147             :   __Pyx_RefNannyDeclarations
    6148           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
    6149           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6150           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_5array_7memview___get__(((struct __pyx_array_obj *)__pyx_v_self));
    6151             : 
    6152             :   /* function exit code */
    6153           0 :   __Pyx_RefNannyFinishContext();
    6154           0 :   return __pyx_r;
    6155             : }
    6156             : 
    6157           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_5array_7memview___get__(struct __pyx_array_obj *__pyx_v_self) {
    6158           0 :   PyObject *__pyx_r = NULL;
    6159             :   __Pyx_RefNannyDeclarations
    6160           0 :   PyObject *__pyx_t_1 = NULL;
    6161           0 :   int __pyx_lineno = 0;
    6162           0 :   const char *__pyx_filename = NULL;
    6163           0 :   int __pyx_clineno = 0;
    6164           0 :   __Pyx_RefNannySetupContext("__get__", 1);
    6165             : 
    6166             :   /* "View.MemoryView":221
    6167             :  *     @property
    6168             :  *     def memview(self):
    6169             :  *         return self.get_memview()             # <<<<<<<<<<<<<<
    6170             :  * 
    6171             :  *     @cname('get_memview')
    6172             :  */
    6173           0 :   __Pyx_XDECREF(__pyx_r);
    6174           0 :   __pyx_t_1 = ((struct __pyx_vtabstruct_array *)__pyx_v_self->__pyx_vtab)->get_memview(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 221, __pyx_L1_error)
    6175           0 :   __Pyx_GOTREF(__pyx_t_1);
    6176           0 :   __pyx_r = __pyx_t_1;
    6177           0 :   __pyx_t_1 = 0;
    6178           0 :   goto __pyx_L0;
    6179             : 
    6180             :   /* "View.MemoryView":219
    6181             :  *         PyObject_Free(self._shape)
    6182             :  * 
    6183             :  *     @property             # <<<<<<<<<<<<<<
    6184             :  *     def memview(self):
    6185             :  *         return self.get_memview()
    6186             :  */
    6187             : 
    6188             :   /* function exit code */
    6189           0 :   __pyx_L1_error:;
    6190           0 :   __Pyx_XDECREF(__pyx_t_1);
    6191           0 :   __Pyx_AddTraceback("View.MemoryView.array.memview.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6192           0 :   __pyx_r = NULL;
    6193           0 :   __pyx_L0:;
    6194           0 :   __Pyx_XGIVEREF(__pyx_r);
    6195           0 :   __Pyx_RefNannyFinishContext();
    6196           0 :   return __pyx_r;
    6197             : }
    6198             : 
    6199             : /* "View.MemoryView":224
    6200             :  * 
    6201             :  *     @cname('get_memview')
    6202             :  *     cdef get_memview(self):             # <<<<<<<<<<<<<<
    6203             :  *         flags =  PyBUF_ANY_CONTIGUOUS|PyBUF_FORMAT|PyBUF_WRITABLE
    6204             :  *         return  memoryview(self, flags, self.dtype_is_object)
    6205             :  */
    6206             : 
    6207           0 : static PyObject *__pyx_array_get_memview(struct __pyx_array_obj *__pyx_v_self) {
    6208           0 :   int __pyx_v_flags;
    6209           0 :   PyObject *__pyx_r = NULL;
    6210             :   __Pyx_RefNannyDeclarations
    6211           0 :   PyObject *__pyx_t_1 = NULL;
    6212           0 :   PyObject *__pyx_t_2 = NULL;
    6213           0 :   PyObject *__pyx_t_3 = NULL;
    6214           0 :   int __pyx_lineno = 0;
    6215           0 :   const char *__pyx_filename = NULL;
    6216           0 :   int __pyx_clineno = 0;
    6217           0 :   __Pyx_RefNannySetupContext("get_memview", 1);
    6218             : 
    6219             :   /* "View.MemoryView":225
    6220             :  *     @cname('get_memview')
    6221             :  *     cdef get_memview(self):
    6222             :  *         flags =  PyBUF_ANY_CONTIGUOUS|PyBUF_FORMAT|PyBUF_WRITABLE             # <<<<<<<<<<<<<<
    6223             :  *         return  memoryview(self, flags, self.dtype_is_object)
    6224             :  * 
    6225             :  */
    6226           0 :   __pyx_v_flags = ((PyBUF_ANY_CONTIGUOUS | PyBUF_FORMAT) | PyBUF_WRITABLE);
    6227             : 
    6228             :   /* "View.MemoryView":226
    6229             :  *     cdef get_memview(self):
    6230             :  *         flags =  PyBUF_ANY_CONTIGUOUS|PyBUF_FORMAT|PyBUF_WRITABLE
    6231             :  *         return  memoryview(self, flags, self.dtype_is_object)             # <<<<<<<<<<<<<<
    6232             :  * 
    6233             :  *     def __len__(self):
    6234             :  */
    6235           0 :   __Pyx_XDECREF(__pyx_r);
    6236           0 :   __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_flags); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 226, __pyx_L1_error)
    6237           0 :   __Pyx_GOTREF(__pyx_t_1);
    6238           0 :   __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_self->dtype_is_object); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 226, __pyx_L1_error)
    6239           0 :   __Pyx_GOTREF(__pyx_t_2);
    6240           0 :   __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 226, __pyx_L1_error)
    6241           0 :   __Pyx_GOTREF(__pyx_t_3);
    6242           0 :   __Pyx_INCREF((PyObject *)__pyx_v_self);
    6243           0 :   __Pyx_GIVEREF((PyObject *)__pyx_v_self);
    6244           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_v_self))) __PYX_ERR(1, 226, __pyx_L1_error);
    6245           0 :   __Pyx_GIVEREF(__pyx_t_1);
    6246           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1)) __PYX_ERR(1, 226, __pyx_L1_error);
    6247           0 :   __Pyx_GIVEREF(__pyx_t_2);
    6248           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2)) __PYX_ERR(1, 226, __pyx_L1_error);
    6249           0 :   __pyx_t_1 = 0;
    6250           0 :   __pyx_t_2 = 0;
    6251           0 :   __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 226, __pyx_L1_error)
    6252           0 :   __Pyx_GOTREF(__pyx_t_2);
    6253           0 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    6254           0 :   __pyx_r = __pyx_t_2;
    6255           0 :   __pyx_t_2 = 0;
    6256           0 :   goto __pyx_L0;
    6257             : 
    6258             :   /* "View.MemoryView":224
    6259             :  * 
    6260             :  *     @cname('get_memview')
    6261             :  *     cdef get_memview(self):             # <<<<<<<<<<<<<<
    6262             :  *         flags =  PyBUF_ANY_CONTIGUOUS|PyBUF_FORMAT|PyBUF_WRITABLE
    6263             :  *         return  memoryview(self, flags, self.dtype_is_object)
    6264             :  */
    6265             : 
    6266             :   /* function exit code */
    6267           0 :   __pyx_L1_error:;
    6268           0 :   __Pyx_XDECREF(__pyx_t_1);
    6269           0 :   __Pyx_XDECREF(__pyx_t_2);
    6270           0 :   __Pyx_XDECREF(__pyx_t_3);
    6271           0 :   __Pyx_AddTraceback("View.MemoryView.array.get_memview", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6272           0 :   __pyx_r = 0;
    6273           0 :   __pyx_L0:;
    6274           0 :   __Pyx_XGIVEREF(__pyx_r);
    6275           0 :   __Pyx_RefNannyFinishContext();
    6276           0 :   return __pyx_r;
    6277             : }
    6278             : 
    6279             : /* "View.MemoryView":228
    6280             :  *         return  memoryview(self, flags, self.dtype_is_object)
    6281             :  * 
    6282             :  *     def __len__(self):             # <<<<<<<<<<<<<<
    6283             :  *         return self._shape[0]
    6284             :  * 
    6285             :  */
    6286             : 
    6287             : /* Python wrapper */
    6288             : static Py_ssize_t __pyx_array___len__(PyObject *__pyx_v_self); /*proto*/
    6289           0 : static Py_ssize_t __pyx_array___len__(PyObject *__pyx_v_self) {
    6290           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6291           0 :   Py_ssize_t __pyx_r;
    6292             :   __Pyx_RefNannyDeclarations
    6293           0 :   __Pyx_RefNannySetupContext("__len__ (wrapper)", 0);
    6294           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6295           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(((struct __pyx_array_obj *)__pyx_v_self));
    6296             : 
    6297             :   /* function exit code */
    6298           0 :   __Pyx_RefNannyFinishContext();
    6299           0 :   return __pyx_r;
    6300             : }
    6301             : 
    6302           0 : static Py_ssize_t __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(struct __pyx_array_obj *__pyx_v_self) {
    6303           0 :   Py_ssize_t __pyx_r;
    6304             : 
    6305             :   /* "View.MemoryView":229
    6306             :  * 
    6307             :  *     def __len__(self):
    6308             :  *         return self._shape[0]             # <<<<<<<<<<<<<<
    6309             :  * 
    6310             :  *     def __getattr__(self, attr):
    6311             :  */
    6312           0 :   __pyx_r = (__pyx_v_self->_shape[0]);
    6313           0 :   goto __pyx_L0;
    6314             : 
    6315             :   /* "View.MemoryView":228
    6316             :  *         return  memoryview(self, flags, self.dtype_is_object)
    6317             :  * 
    6318             :  *     def __len__(self):             # <<<<<<<<<<<<<<
    6319             :  *         return self._shape[0]
    6320             :  * 
    6321             :  */
    6322             : 
    6323             :   /* function exit code */
    6324           0 :   __pyx_L0:;
    6325           0 :   return __pyx_r;
    6326             : }
    6327             : 
    6328             : /* "View.MemoryView":231
    6329             :  *         return self._shape[0]
    6330             :  * 
    6331             :  *     def __getattr__(self, attr):             # <<<<<<<<<<<<<<
    6332             :  *         return getattr(self.memview, attr)
    6333             :  * 
    6334             :  */
    6335             : 
    6336             : /* Python wrapper */
    6337             : static PyObject *__pyx_array___getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_attr); /*proto*/
    6338           0 : static PyObject *__pyx_array___getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_attr) {
    6339           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6340           0 :   PyObject *__pyx_r = 0;
    6341             :   __Pyx_RefNannyDeclarations
    6342           0 :   __Pyx_RefNannySetupContext("__getattr__ (wrapper)", 0);
    6343           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6344           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(((struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_attr));
    6345             : 
    6346             :   /* function exit code */
    6347           0 :   __Pyx_RefNannyFinishContext();
    6348           0 :   return __pyx_r;
    6349             : }
    6350             : 
    6351           0 : static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_attr) {
    6352           0 :   PyObject *__pyx_r = NULL;
    6353             :   __Pyx_RefNannyDeclarations
    6354           0 :   PyObject *__pyx_t_1 = NULL;
    6355           0 :   PyObject *__pyx_t_2 = NULL;
    6356           0 :   int __pyx_lineno = 0;
    6357           0 :   const char *__pyx_filename = NULL;
    6358           0 :   int __pyx_clineno = 0;
    6359           0 :   __Pyx_RefNannySetupContext("__getattr__", 1);
    6360             : 
    6361             :   /* "View.MemoryView":232
    6362             :  * 
    6363             :  *     def __getattr__(self, attr):
    6364             :  *         return getattr(self.memview, attr)             # <<<<<<<<<<<<<<
    6365             :  * 
    6366             :  *     def __getitem__(self, item):
    6367             :  */
    6368           0 :   __Pyx_XDECREF(__pyx_r);
    6369           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 232, __pyx_L1_error)
    6370           0 :   __Pyx_GOTREF(__pyx_t_1);
    6371           0 :   __pyx_t_2 = __Pyx_GetAttr(__pyx_t_1, __pyx_v_attr); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 232, __pyx_L1_error)
    6372           0 :   __Pyx_GOTREF(__pyx_t_2);
    6373           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    6374           0 :   __pyx_r = __pyx_t_2;
    6375           0 :   __pyx_t_2 = 0;
    6376           0 :   goto __pyx_L0;
    6377             : 
    6378             :   /* "View.MemoryView":231
    6379             :  *         return self._shape[0]
    6380             :  * 
    6381             :  *     def __getattr__(self, attr):             # <<<<<<<<<<<<<<
    6382             :  *         return getattr(self.memview, attr)
    6383             :  * 
    6384             :  */
    6385             : 
    6386             :   /* function exit code */
    6387           0 :   __pyx_L1_error:;
    6388           0 :   __Pyx_XDECREF(__pyx_t_1);
    6389           0 :   __Pyx_XDECREF(__pyx_t_2);
    6390           0 :   __Pyx_AddTraceback("View.MemoryView.array.__getattr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6391           0 :   __pyx_r = NULL;
    6392           0 :   __pyx_L0:;
    6393           0 :   __Pyx_XGIVEREF(__pyx_r);
    6394           0 :   __Pyx_RefNannyFinishContext();
    6395           0 :   return __pyx_r;
    6396             : }
    6397             : 
    6398             : /* "View.MemoryView":234
    6399             :  *         return getattr(self.memview, attr)
    6400             :  * 
    6401             :  *     def __getitem__(self, item):             # <<<<<<<<<<<<<<
    6402             :  *         return self.memview[item]
    6403             :  * 
    6404             :  */
    6405             : 
    6406             : /* Python wrapper */
    6407             : static PyObject *__pyx_array___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item); /*proto*/
    6408           0 : static PyObject *__pyx_array___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item) {
    6409           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6410           0 :   PyObject *__pyx_r = 0;
    6411             :   __Pyx_RefNannyDeclarations
    6412           0 :   __Pyx_RefNannySetupContext("__getitem__ (wrapper)", 0);
    6413           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6414           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(((struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_item));
    6415             : 
    6416             :   /* function exit code */
    6417           0 :   __Pyx_RefNannyFinishContext();
    6418           0 :   return __pyx_r;
    6419             : }
    6420             : 
    6421           0 : static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item) {
    6422           0 :   PyObject *__pyx_r = NULL;
    6423             :   __Pyx_RefNannyDeclarations
    6424           0 :   PyObject *__pyx_t_1 = NULL;
    6425           0 :   PyObject *__pyx_t_2 = NULL;
    6426           0 :   int __pyx_lineno = 0;
    6427           0 :   const char *__pyx_filename = NULL;
    6428           0 :   int __pyx_clineno = 0;
    6429           0 :   __Pyx_RefNannySetupContext("__getitem__", 1);
    6430             : 
    6431             :   /* "View.MemoryView":235
    6432             :  * 
    6433             :  *     def __getitem__(self, item):
    6434             :  *         return self.memview[item]             # <<<<<<<<<<<<<<
    6435             :  * 
    6436             :  *     def __setitem__(self, item, value):
    6437             :  */
    6438           0 :   __Pyx_XDECREF(__pyx_r);
    6439           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 235, __pyx_L1_error)
    6440           0 :   __Pyx_GOTREF(__pyx_t_1);
    6441           0 :   __pyx_t_2 = __Pyx_PyObject_GetItem(__pyx_t_1, __pyx_v_item); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 235, __pyx_L1_error)
    6442           0 :   __Pyx_GOTREF(__pyx_t_2);
    6443           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    6444           0 :   __pyx_r = __pyx_t_2;
    6445           0 :   __pyx_t_2 = 0;
    6446           0 :   goto __pyx_L0;
    6447             : 
    6448             :   /* "View.MemoryView":234
    6449             :  *         return getattr(self.memview, attr)
    6450             :  * 
    6451             :  *     def __getitem__(self, item):             # <<<<<<<<<<<<<<
    6452             :  *         return self.memview[item]
    6453             :  * 
    6454             :  */
    6455             : 
    6456             :   /* function exit code */
    6457           0 :   __pyx_L1_error:;
    6458           0 :   __Pyx_XDECREF(__pyx_t_1);
    6459           0 :   __Pyx_XDECREF(__pyx_t_2);
    6460           0 :   __Pyx_AddTraceback("View.MemoryView.array.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6461           0 :   __pyx_r = NULL;
    6462           0 :   __pyx_L0:;
    6463           0 :   __Pyx_XGIVEREF(__pyx_r);
    6464           0 :   __Pyx_RefNannyFinishContext();
    6465           0 :   return __pyx_r;
    6466             : }
    6467             : 
    6468             : /* "View.MemoryView":237
    6469             :  *         return self.memview[item]
    6470             :  * 
    6471             :  *     def __setitem__(self, item, value):             # <<<<<<<<<<<<<<
    6472             :  *         self.memview[item] = value
    6473             :  * 
    6474             :  */
    6475             : 
    6476             : /* Python wrapper */
    6477             : static int __pyx_array___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value); /*proto*/
    6478           0 : static int __pyx_array___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value) {
    6479           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6480           0 :   int __pyx_r;
    6481             :   __Pyx_RefNannyDeclarations
    6482           0 :   __Pyx_RefNannySetupContext("__setitem__ (wrapper)", 0);
    6483           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    6484           0 :   __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(((struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_item), ((PyObject *)__pyx_v_value));
    6485             : 
    6486             :   /* function exit code */
    6487           0 :   __Pyx_RefNannyFinishContext();
    6488           0 :   return __pyx_r;
    6489             : }
    6490             : 
    6491           0 : static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value) {
    6492           0 :   int __pyx_r;
    6493             :   __Pyx_RefNannyDeclarations
    6494           0 :   PyObject *__pyx_t_1 = NULL;
    6495           0 :   int __pyx_lineno = 0;
    6496           0 :   const char *__pyx_filename = NULL;
    6497           0 :   int __pyx_clineno = 0;
    6498           0 :   __Pyx_RefNannySetupContext("__setitem__", 1);
    6499             : 
    6500             :   /* "View.MemoryView":238
    6501             :  * 
    6502             :  *     def __setitem__(self, item, value):
    6503             :  *         self.memview[item] = value             # <<<<<<<<<<<<<<
    6504             :  * 
    6505             :  * 
    6506             :  */
    6507           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 238, __pyx_L1_error)
    6508           0 :   __Pyx_GOTREF(__pyx_t_1);
    6509           0 :   if (unlikely((PyObject_SetItem(__pyx_t_1, __pyx_v_item, __pyx_v_value) < 0))) __PYX_ERR(1, 238, __pyx_L1_error)
    6510           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    6511             : 
    6512             :   /* "View.MemoryView":237
    6513             :  *         return self.memview[item]
    6514             :  * 
    6515             :  *     def __setitem__(self, item, value):             # <<<<<<<<<<<<<<
    6516             :  *         self.memview[item] = value
    6517             :  * 
    6518             :  */
    6519             : 
    6520             :   /* function exit code */
    6521           0 :   __pyx_r = 0;
    6522           0 :   goto __pyx_L0;
    6523           0 :   __pyx_L1_error:;
    6524           0 :   __Pyx_XDECREF(__pyx_t_1);
    6525           0 :   __Pyx_AddTraceback("View.MemoryView.array.__setitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6526           0 :   __pyx_r = -1;
    6527           0 :   __pyx_L0:;
    6528           0 :   __Pyx_RefNannyFinishContext();
    6529           0 :   return __pyx_r;
    6530             : }
    6531             : 
    6532             : /* "(tree fragment)":1
    6533             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
    6534             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6535             :  * def __setstate_cython__(self, __pyx_state):
    6536             :  */
    6537             : 
    6538             : /* Python wrapper */
    6539             : static PyObject *__pyx_pw___pyx_array_1__reduce_cython__(PyObject *__pyx_v_self, 
    6540             : #if CYTHON_METH_FASTCALL
    6541             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    6542             : #else
    6543             : PyObject *__pyx_args, PyObject *__pyx_kwds
    6544             : #endif
    6545             : ); /*proto*/
    6546           0 : static PyObject *__pyx_pw___pyx_array_1__reduce_cython__(PyObject *__pyx_v_self, 
    6547             : #if CYTHON_METH_FASTCALL
    6548             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    6549             : #else
    6550             : PyObject *__pyx_args, PyObject *__pyx_kwds
    6551             : #endif
    6552             : ) {
    6553             :   #if !CYTHON_METH_FASTCALL
    6554             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    6555             :   #endif
    6556           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6557           0 :   PyObject *__pyx_r = 0;
    6558             :   __Pyx_RefNannyDeclarations
    6559           0 :   __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
    6560             :   #if !CYTHON_METH_FASTCALL
    6561             :   #if CYTHON_ASSUME_SAFE_MACROS
    6562             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    6563             :   #else
    6564             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
    6565             :   #endif
    6566             :   #endif
    6567           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
    6568           0 :   if (unlikely(__pyx_nargs > 0)) {
    6569           0 :     __Pyx_RaiseArgtupleInvalid("__reduce_cython__", 1, 0, 0, __pyx_nargs); return NULL;}
    6570           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__reduce_cython__", 0))) return NULL;
    6571           0 :   __pyx_r = __pyx_pf___pyx_array___reduce_cython__(((struct __pyx_array_obj *)__pyx_v_self));
    6572             : 
    6573             :   /* function exit code */
    6574           0 :   __Pyx_RefNannyFinishContext();
    6575           0 :   return __pyx_r;
    6576             : }
    6577             : 
    6578           0 : static PyObject *__pyx_pf___pyx_array___reduce_cython__(CYTHON_UNUSED struct __pyx_array_obj *__pyx_v_self) {
    6579           0 :   PyObject *__pyx_r = NULL;
    6580             :   __Pyx_RefNannyDeclarations
    6581           0 :   int __pyx_lineno = 0;
    6582           0 :   const char *__pyx_filename = NULL;
    6583           0 :   int __pyx_clineno = 0;
    6584           0 :   __Pyx_RefNannySetupContext("__reduce_cython__", 1);
    6585             : 
    6586             :   /* "(tree fragment)":2
    6587             :  * def __reduce_cython__(self):
    6588             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
    6589             :  * def __setstate_cython__(self, __pyx_state):
    6590             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6591             :  */
    6592           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
    6593           0 :   __PYX_ERR(1, 2, __pyx_L1_error)
    6594             : 
    6595             :   /* "(tree fragment)":1
    6596             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
    6597             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6598             :  * def __setstate_cython__(self, __pyx_state):
    6599             :  */
    6600             : 
    6601             :   /* function exit code */
    6602           0 :   __pyx_L1_error:;
    6603           0 :   __Pyx_AddTraceback("View.MemoryView.array.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6604           0 :   __pyx_r = NULL;
    6605           0 :   __Pyx_XGIVEREF(__pyx_r);
    6606           0 :   __Pyx_RefNannyFinishContext();
    6607           0 :   return __pyx_r;
    6608             : }
    6609             : 
    6610             : /* "(tree fragment)":3
    6611             :  * def __reduce_cython__(self):
    6612             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6613             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
    6614             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6615             :  */
    6616             : 
    6617             : /* Python wrapper */
    6618             : static PyObject *__pyx_pw___pyx_array_3__setstate_cython__(PyObject *__pyx_v_self, 
    6619             : #if CYTHON_METH_FASTCALL
    6620             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    6621             : #else
    6622             : PyObject *__pyx_args, PyObject *__pyx_kwds
    6623             : #endif
    6624             : ); /*proto*/
    6625           0 : static PyObject *__pyx_pw___pyx_array_3__setstate_cython__(PyObject *__pyx_v_self, 
    6626             : #if CYTHON_METH_FASTCALL
    6627             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    6628             : #else
    6629             : PyObject *__pyx_args, PyObject *__pyx_kwds
    6630             : #endif
    6631             : ) {
    6632           0 :   CYTHON_UNUSED PyObject *__pyx_v___pyx_state = 0;
    6633             :   #if !CYTHON_METH_FASTCALL
    6634             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    6635             :   #endif
    6636           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    6637           0 :   PyObject* values[1] = {0};
    6638           0 :   int __pyx_lineno = 0;
    6639           0 :   const char *__pyx_filename = NULL;
    6640           0 :   int __pyx_clineno = 0;
    6641           0 :   PyObject *__pyx_r = 0;
    6642             :   __Pyx_RefNannyDeclarations
    6643           0 :   __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
    6644             :   #if !CYTHON_METH_FASTCALL
    6645             :   #if CYTHON_ASSUME_SAFE_MACROS
    6646             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    6647             :   #else
    6648             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
    6649             :   #endif
    6650             :   #endif
    6651           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
    6652             :   {
    6653           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_state,0};
    6654           0 :     if (__pyx_kwds) {
    6655           0 :       Py_ssize_t kw_args;
    6656           0 :       switch (__pyx_nargs) {
    6657           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
    6658           0 :         CYTHON_FALLTHROUGH;
    6659           0 :         case  0: break;
    6660           0 :         default: goto __pyx_L5_argtuple_error;
    6661             :       }
    6662           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
    6663           0 :       switch (__pyx_nargs) {
    6664             :         case  0:
    6665           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_state)) != 0)) {
    6666           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
    6667           0 :           kw_args--;
    6668             :         }
    6669           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 3, __pyx_L3_error)
    6670           0 :         else goto __pyx_L5_argtuple_error;
    6671             :       }
    6672           0 :       if (unlikely(kw_args > 0)) {
    6673           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
    6674           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__setstate_cython__") < 0)) __PYX_ERR(1, 3, __pyx_L3_error)
    6675             :       }
    6676           0 :     } else if (unlikely(__pyx_nargs != 1)) {
    6677           0 :       goto __pyx_L5_argtuple_error;
    6678             :     } else {
    6679           0 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
    6680             :     }
    6681           0 :     __pyx_v___pyx_state = values[0];
    6682             :   }
    6683           0 :   goto __pyx_L6_skip;
    6684           0 :   __pyx_L5_argtuple_error:;
    6685           0 :   __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, __pyx_nargs); __PYX_ERR(1, 3, __pyx_L3_error)
    6686           0 :   __pyx_L6_skip:;
    6687           0 :   goto __pyx_L4_argument_unpacking_done;
    6688           0 :   __pyx_L3_error:;
    6689             :   {
    6690           0 :     Py_ssize_t __pyx_temp;
    6691           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    6692             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
    6693             :     }
    6694             :   }
    6695           0 :   __Pyx_AddTraceback("View.MemoryView.array.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6696           0 :   __Pyx_RefNannyFinishContext();
    6697           0 :   return NULL;
    6698           0 :   __pyx_L4_argument_unpacking_done:;
    6699           0 :   __pyx_r = __pyx_pf___pyx_array_2__setstate_cython__(((struct __pyx_array_obj *)__pyx_v_self), __pyx_v___pyx_state);
    6700             : 
    6701             :   /* function exit code */
    6702             :   {
    6703           0 :     Py_ssize_t __pyx_temp;
    6704           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    6705             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
    6706             :     }
    6707             :   }
    6708             :   __Pyx_RefNannyFinishContext();
    6709             :   return __pyx_r;
    6710             : }
    6711             : 
    6712           0 : static PyObject *__pyx_pf___pyx_array_2__setstate_cython__(CYTHON_UNUSED struct __pyx_array_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
    6713           0 :   PyObject *__pyx_r = NULL;
    6714             :   __Pyx_RefNannyDeclarations
    6715           0 :   int __pyx_lineno = 0;
    6716           0 :   const char *__pyx_filename = NULL;
    6717           0 :   int __pyx_clineno = 0;
    6718           0 :   __Pyx_RefNannySetupContext("__setstate_cython__", 1);
    6719             : 
    6720             :   /* "(tree fragment)":4
    6721             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6722             :  * def __setstate_cython__(self, __pyx_state):
    6723             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
    6724             :  */
    6725           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
    6726           0 :   __PYX_ERR(1, 4, __pyx_L1_error)
    6727             : 
    6728             :   /* "(tree fragment)":3
    6729             :  * def __reduce_cython__(self):
    6730             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6731             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
    6732             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
    6733             :  */
    6734             : 
    6735             :   /* function exit code */
    6736           0 :   __pyx_L1_error:;
    6737           0 :   __Pyx_AddTraceback("View.MemoryView.array.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6738           0 :   __pyx_r = NULL;
    6739           0 :   __Pyx_XGIVEREF(__pyx_r);
    6740           0 :   __Pyx_RefNannyFinishContext();
    6741           0 :   return __pyx_r;
    6742             : }
    6743             : 
    6744             : /* "View.MemoryView":248
    6745             :  * 
    6746             :  * @cname("__pyx_array_allocate_buffer")
    6747             :  * cdef int _allocate_buffer(array self) except -1:             # <<<<<<<<<<<<<<
    6748             :  * 
    6749             :  * 
    6750             :  */
    6751             : 
    6752           0 : static int __pyx_array_allocate_buffer(struct __pyx_array_obj *__pyx_v_self) {
    6753           0 :   Py_ssize_t __pyx_v_i;
    6754           0 :   PyObject **__pyx_v_p;
    6755           0 :   int __pyx_r;
    6756           0 :   int __pyx_t_1;
    6757           0 :   Py_ssize_t __pyx_t_2;
    6758           0 :   Py_ssize_t __pyx_t_3;
    6759           0 :   Py_ssize_t __pyx_t_4;
    6760           0 :   int __pyx_lineno = 0;
    6761           0 :   const char *__pyx_filename = NULL;
    6762           0 :   int __pyx_clineno = 0;
    6763             : 
    6764             :   /* "View.MemoryView":254
    6765             :  *     cdef PyObject **p
    6766             :  * 
    6767             :  *     self.free_data = True             # <<<<<<<<<<<<<<
    6768             :  *     self.data = <char *>malloc(self.len)
    6769             :  *     if not self.data:
    6770             :  */
    6771           0 :   __pyx_v_self->free_data = 1;
    6772             : 
    6773             :   /* "View.MemoryView":255
    6774             :  * 
    6775             :  *     self.free_data = True
    6776             :  *     self.data = <char *>malloc(self.len)             # <<<<<<<<<<<<<<
    6777             :  *     if not self.data:
    6778             :  *         raise MemoryError, "unable to allocate array data."
    6779             :  */
    6780           0 :   __pyx_v_self->data = ((char *)malloc(__pyx_v_self->len));
    6781             : 
    6782             :   /* "View.MemoryView":256
    6783             :  *     self.free_data = True
    6784             :  *     self.data = <char *>malloc(self.len)
    6785             :  *     if not self.data:             # <<<<<<<<<<<<<<
    6786             :  *         raise MemoryError, "unable to allocate array data."
    6787             :  * 
    6788             :  */
    6789           0 :   __pyx_t_1 = (!(__pyx_v_self->data != 0));
    6790           0 :   if (unlikely(__pyx_t_1)) {
    6791             : 
    6792             :     /* "View.MemoryView":257
    6793             :  *     self.data = <char *>malloc(self.len)
    6794             :  *     if not self.data:
    6795             :  *         raise MemoryError, "unable to allocate array data."             # <<<<<<<<<<<<<<
    6796             :  * 
    6797             :  *     if self.dtype_is_object:
    6798             :  */
    6799           0 :     __Pyx_Raise(__pyx_builtin_MemoryError, __pyx_kp_s_unable_to_allocate_array_data, 0, 0);
    6800           0 :     __PYX_ERR(1, 257, __pyx_L1_error)
    6801             : 
    6802             :     /* "View.MemoryView":256
    6803             :  *     self.free_data = True
    6804             :  *     self.data = <char *>malloc(self.len)
    6805             :  *     if not self.data:             # <<<<<<<<<<<<<<
    6806             :  *         raise MemoryError, "unable to allocate array data."
    6807             :  * 
    6808             :  */
    6809             :   }
    6810             : 
    6811             :   /* "View.MemoryView":259
    6812             :  *         raise MemoryError, "unable to allocate array data."
    6813             :  * 
    6814             :  *     if self.dtype_is_object:             # <<<<<<<<<<<<<<
    6815             :  *         p = <PyObject **> self.data
    6816             :  *         for i in range(self.len // self.itemsize):
    6817             :  */
    6818           0 :   if (__pyx_v_self->dtype_is_object) {
    6819             : 
    6820             :     /* "View.MemoryView":260
    6821             :  * 
    6822             :  *     if self.dtype_is_object:
    6823             :  *         p = <PyObject **> self.data             # <<<<<<<<<<<<<<
    6824             :  *         for i in range(self.len // self.itemsize):
    6825             :  *             p[i] = Py_None
    6826             :  */
    6827           0 :     __pyx_v_p = ((PyObject **)__pyx_v_self->data);
    6828             : 
    6829             :     /* "View.MemoryView":261
    6830             :  *     if self.dtype_is_object:
    6831             :  *         p = <PyObject **> self.data
    6832             :  *         for i in range(self.len // self.itemsize):             # <<<<<<<<<<<<<<
    6833             :  *             p[i] = Py_None
    6834             :  *             Py_INCREF(Py_None)
    6835             :  */
    6836           0 :     if (unlikely(__pyx_v_self->itemsize == 0)) {
    6837           0 :       PyErr_SetString(PyExc_ZeroDivisionError, "integer division or modulo by zero");
    6838           0 :       __PYX_ERR(1, 261, __pyx_L1_error)
    6839             :     }
    6840           0 :     else if (sizeof(Py_ssize_t) == sizeof(long) && (!(((Py_ssize_t)-1) > 0)) && unlikely(__pyx_v_self->itemsize == (Py_ssize_t)-1)  && unlikely(__Pyx_UNARY_NEG_WOULD_OVERFLOW(__pyx_v_self->len))) {
    6841           0 :       PyErr_SetString(PyExc_OverflowError, "value too large to perform division");
    6842           0 :       __PYX_ERR(1, 261, __pyx_L1_error)
    6843             :     }
    6844           0 :     __pyx_t_2 = __Pyx_div_Py_ssize_t(__pyx_v_self->len, __pyx_v_self->itemsize);
    6845           0 :     __pyx_t_3 = __pyx_t_2;
    6846           0 :     for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
    6847           0 :       __pyx_v_i = __pyx_t_4;
    6848             : 
    6849             :       /* "View.MemoryView":262
    6850             :  *         p = <PyObject **> self.data
    6851             :  *         for i in range(self.len // self.itemsize):
    6852             :  *             p[i] = Py_None             # <<<<<<<<<<<<<<
    6853             :  *             Py_INCREF(Py_None)
    6854             :  *     return 0
    6855             :  */
    6856           0 :       (__pyx_v_p[__pyx_v_i]) = Py_None;
    6857             : 
    6858             :       /* "View.MemoryView":263
    6859             :  *         for i in range(self.len // self.itemsize):
    6860             :  *             p[i] = Py_None
    6861             :  *             Py_INCREF(Py_None)             # <<<<<<<<<<<<<<
    6862             :  *     return 0
    6863             :  * 
    6864             :  */
    6865           0 :       Py_INCREF(Py_None);
    6866             :     }
    6867             : 
    6868             :     /* "View.MemoryView":259
    6869             :  *         raise MemoryError, "unable to allocate array data."
    6870             :  * 
    6871             :  *     if self.dtype_is_object:             # <<<<<<<<<<<<<<
    6872             :  *         p = <PyObject **> self.data
    6873             :  *         for i in range(self.len // self.itemsize):
    6874             :  */
    6875             :   }
    6876             : 
    6877             :   /* "View.MemoryView":264
    6878             :  *             p[i] = Py_None
    6879             :  *             Py_INCREF(Py_None)
    6880             :  *     return 0             # <<<<<<<<<<<<<<
    6881             :  * 
    6882             :  * 
    6883             :  */
    6884           0 :   __pyx_r = 0;
    6885           0 :   goto __pyx_L0;
    6886             : 
    6887             :   /* "View.MemoryView":248
    6888             :  * 
    6889             :  * @cname("__pyx_array_allocate_buffer")
    6890             :  * cdef int _allocate_buffer(array self) except -1:             # <<<<<<<<<<<<<<
    6891             :  * 
    6892             :  * 
    6893             :  */
    6894             : 
    6895             :   /* function exit code */
    6896           0 :   __pyx_L1_error:;
    6897           0 :   __Pyx_AddTraceback("View.MemoryView._allocate_buffer", __pyx_clineno, __pyx_lineno, __pyx_filename);
    6898           0 :   __pyx_r = -1;
    6899           0 :   __pyx_L0:;
    6900           0 :   return __pyx_r;
    6901             : }
    6902             : 
    6903             : /* "View.MemoryView":268
    6904             :  * 
    6905             :  * @cname("__pyx_array_new")
    6906             :  * cdef array array_cwrapper(tuple shape, Py_ssize_t itemsize, char *format, char *c_mode, char *buf):             # <<<<<<<<<<<<<<
    6907             :  *     cdef array result
    6908             :  *     cdef str mode = "fortran" if c_mode[0] == b'f' else "c"  # this often comes from a constant C string.
    6909             :  */
    6910             : 
    6911           0 : static struct __pyx_array_obj *__pyx_array_new(PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize, char *__pyx_v_format, char *__pyx_v_c_mode, char *__pyx_v_buf) {
    6912           0 :   struct __pyx_array_obj *__pyx_v_result = 0;
    6913           0 :   PyObject *__pyx_v_mode = 0;
    6914           0 :   struct __pyx_array_obj *__pyx_r = NULL;
    6915             :   __Pyx_RefNannyDeclarations
    6916           0 :   PyObject *__pyx_t_1 = NULL;
    6917           0 :   int __pyx_t_2;
    6918           0 :   PyObject *__pyx_t_3 = NULL;
    6919           0 :   PyObject *__pyx_t_4 = NULL;
    6920           0 :   int __pyx_lineno = 0;
    6921           0 :   const char *__pyx_filename = NULL;
    6922           0 :   int __pyx_clineno = 0;
    6923           0 :   __Pyx_RefNannySetupContext("array_cwrapper", 1);
    6924             : 
    6925             :   /* "View.MemoryView":270
    6926             :  * cdef array array_cwrapper(tuple shape, Py_ssize_t itemsize, char *format, char *c_mode, char *buf):
    6927             :  *     cdef array result
    6928             :  *     cdef str mode = "fortran" if c_mode[0] == b'f' else "c"  # this often comes from a constant C string.             # <<<<<<<<<<<<<<
    6929             :  * 
    6930             :  *     if buf is NULL:
    6931             :  */
    6932           0 :   __pyx_t_2 = ((__pyx_v_c_mode[0]) == 'f');
    6933           0 :   if (__pyx_t_2) {
    6934           0 :     __Pyx_INCREF(__pyx_n_s_fortran);
    6935             :     __pyx_t_1 = __pyx_n_s_fortran;
    6936             :   } else {
    6937           0 :     __Pyx_INCREF(__pyx_n_s_c);
    6938             :     __pyx_t_1 = __pyx_n_s_c;
    6939             :   }
    6940           0 :   __pyx_v_mode = ((PyObject*)__pyx_t_1);
    6941           0 :   __pyx_t_1 = 0;
    6942             : 
    6943             :   /* "View.MemoryView":272
    6944             :  *     cdef str mode = "fortran" if c_mode[0] == b'f' else "c"  # this often comes from a constant C string.
    6945             :  * 
    6946             :  *     if buf is NULL:             # <<<<<<<<<<<<<<
    6947             :  *         result = array.__new__(array, shape, itemsize, format, mode)
    6948             :  *     else:
    6949             :  */
    6950           0 :   __pyx_t_2 = (__pyx_v_buf == NULL);
    6951           0 :   if (__pyx_t_2) {
    6952             : 
    6953             :     /* "View.MemoryView":273
    6954             :  * 
    6955             :  *     if buf is NULL:
    6956             :  *         result = array.__new__(array, shape, itemsize, format, mode)             # <<<<<<<<<<<<<<
    6957             :  *     else:
    6958             :  *         result = array.__new__(array, shape, itemsize, format, mode, allocate_buffer=False)
    6959             :  */
    6960           0 :     __pyx_t_1 = PyInt_FromSsize_t(__pyx_v_itemsize); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 273, __pyx_L1_error)
    6961           0 :     __Pyx_GOTREF(__pyx_t_1);
    6962           0 :     __pyx_t_3 = __Pyx_PyBytes_FromString(__pyx_v_format); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 273, __pyx_L1_error)
    6963           0 :     __Pyx_GOTREF(__pyx_t_3);
    6964           0 :     __pyx_t_4 = PyTuple_New(4); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 273, __pyx_L1_error)
    6965           0 :     __Pyx_GOTREF(__pyx_t_4);
    6966           0 :     __Pyx_INCREF(__pyx_v_shape);
    6967           0 :     __Pyx_GIVEREF(__pyx_v_shape);
    6968           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_shape)) __PYX_ERR(1, 273, __pyx_L1_error);
    6969           0 :     __Pyx_GIVEREF(__pyx_t_1);
    6970           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1)) __PYX_ERR(1, 273, __pyx_L1_error);
    6971           0 :     __Pyx_GIVEREF(__pyx_t_3);
    6972           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_3)) __PYX_ERR(1, 273, __pyx_L1_error);
    6973           0 :     __Pyx_INCREF(__pyx_v_mode);
    6974           0 :     __Pyx_GIVEREF(__pyx_v_mode);
    6975           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_v_mode)) __PYX_ERR(1, 273, __pyx_L1_error);
    6976           0 :     __pyx_t_1 = 0;
    6977           0 :     __pyx_t_3 = 0;
    6978           0 :     __pyx_t_3 = ((PyObject *)__pyx_tp_new_array(((PyTypeObject *)__pyx_array_type), __pyx_t_4, NULL)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 273, __pyx_L1_error)
    6979           0 :     __Pyx_GOTREF((PyObject *)__pyx_t_3);
    6980           0 :     __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    6981           0 :     __pyx_v_result = ((struct __pyx_array_obj *)__pyx_t_3);
    6982           0 :     __pyx_t_3 = 0;
    6983             : 
    6984             :     /* "View.MemoryView":272
    6985             :  *     cdef str mode = "fortran" if c_mode[0] == b'f' else "c"  # this often comes from a constant C string.
    6986             :  * 
    6987             :  *     if buf is NULL:             # <<<<<<<<<<<<<<
    6988             :  *         result = array.__new__(array, shape, itemsize, format, mode)
    6989             :  *     else:
    6990             :  */
    6991           0 :     goto __pyx_L3;
    6992             :   }
    6993             : 
    6994             :   /* "View.MemoryView":275
    6995             :  *         result = array.__new__(array, shape, itemsize, format, mode)
    6996             :  *     else:
    6997             :  *         result = array.__new__(array, shape, itemsize, format, mode, allocate_buffer=False)             # <<<<<<<<<<<<<<
    6998             :  *         result.data = buf
    6999             :  * 
    7000             :  */
    7001             :   /*else*/ {
    7002           0 :     __pyx_t_3 = PyInt_FromSsize_t(__pyx_v_itemsize); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 275, __pyx_L1_error)
    7003           0 :     __Pyx_GOTREF(__pyx_t_3);
    7004           0 :     __pyx_t_4 = __Pyx_PyBytes_FromString(__pyx_v_format); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 275, __pyx_L1_error)
    7005           0 :     __Pyx_GOTREF(__pyx_t_4);
    7006           0 :     __pyx_t_1 = PyTuple_New(4); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 275, __pyx_L1_error)
    7007           0 :     __Pyx_GOTREF(__pyx_t_1);
    7008           0 :     __Pyx_INCREF(__pyx_v_shape);
    7009           0 :     __Pyx_GIVEREF(__pyx_v_shape);
    7010           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_shape)) __PYX_ERR(1, 275, __pyx_L1_error);
    7011           0 :     __Pyx_GIVEREF(__pyx_t_3);
    7012           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3)) __PYX_ERR(1, 275, __pyx_L1_error);
    7013           0 :     __Pyx_GIVEREF(__pyx_t_4);
    7014           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4)) __PYX_ERR(1, 275, __pyx_L1_error);
    7015           0 :     __Pyx_INCREF(__pyx_v_mode);
    7016           0 :     __Pyx_GIVEREF(__pyx_v_mode);
    7017           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_mode)) __PYX_ERR(1, 275, __pyx_L1_error);
    7018           0 :     __pyx_t_3 = 0;
    7019           0 :     __pyx_t_4 = 0;
    7020           0 :     __pyx_t_4 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 275, __pyx_L1_error)
    7021           0 :     __Pyx_GOTREF(__pyx_t_4);
    7022           0 :     if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_allocate_buffer, Py_False) < 0) __PYX_ERR(1, 275, __pyx_L1_error)
    7023           0 :     __pyx_t_3 = ((PyObject *)__pyx_tp_new_array(((PyTypeObject *)__pyx_array_type), __pyx_t_1, __pyx_t_4)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 275, __pyx_L1_error)
    7024           0 :     __Pyx_GOTREF((PyObject *)__pyx_t_3);
    7025           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    7026           0 :     __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    7027           0 :     __pyx_v_result = ((struct __pyx_array_obj *)__pyx_t_3);
    7028           0 :     __pyx_t_3 = 0;
    7029             : 
    7030             :     /* "View.MemoryView":276
    7031             :  *     else:
    7032             :  *         result = array.__new__(array, shape, itemsize, format, mode, allocate_buffer=False)
    7033             :  *         result.data = buf             # <<<<<<<<<<<<<<
    7034             :  * 
    7035             :  *     return result
    7036             :  */
    7037           0 :     __pyx_v_result->data = __pyx_v_buf;
    7038             :   }
    7039           0 :   __pyx_L3:;
    7040             : 
    7041             :   /* "View.MemoryView":278
    7042             :  *         result.data = buf
    7043             :  * 
    7044             :  *     return result             # <<<<<<<<<<<<<<
    7045             :  * 
    7046             :  * 
    7047             :  */
    7048           0 :   __Pyx_XDECREF((PyObject *)__pyx_r);
    7049           0 :   __Pyx_INCREF((PyObject *)__pyx_v_result);
    7050           0 :   __pyx_r = __pyx_v_result;
    7051           0 :   goto __pyx_L0;
    7052             : 
    7053             :   /* "View.MemoryView":268
    7054             :  * 
    7055             :  * @cname("__pyx_array_new")
    7056             :  * cdef array array_cwrapper(tuple shape, Py_ssize_t itemsize, char *format, char *c_mode, char *buf):             # <<<<<<<<<<<<<<
    7057             :  *     cdef array result
    7058             :  *     cdef str mode = "fortran" if c_mode[0] == b'f' else "c"  # this often comes from a constant C string.
    7059             :  */
    7060             : 
    7061             :   /* function exit code */
    7062           0 :   __pyx_L1_error:;
    7063           0 :   __Pyx_XDECREF(__pyx_t_1);
    7064           0 :   __Pyx_XDECREF(__pyx_t_3);
    7065           0 :   __Pyx_XDECREF(__pyx_t_4);
    7066           0 :   __Pyx_AddTraceback("View.MemoryView.array_cwrapper", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7067           0 :   __pyx_r = 0;
    7068           0 :   __pyx_L0:;
    7069           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_result);
    7070           0 :   __Pyx_XDECREF(__pyx_v_mode);
    7071           0 :   __Pyx_XGIVEREF((PyObject *)__pyx_r);
    7072           0 :   __Pyx_RefNannyFinishContext();
    7073           0 :   return __pyx_r;
    7074             : }
    7075             : 
    7076             : /* "View.MemoryView":304
    7077             :  * cdef class Enum(object):
    7078             :  *     cdef object name
    7079             :  *     def __init__(self, name):             # <<<<<<<<<<<<<<
    7080             :  *         self.name = name
    7081             :  *     def __repr__(self):
    7082             :  */
    7083             : 
    7084             : /* Python wrapper */
    7085             : static int __pyx_MemviewEnum___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
    7086          15 : static int __pyx_MemviewEnum___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
    7087          15 :   PyObject *__pyx_v_name = 0;
    7088          15 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    7089          15 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    7090          15 :   PyObject* values[1] = {0};
    7091          15 :   int __pyx_lineno = 0;
    7092          15 :   const char *__pyx_filename = NULL;
    7093          15 :   int __pyx_clineno = 0;
    7094          15 :   int __pyx_r;
    7095             :   __Pyx_RefNannyDeclarations
    7096          15 :   __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
    7097             :   #if CYTHON_ASSUME_SAFE_MACROS
    7098          15 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    7099             :   #else
    7100             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return -1;
    7101             :   #endif
    7102          15 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    7103             :   {
    7104          15 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_name,0};
    7105          15 :     if (__pyx_kwds) {
    7106           0 :       Py_ssize_t kw_args;
    7107           0 :       switch (__pyx_nargs) {
    7108           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    7109           0 :         CYTHON_FALLTHROUGH;
    7110           0 :         case  0: break;
    7111           0 :         default: goto __pyx_L5_argtuple_error;
    7112             :       }
    7113           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
    7114           0 :       switch (__pyx_nargs) {
    7115           0 :         case  0:
    7116           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_name)) != 0)) {
    7117           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
    7118           0 :           kw_args--;
    7119             :         }
    7120           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 304, __pyx_L3_error)
    7121           0 :         else goto __pyx_L5_argtuple_error;
    7122             :       }
    7123           0 :       if (unlikely(kw_args > 0)) {
    7124           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
    7125           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__init__") < 0)) __PYX_ERR(1, 304, __pyx_L3_error)
    7126             :       }
    7127          15 :     } else if (unlikely(__pyx_nargs != 1)) {
    7128           0 :       goto __pyx_L5_argtuple_error;
    7129             :     } else {
    7130          15 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    7131             :     }
    7132          15 :     __pyx_v_name = values[0];
    7133             :   }
    7134          15 :   goto __pyx_L6_skip;
    7135           0 :   __pyx_L5_argtuple_error:;
    7136           0 :   __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, __pyx_nargs); __PYX_ERR(1, 304, __pyx_L3_error)
    7137          15 :   __pyx_L6_skip:;
    7138          15 :   goto __pyx_L4_argument_unpacking_done;
    7139           0 :   __pyx_L3_error:;
    7140             :   {
    7141           0 :     Py_ssize_t __pyx_temp;
    7142           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7143             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    7144             :     }
    7145             :   }
    7146           0 :   __Pyx_AddTraceback("View.MemoryView.Enum.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7147           0 :   __Pyx_RefNannyFinishContext();
    7148           0 :   return -1;
    7149          15 :   __pyx_L4_argument_unpacking_done:;
    7150          15 :   __pyx_r = __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(((struct __pyx_MemviewEnum_obj *)__pyx_v_self), __pyx_v_name);
    7151             : 
    7152             :   /* function exit code */
    7153             :   {
    7154          15 :     Py_ssize_t __pyx_temp;
    7155          15 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7156             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    7157             :     }
    7158             :   }
    7159             :   __Pyx_RefNannyFinishContext();
    7160             :   return __pyx_r;
    7161             : }
    7162             : 
    7163          15 : static int __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v_name) {
    7164          15 :   int __pyx_r;
    7165             :   __Pyx_RefNannyDeclarations
    7166          15 :   __Pyx_RefNannySetupContext("__init__", 1);
    7167             : 
    7168             :   /* "View.MemoryView":305
    7169             :  *     cdef object name
    7170             :  *     def __init__(self, name):
    7171             :  *         self.name = name             # <<<<<<<<<<<<<<
    7172             :  *     def __repr__(self):
    7173             :  *         return self.name
    7174             :  */
    7175          15 :   __Pyx_INCREF(__pyx_v_name);
    7176          15 :   __Pyx_GIVEREF(__pyx_v_name);
    7177          15 :   __Pyx_GOTREF(__pyx_v_self->name);
    7178          15 :   __Pyx_DECREF(__pyx_v_self->name);
    7179          15 :   __pyx_v_self->name = __pyx_v_name;
    7180             : 
    7181             :   /* "View.MemoryView":304
    7182             :  * cdef class Enum(object):
    7183             :  *     cdef object name
    7184             :  *     def __init__(self, name):             # <<<<<<<<<<<<<<
    7185             :  *         self.name = name
    7186             :  *     def __repr__(self):
    7187             :  */
    7188             : 
    7189             :   /* function exit code */
    7190          15 :   __pyx_r = 0;
    7191          15 :   __Pyx_RefNannyFinishContext();
    7192          15 :   return __pyx_r;
    7193             : }
    7194             : 
    7195             : /* "View.MemoryView":306
    7196             :  *     def __init__(self, name):
    7197             :  *         self.name = name
    7198             :  *     def __repr__(self):             # <<<<<<<<<<<<<<
    7199             :  *         return self.name
    7200             :  * 
    7201             :  */
    7202             : 
    7203             : /* Python wrapper */
    7204             : static PyObject *__pyx_MemviewEnum___repr__(PyObject *__pyx_v_self); /*proto*/
    7205           0 : static PyObject *__pyx_MemviewEnum___repr__(PyObject *__pyx_v_self) {
    7206           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    7207           0 :   PyObject *__pyx_r = 0;
    7208             :   __Pyx_RefNannyDeclarations
    7209           0 :   __Pyx_RefNannySetupContext("__repr__ (wrapper)", 0);
    7210           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    7211           0 :   __pyx_r = __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(((struct __pyx_MemviewEnum_obj *)__pyx_v_self));
    7212             : 
    7213             :   /* function exit code */
    7214           0 :   __Pyx_RefNannyFinishContext();
    7215           0 :   return __pyx_r;
    7216             : }
    7217             : 
    7218           0 : static PyObject *__pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(struct __pyx_MemviewEnum_obj *__pyx_v_self) {
    7219           0 :   PyObject *__pyx_r = NULL;
    7220             :   __Pyx_RefNannyDeclarations
    7221           0 :   __Pyx_RefNannySetupContext("__repr__", 1);
    7222             : 
    7223             :   /* "View.MemoryView":307
    7224             :  *         self.name = name
    7225             :  *     def __repr__(self):
    7226             :  *         return self.name             # <<<<<<<<<<<<<<
    7227             :  * 
    7228             :  * cdef generic = Enum("<strided and direct or indirect>")
    7229             :  */
    7230           0 :   __Pyx_XDECREF(__pyx_r);
    7231           0 :   __Pyx_INCREF(__pyx_v_self->name);
    7232           0 :   __pyx_r = __pyx_v_self->name;
    7233           0 :   goto __pyx_L0;
    7234             : 
    7235             :   /* "View.MemoryView":306
    7236             :  *     def __init__(self, name):
    7237             :  *         self.name = name
    7238             :  *     def __repr__(self):             # <<<<<<<<<<<<<<
    7239             :  *         return self.name
    7240             :  * 
    7241             :  */
    7242             : 
    7243             :   /* function exit code */
    7244           0 :   __pyx_L0:;
    7245           0 :   __Pyx_XGIVEREF(__pyx_r);
    7246           0 :   __Pyx_RefNannyFinishContext();
    7247           0 :   return __pyx_r;
    7248             : }
    7249             : 
    7250             : /* "(tree fragment)":1
    7251             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
    7252             :  *     cdef tuple state
    7253             :  *     cdef object _dict
    7254             :  */
    7255             : 
    7256             : /* Python wrapper */
    7257             : static PyObject *__pyx_pw___pyx_MemviewEnum_1__reduce_cython__(PyObject *__pyx_v_self, 
    7258             : #if CYTHON_METH_FASTCALL
    7259             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    7260             : #else
    7261             : PyObject *__pyx_args, PyObject *__pyx_kwds
    7262             : #endif
    7263             : ); /*proto*/
    7264           0 : static PyObject *__pyx_pw___pyx_MemviewEnum_1__reduce_cython__(PyObject *__pyx_v_self, 
    7265             : #if CYTHON_METH_FASTCALL
    7266             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    7267             : #else
    7268             : PyObject *__pyx_args, PyObject *__pyx_kwds
    7269             : #endif
    7270             : ) {
    7271             :   #if !CYTHON_METH_FASTCALL
    7272             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    7273             :   #endif
    7274           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    7275           0 :   PyObject *__pyx_r = 0;
    7276             :   __Pyx_RefNannyDeclarations
    7277           0 :   __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
    7278             :   #if !CYTHON_METH_FASTCALL
    7279             :   #if CYTHON_ASSUME_SAFE_MACROS
    7280             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    7281             :   #else
    7282             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
    7283             :   #endif
    7284             :   #endif
    7285           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
    7286           0 :   if (unlikely(__pyx_nargs > 0)) {
    7287           0 :     __Pyx_RaiseArgtupleInvalid("__reduce_cython__", 1, 0, 0, __pyx_nargs); return NULL;}
    7288           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__reduce_cython__", 0))) return NULL;
    7289           0 :   __pyx_r = __pyx_pf___pyx_MemviewEnum___reduce_cython__(((struct __pyx_MemviewEnum_obj *)__pyx_v_self));
    7290             : 
    7291             :   /* function exit code */
    7292           0 :   __Pyx_RefNannyFinishContext();
    7293           0 :   return __pyx_r;
    7294             : }
    7295             : 
    7296           0 : static PyObject *__pyx_pf___pyx_MemviewEnum___reduce_cython__(struct __pyx_MemviewEnum_obj *__pyx_v_self) {
    7297           0 :   PyObject *__pyx_v_state = 0;
    7298           0 :   PyObject *__pyx_v__dict = 0;
    7299           0 :   int __pyx_v_use_setstate;
    7300           0 :   PyObject *__pyx_r = NULL;
    7301             :   __Pyx_RefNannyDeclarations
    7302           0 :   PyObject *__pyx_t_1 = NULL;
    7303           0 :   int __pyx_t_2;
    7304           0 :   PyObject *__pyx_t_3 = NULL;
    7305           0 :   PyObject *__pyx_t_4 = NULL;
    7306           0 :   int __pyx_lineno = 0;
    7307           0 :   const char *__pyx_filename = NULL;
    7308           0 :   int __pyx_clineno = 0;
    7309           0 :   __Pyx_RefNannySetupContext("__reduce_cython__", 1);
    7310             : 
    7311             :   /* "(tree fragment)":5
    7312             :  *     cdef object _dict
    7313             :  *     cdef bint use_setstate
    7314             :  *     state = (self.name,)             # <<<<<<<<<<<<<<
    7315             :  *     _dict = getattr(self, '__dict__', None)
    7316             :  *     if _dict is not None:
    7317             :  */
    7318           0 :   __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 5, __pyx_L1_error)
    7319           0 :   __Pyx_GOTREF(__pyx_t_1);
    7320           0 :   __Pyx_INCREF(__pyx_v_self->name);
    7321           0 :   __Pyx_GIVEREF(__pyx_v_self->name);
    7322           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->name)) __PYX_ERR(1, 5, __pyx_L1_error);
    7323           0 :   __pyx_v_state = ((PyObject*)__pyx_t_1);
    7324           0 :   __pyx_t_1 = 0;
    7325             : 
    7326             :   /* "(tree fragment)":6
    7327             :  *     cdef bint use_setstate
    7328             :  *     state = (self.name,)
    7329             :  *     _dict = getattr(self, '__dict__', None)             # <<<<<<<<<<<<<<
    7330             :  *     if _dict is not None:
    7331             :  *         state += (_dict,)
    7332             :  */
    7333           0 :   __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
    7334           0 :   __Pyx_GOTREF(__pyx_t_1);
    7335           0 :   __pyx_v__dict = __pyx_t_1;
    7336           0 :   __pyx_t_1 = 0;
    7337             : 
    7338             :   /* "(tree fragment)":7
    7339             :  *     state = (self.name,)
    7340             :  *     _dict = getattr(self, '__dict__', None)
    7341             :  *     if _dict is not None:             # <<<<<<<<<<<<<<
    7342             :  *         state += (_dict,)
    7343             :  *         use_setstate = True
    7344             :  */
    7345           0 :   __pyx_t_2 = (__pyx_v__dict != Py_None);
    7346           0 :   if (__pyx_t_2) {
    7347             : 
    7348             :     /* "(tree fragment)":8
    7349             :  *     _dict = getattr(self, '__dict__', None)
    7350             :  *     if _dict is not None:
    7351             :  *         state += (_dict,)             # <<<<<<<<<<<<<<
    7352             :  *         use_setstate = True
    7353             :  *     else:
    7354             :  */
    7355           0 :     __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 8, __pyx_L1_error)
    7356           0 :     __Pyx_GOTREF(__pyx_t_1);
    7357           0 :     __Pyx_INCREF(__pyx_v__dict);
    7358           0 :     __Pyx_GIVEREF(__pyx_v__dict);
    7359           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict)) __PYX_ERR(1, 8, __pyx_L1_error);
    7360           0 :     __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 8, __pyx_L1_error)
    7361           0 :     __Pyx_GOTREF(__pyx_t_3);
    7362           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    7363           0 :     __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3));
    7364           0 :     __pyx_t_3 = 0;
    7365             : 
    7366             :     /* "(tree fragment)":9
    7367             :  *     if _dict is not None:
    7368             :  *         state += (_dict,)
    7369             :  *         use_setstate = True             # <<<<<<<<<<<<<<
    7370             :  *     else:
    7371             :  *         use_setstate = self.name is not None
    7372             :  */
    7373           0 :     __pyx_v_use_setstate = 1;
    7374             : 
    7375             :     /* "(tree fragment)":7
    7376             :  *     state = (self.name,)
    7377             :  *     _dict = getattr(self, '__dict__', None)
    7378             :  *     if _dict is not None:             # <<<<<<<<<<<<<<
    7379             :  *         state += (_dict,)
    7380             :  *         use_setstate = True
    7381             :  */
    7382           0 :     goto __pyx_L3;
    7383             :   }
    7384             : 
    7385             :   /* "(tree fragment)":11
    7386             :  *         use_setstate = True
    7387             :  *     else:
    7388             :  *         use_setstate = self.name is not None             # <<<<<<<<<<<<<<
    7389             :  *     if use_setstate:
    7390             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, None), state
    7391             :  */
    7392             :   /*else*/ {
    7393           0 :     __pyx_t_2 = (__pyx_v_self->name != Py_None);
    7394           0 :     __pyx_v_use_setstate = __pyx_t_2;
    7395             :   }
    7396           0 :   __pyx_L3:;
    7397             : 
    7398             :   /* "(tree fragment)":12
    7399             :  *     else:
    7400             :  *         use_setstate = self.name is not None
    7401             :  *     if use_setstate:             # <<<<<<<<<<<<<<
    7402             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, None), state
    7403             :  *     else:
    7404             :  */
    7405           0 :   if (__pyx_v_use_setstate) {
    7406             : 
    7407             :     /* "(tree fragment)":13
    7408             :  *         use_setstate = self.name is not None
    7409             :  *     if use_setstate:
    7410             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, None), state             # <<<<<<<<<<<<<<
    7411             :  *     else:
    7412             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, state)
    7413             :  */
    7414           0 :     __Pyx_XDECREF(__pyx_r);
    7415           0 :     __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Enum); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 13, __pyx_L1_error)
    7416           0 :     __Pyx_GOTREF(__pyx_t_3);
    7417           0 :     __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error)
    7418           0 :     __Pyx_GOTREF(__pyx_t_1);
    7419           0 :     __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    7420           0 :     __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    7421           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))))) __PYX_ERR(1, 13, __pyx_L1_error);
    7422           0 :     __Pyx_INCREF(__pyx_int_136983863);
    7423           0 :     __Pyx_GIVEREF(__pyx_int_136983863);
    7424           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_136983863)) __PYX_ERR(1, 13, __pyx_L1_error);
    7425           0 :     __Pyx_INCREF(Py_None);
    7426           0 :     __Pyx_GIVEREF(Py_None);
    7427           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None)) __PYX_ERR(1, 13, __pyx_L1_error);
    7428           0 :     __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 13, __pyx_L1_error)
    7429           0 :     __Pyx_GOTREF(__pyx_t_4);
    7430           0 :     __Pyx_GIVEREF(__pyx_t_3);
    7431           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3)) __PYX_ERR(1, 13, __pyx_L1_error);
    7432           0 :     __Pyx_GIVEREF(__pyx_t_1);
    7433           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error);
    7434           0 :     __Pyx_INCREF(__pyx_v_state);
    7435           0 :     __Pyx_GIVEREF(__pyx_v_state);
    7436           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state)) __PYX_ERR(1, 13, __pyx_L1_error);
    7437           0 :     __pyx_t_3 = 0;
    7438           0 :     __pyx_t_1 = 0;
    7439           0 :     __pyx_r = __pyx_t_4;
    7440           0 :     __pyx_t_4 = 0;
    7441           0 :     goto __pyx_L0;
    7442             : 
    7443             :     /* "(tree fragment)":12
    7444             :  *     else:
    7445             :  *         use_setstate = self.name is not None
    7446             :  *     if use_setstate:             # <<<<<<<<<<<<<<
    7447             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, None), state
    7448             :  *     else:
    7449             :  */
    7450             :   }
    7451             : 
    7452             :   /* "(tree fragment)":15
    7453             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, None), state
    7454             :  *     else:
    7455             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, state)             # <<<<<<<<<<<<<<
    7456             :  * def __setstate_cython__(self, __pyx_state):
    7457             :  *     __pyx_unpickle_Enum__set_state(self, __pyx_state)
    7458             :  */
    7459             :   /*else*/ {
    7460           0 :     __Pyx_XDECREF(__pyx_r);
    7461           0 :     __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Enum); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 15, __pyx_L1_error)
    7462           0 :     __Pyx_GOTREF(__pyx_t_4);
    7463           0 :     __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error)
    7464           0 :     __Pyx_GOTREF(__pyx_t_1);
    7465           0 :     __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    7466           0 :     __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    7467           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))))) __PYX_ERR(1, 15, __pyx_L1_error);
    7468           0 :     __Pyx_INCREF(__pyx_int_136983863);
    7469           0 :     __Pyx_GIVEREF(__pyx_int_136983863);
    7470           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_136983863)) __PYX_ERR(1, 15, __pyx_L1_error);
    7471           0 :     __Pyx_INCREF(__pyx_v_state);
    7472           0 :     __Pyx_GIVEREF(__pyx_v_state);
    7473           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state)) __PYX_ERR(1, 15, __pyx_L1_error);
    7474           0 :     __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 15, __pyx_L1_error)
    7475           0 :     __Pyx_GOTREF(__pyx_t_3);
    7476           0 :     __Pyx_GIVEREF(__pyx_t_4);
    7477           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4)) __PYX_ERR(1, 15, __pyx_L1_error);
    7478           0 :     __Pyx_GIVEREF(__pyx_t_1);
    7479           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error);
    7480           0 :     __pyx_t_4 = 0;
    7481           0 :     __pyx_t_1 = 0;
    7482           0 :     __pyx_r = __pyx_t_3;
    7483           0 :     __pyx_t_3 = 0;
    7484           0 :     goto __pyx_L0;
    7485             :   }
    7486             : 
    7487             :   /* "(tree fragment)":1
    7488             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
    7489             :  *     cdef tuple state
    7490             :  *     cdef object _dict
    7491             :  */
    7492             : 
    7493             :   /* function exit code */
    7494           0 :   __pyx_L1_error:;
    7495           0 :   __Pyx_XDECREF(__pyx_t_1);
    7496           0 :   __Pyx_XDECREF(__pyx_t_3);
    7497           0 :   __Pyx_XDECREF(__pyx_t_4);
    7498           0 :   __Pyx_AddTraceback("View.MemoryView.Enum.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7499           0 :   __pyx_r = NULL;
    7500           0 :   __pyx_L0:;
    7501           0 :   __Pyx_XDECREF(__pyx_v_state);
    7502           0 :   __Pyx_XDECREF(__pyx_v__dict);
    7503           0 :   __Pyx_XGIVEREF(__pyx_r);
    7504           0 :   __Pyx_RefNannyFinishContext();
    7505           0 :   return __pyx_r;
    7506             : }
    7507             : 
    7508             : /* "(tree fragment)":16
    7509             :  *     else:
    7510             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, state)
    7511             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
    7512             :  *     __pyx_unpickle_Enum__set_state(self, __pyx_state)
    7513             :  */
    7514             : 
    7515             : /* Python wrapper */
    7516             : static PyObject *__pyx_pw___pyx_MemviewEnum_3__setstate_cython__(PyObject *__pyx_v_self, 
    7517             : #if CYTHON_METH_FASTCALL
    7518             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    7519             : #else
    7520             : PyObject *__pyx_args, PyObject *__pyx_kwds
    7521             : #endif
    7522             : ); /*proto*/
    7523           0 : static PyObject *__pyx_pw___pyx_MemviewEnum_3__setstate_cython__(PyObject *__pyx_v_self, 
    7524             : #if CYTHON_METH_FASTCALL
    7525             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
    7526             : #else
    7527             : PyObject *__pyx_args, PyObject *__pyx_kwds
    7528             : #endif
    7529             : ) {
    7530           0 :   PyObject *__pyx_v___pyx_state = 0;
    7531             :   #if !CYTHON_METH_FASTCALL
    7532             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    7533             :   #endif
    7534           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    7535           0 :   PyObject* values[1] = {0};
    7536           0 :   int __pyx_lineno = 0;
    7537           0 :   const char *__pyx_filename = NULL;
    7538           0 :   int __pyx_clineno = 0;
    7539           0 :   PyObject *__pyx_r = 0;
    7540             :   __Pyx_RefNannyDeclarations
    7541           0 :   __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
    7542             :   #if !CYTHON_METH_FASTCALL
    7543             :   #if CYTHON_ASSUME_SAFE_MACROS
    7544             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    7545             :   #else
    7546             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
    7547             :   #endif
    7548             :   #endif
    7549           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
    7550             :   {
    7551           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_state,0};
    7552           0 :     if (__pyx_kwds) {
    7553           0 :       Py_ssize_t kw_args;
    7554           0 :       switch (__pyx_nargs) {
    7555           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
    7556           0 :         CYTHON_FALLTHROUGH;
    7557           0 :         case  0: break;
    7558           0 :         default: goto __pyx_L5_argtuple_error;
    7559             :       }
    7560           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
    7561           0 :       switch (__pyx_nargs) {
    7562             :         case  0:
    7563           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_state)) != 0)) {
    7564           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
    7565           0 :           kw_args--;
    7566             :         }
    7567           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 16, __pyx_L3_error)
    7568           0 :         else goto __pyx_L5_argtuple_error;
    7569             :       }
    7570           0 :       if (unlikely(kw_args > 0)) {
    7571           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
    7572           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__setstate_cython__") < 0)) __PYX_ERR(1, 16, __pyx_L3_error)
    7573             :       }
    7574           0 :     } else if (unlikely(__pyx_nargs != 1)) {
    7575           0 :       goto __pyx_L5_argtuple_error;
    7576             :     } else {
    7577           0 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
    7578             :     }
    7579           0 :     __pyx_v___pyx_state = values[0];
    7580             :   }
    7581           0 :   goto __pyx_L6_skip;
    7582           0 :   __pyx_L5_argtuple_error:;
    7583           0 :   __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, __pyx_nargs); __PYX_ERR(1, 16, __pyx_L3_error)
    7584           0 :   __pyx_L6_skip:;
    7585           0 :   goto __pyx_L4_argument_unpacking_done;
    7586           0 :   __pyx_L3_error:;
    7587             :   {
    7588           0 :     Py_ssize_t __pyx_temp;
    7589           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7590             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
    7591             :     }
    7592             :   }
    7593           0 :   __Pyx_AddTraceback("View.MemoryView.Enum.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7594           0 :   __Pyx_RefNannyFinishContext();
    7595           0 :   return NULL;
    7596           0 :   __pyx_L4_argument_unpacking_done:;
    7597           0 :   __pyx_r = __pyx_pf___pyx_MemviewEnum_2__setstate_cython__(((struct __pyx_MemviewEnum_obj *)__pyx_v_self), __pyx_v___pyx_state);
    7598             : 
    7599             :   /* function exit code */
    7600             :   {
    7601           0 :     Py_ssize_t __pyx_temp;
    7602           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7603             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
    7604             :     }
    7605             :   }
    7606             :   __Pyx_RefNannyFinishContext();
    7607             :   return __pyx_r;
    7608             : }
    7609             : 
    7610           0 : static PyObject *__pyx_pf___pyx_MemviewEnum_2__setstate_cython__(struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
    7611           0 :   PyObject *__pyx_r = NULL;
    7612             :   __Pyx_RefNannyDeclarations
    7613           0 :   PyObject *__pyx_t_1 = NULL;
    7614           0 :   int __pyx_lineno = 0;
    7615           0 :   const char *__pyx_filename = NULL;
    7616           0 :   int __pyx_clineno = 0;
    7617           0 :   __Pyx_RefNannySetupContext("__setstate_cython__", 1);
    7618             : 
    7619             :   /* "(tree fragment)":17
    7620             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, state)
    7621             :  * def __setstate_cython__(self, __pyx_state):
    7622             :  *     __pyx_unpickle_Enum__set_state(self, __pyx_state)             # <<<<<<<<<<<<<<
    7623             :  */
    7624           0 :   if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None) || __Pyx_RaiseUnexpectedTypeError("tuple", __pyx_v___pyx_state))) __PYX_ERR(1, 17, __pyx_L1_error)
    7625           0 :   __pyx_t_1 = __pyx_unpickle_Enum__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 17, __pyx_L1_error)
    7626           0 :   __Pyx_GOTREF(__pyx_t_1);
    7627           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    7628             : 
    7629             :   /* "(tree fragment)":16
    7630             :  *     else:
    7631             :  *         return __pyx_unpickle_Enum, (type(self), 0x82a3537, state)
    7632             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
    7633             :  *     __pyx_unpickle_Enum__set_state(self, __pyx_state)
    7634             :  */
    7635             : 
    7636             :   /* function exit code */
    7637           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    7638           0 :   goto __pyx_L0;
    7639           0 :   __pyx_L1_error:;
    7640           0 :   __Pyx_XDECREF(__pyx_t_1);
    7641           0 :   __Pyx_AddTraceback("View.MemoryView.Enum.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7642           0 :   __pyx_r = NULL;
    7643           0 :   __pyx_L0:;
    7644           0 :   __Pyx_XGIVEREF(__pyx_r);
    7645           0 :   __Pyx_RefNannyFinishContext();
    7646           0 :   return __pyx_r;
    7647             : }
    7648             : 
    7649             : /* "View.MemoryView":349
    7650             :  *     cdef __Pyx_TypeInfo *typeinfo
    7651             :  * 
    7652             :  *     def __cinit__(memoryview self, object obj, int flags, bint dtype_is_object=False):             # <<<<<<<<<<<<<<
    7653             :  *         self.obj = obj
    7654             :  *         self.flags = flags
    7655             :  */
    7656             : 
    7657             : /* Python wrapper */
    7658             : static int __pyx_memoryview___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
    7659           0 : static int __pyx_memoryview___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
    7660           0 :   PyObject *__pyx_v_obj = 0;
    7661           0 :   int __pyx_v_flags;
    7662           0 :   int __pyx_v_dtype_is_object;
    7663           0 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
    7664           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    7665           0 :   PyObject* values[3] = {0,0,0};
    7666           0 :   int __pyx_lineno = 0;
    7667           0 :   const char *__pyx_filename = NULL;
    7668           0 :   int __pyx_clineno = 0;
    7669           0 :   int __pyx_r;
    7670             :   __Pyx_RefNannyDeclarations
    7671           0 :   __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0);
    7672             :   #if CYTHON_ASSUME_SAFE_MACROS
    7673           0 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
    7674             :   #else
    7675             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return -1;
    7676             :   #endif
    7677           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    7678             :   {
    7679           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_flags,&__pyx_n_s_dtype_is_object,0};
    7680           0 :     if (__pyx_kwds) {
    7681           0 :       Py_ssize_t kw_args;
    7682           0 :       switch (__pyx_nargs) {
    7683           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
    7684           0 :         CYTHON_FALLTHROUGH;
    7685           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
    7686           0 :         CYTHON_FALLTHROUGH;
    7687           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    7688           0 :         CYTHON_FALLTHROUGH;
    7689           0 :         case  0: break;
    7690           0 :         default: goto __pyx_L5_argtuple_error;
    7691             :       }
    7692           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
    7693           0 :       switch (__pyx_nargs) {
    7694           0 :         case  0:
    7695           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_obj)) != 0)) {
    7696           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
    7697           0 :           kw_args--;
    7698             :         }
    7699           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 349, __pyx_L3_error)
    7700           0 :         else goto __pyx_L5_argtuple_error;
    7701           0 :         CYTHON_FALLTHROUGH;
    7702             :         case  1:
    7703           0 :         if (likely((values[1] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_flags)) != 0)) {
    7704           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[1]);
    7705           0 :           kw_args--;
    7706             :         }
    7707           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 349, __pyx_L3_error)
    7708             :         else {
    7709           0 :           __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 2, 3, 1); __PYX_ERR(1, 349, __pyx_L3_error)
    7710             :         }
    7711           0 :         CYTHON_FALLTHROUGH;
    7712             :         case  2:
    7713           0 :         if (kw_args > 0) {
    7714           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_dtype_is_object);
    7715           0 :           if (value) { values[2] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
    7716           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 349, __pyx_L3_error)
    7717             :         }
    7718             :       }
    7719           0 :       if (unlikely(kw_args > 0)) {
    7720           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
    7721           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__cinit__") < 0)) __PYX_ERR(1, 349, __pyx_L3_error)
    7722             :       }
    7723             :     } else {
    7724           0 :       switch (__pyx_nargs) {
    7725           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
    7726           0 :         CYTHON_FALLTHROUGH;
    7727           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
    7728           0 :         values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
    7729           0 :         break;
    7730           0 :         default: goto __pyx_L5_argtuple_error;
    7731             :       }
    7732             :     }
    7733           0 :     __pyx_v_obj = values[0];
    7734           0 :     __pyx_v_flags = __Pyx_PyInt_As_int(values[1]); if (unlikely((__pyx_v_flags == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 349, __pyx_L3_error)
    7735           0 :     if (values[2]) {
    7736           0 :       __pyx_v_dtype_is_object = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_dtype_is_object == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 349, __pyx_L3_error)
    7737             :     } else {
    7738             :       __pyx_v_dtype_is_object = ((int)0);
    7739             :     }
    7740             :   }
    7741           0 :   goto __pyx_L6_skip;
    7742           0 :   __pyx_L5_argtuple_error:;
    7743           0 :   __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 2, 3, __pyx_nargs); __PYX_ERR(1, 349, __pyx_L3_error)
    7744           0 :   __pyx_L6_skip:;
    7745           0 :   goto __pyx_L4_argument_unpacking_done;
    7746           0 :   __pyx_L3_error:;
    7747             :   {
    7748           0 :     Py_ssize_t __pyx_temp;
    7749           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7750             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    7751             :     }
    7752             :   }
    7753           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    7754           0 :   __Pyx_RefNannyFinishContext();
    7755           0 :   return -1;
    7756           0 :   __pyx_L4_argument_unpacking_done:;
    7757           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(((struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_obj, __pyx_v_flags, __pyx_v_dtype_is_object);
    7758             : 
    7759             :   /* function exit code */
    7760             :   {
    7761           0 :     Py_ssize_t __pyx_temp;
    7762           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
    7763             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
    7764             :     }
    7765             :   }
    7766             :   __Pyx_RefNannyFinishContext();
    7767             :   return __pyx_r;
    7768             : }
    7769             : 
    7770           0 : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj, int __pyx_v_flags, int __pyx_v_dtype_is_object) {
    7771           0 :   int __pyx_r;
    7772             :   __Pyx_RefNannyDeclarations
    7773           0 :   int __pyx_t_1;
    7774           0 :   int __pyx_t_2;
    7775           0 :   int __pyx_t_3;
    7776           0 :   Py_intptr_t __pyx_t_4;
    7777           0 :   size_t __pyx_t_5;
    7778           0 :   int __pyx_lineno = 0;
    7779           0 :   const char *__pyx_filename = NULL;
    7780           0 :   int __pyx_clineno = 0;
    7781           0 :   __Pyx_RefNannySetupContext("__cinit__", 1);
    7782             : 
    7783             :   /* "View.MemoryView":350
    7784             :  * 
    7785             :  *     def __cinit__(memoryview self, object obj, int flags, bint dtype_is_object=False):
    7786             :  *         self.obj = obj             # <<<<<<<<<<<<<<
    7787             :  *         self.flags = flags
    7788             :  *         if type(self) is memoryview or obj is not None:
    7789             :  */
    7790           0 :   __Pyx_INCREF(__pyx_v_obj);
    7791           0 :   __Pyx_GIVEREF(__pyx_v_obj);
    7792           0 :   __Pyx_GOTREF(__pyx_v_self->obj);
    7793           0 :   __Pyx_DECREF(__pyx_v_self->obj);
    7794           0 :   __pyx_v_self->obj = __pyx_v_obj;
    7795             : 
    7796             :   /* "View.MemoryView":351
    7797             :  *     def __cinit__(memoryview self, object obj, int flags, bint dtype_is_object=False):
    7798             :  *         self.obj = obj
    7799             :  *         self.flags = flags             # <<<<<<<<<<<<<<
    7800             :  *         if type(self) is memoryview or obj is not None:
    7801             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7802             :  */
    7803           0 :   __pyx_v_self->flags = __pyx_v_flags;
    7804             : 
    7805             :   /* "View.MemoryView":352
    7806             :  *         self.obj = obj
    7807             :  *         self.flags = flags
    7808             :  *         if type(self) is memoryview or obj is not None:             # <<<<<<<<<<<<<<
    7809             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7810             :  *             if <PyObject *> self.view.obj == NULL:
    7811             :  */
    7812           0 :   __pyx_t_2 = (((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))) == ((PyObject *)__pyx_memoryview_type));
    7813           0 :   if (!__pyx_t_2) {
    7814           0 :   } else {
    7815           0 :     __pyx_t_1 = __pyx_t_2;
    7816           0 :     goto __pyx_L4_bool_binop_done;
    7817             :   }
    7818           0 :   __pyx_t_2 = (__pyx_v_obj != Py_None);
    7819           0 :   __pyx_t_1 = __pyx_t_2;
    7820           0 :   __pyx_L4_bool_binop_done:;
    7821           0 :   if (__pyx_t_1) {
    7822             : 
    7823             :     /* "View.MemoryView":353
    7824             :  *         self.flags = flags
    7825             :  *         if type(self) is memoryview or obj is not None:
    7826             :  *             __Pyx_GetBuffer(obj, &self.view, flags)             # <<<<<<<<<<<<<<
    7827             :  *             if <PyObject *> self.view.obj == NULL:
    7828             :  *                 (<__pyx_buffer *> &self.view).obj = Py_None
    7829             :  */
    7830           0 :     __pyx_t_3 = __Pyx_GetBuffer(__pyx_v_obj, (&__pyx_v_self->view), __pyx_v_flags); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 353, __pyx_L1_error)
    7831             : 
    7832             :     /* "View.MemoryView":354
    7833             :  *         if type(self) is memoryview or obj is not None:
    7834             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7835             :  *             if <PyObject *> self.view.obj == NULL:             # <<<<<<<<<<<<<<
    7836             :  *                 (<__pyx_buffer *> &self.view).obj = Py_None
    7837             :  *                 Py_INCREF(Py_None)
    7838             :  */
    7839           0 :     __pyx_t_1 = (((PyObject *)__pyx_v_self->view.obj) == NULL);
    7840           0 :     if (__pyx_t_1) {
    7841             : 
    7842             :       /* "View.MemoryView":355
    7843             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7844             :  *             if <PyObject *> self.view.obj == NULL:
    7845             :  *                 (<__pyx_buffer *> &self.view).obj = Py_None             # <<<<<<<<<<<<<<
    7846             :  *                 Py_INCREF(Py_None)
    7847             :  * 
    7848             :  */
    7849           0 :       ((Py_buffer *)(&__pyx_v_self->view))->obj = Py_None;
    7850             : 
    7851             :       /* "View.MemoryView":356
    7852             :  *             if <PyObject *> self.view.obj == NULL:
    7853             :  *                 (<__pyx_buffer *> &self.view).obj = Py_None
    7854             :  *                 Py_INCREF(Py_None)             # <<<<<<<<<<<<<<
    7855             :  * 
    7856             :  *         if not __PYX_CYTHON_ATOMICS_ENABLED():
    7857             :  */
    7858           0 :       Py_INCREF(Py_None);
    7859             : 
    7860             :       /* "View.MemoryView":354
    7861             :  *         if type(self) is memoryview or obj is not None:
    7862             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7863             :  *             if <PyObject *> self.view.obj == NULL:             # <<<<<<<<<<<<<<
    7864             :  *                 (<__pyx_buffer *> &self.view).obj = Py_None
    7865             :  *                 Py_INCREF(Py_None)
    7866             :  */
    7867             :     }
    7868             : 
    7869             :     /* "View.MemoryView":352
    7870             :  *         self.obj = obj
    7871             :  *         self.flags = flags
    7872             :  *         if type(self) is memoryview or obj is not None:             # <<<<<<<<<<<<<<
    7873             :  *             __Pyx_GetBuffer(obj, &self.view, flags)
    7874             :  *             if <PyObject *> self.view.obj == NULL:
    7875             :  */
    7876             :   }
    7877             : 
    7878             :   /* "View.MemoryView":358
    7879             :  *                 Py_INCREF(Py_None)
    7880             :  * 
    7881             :  *         if not __PYX_CYTHON_ATOMICS_ENABLED():             # <<<<<<<<<<<<<<
    7882             :  *             global __pyx_memoryview_thread_locks_used
    7883             :  *             if __pyx_memoryview_thread_locks_used < 8:
    7884             :  */
    7885           0 :   __pyx_t_1 = (!__PYX_CYTHON_ATOMICS_ENABLED());
    7886           0 :   if (__pyx_t_1) {
    7887             : 
    7888             :     /* "View.MemoryView":360
    7889             :  *         if not __PYX_CYTHON_ATOMICS_ENABLED():
    7890             :  *             global __pyx_memoryview_thread_locks_used
    7891             :  *             if __pyx_memoryview_thread_locks_used < 8:             # <<<<<<<<<<<<<<
    7892             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]
    7893             :  *                 __pyx_memoryview_thread_locks_used += 1
    7894             :  */
    7895             :     __pyx_t_1 = (__pyx_memoryview_thread_locks_used < 8);
    7896             :     if (__pyx_t_1) {
    7897             : 
    7898             :       /* "View.MemoryView":361
    7899             :  *             global __pyx_memoryview_thread_locks_used
    7900             :  *             if __pyx_memoryview_thread_locks_used < 8:
    7901             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]             # <<<<<<<<<<<<<<
    7902             :  *                 __pyx_memoryview_thread_locks_used += 1
    7903             :  *             if self.lock is NULL:
    7904             :  */
    7905             :       __pyx_v_self->lock = (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]);
    7906             : 
    7907             :       /* "View.MemoryView":362
    7908             :  *             if __pyx_memoryview_thread_locks_used < 8:
    7909             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]
    7910             :  *                 __pyx_memoryview_thread_locks_used += 1             # <<<<<<<<<<<<<<
    7911             :  *             if self.lock is NULL:
    7912             :  *                 self.lock = PyThread_allocate_lock()
    7913             :  */
    7914             :       __pyx_memoryview_thread_locks_used = (__pyx_memoryview_thread_locks_used + 1);
    7915             : 
    7916             :       /* "View.MemoryView":360
    7917             :  *         if not __PYX_CYTHON_ATOMICS_ENABLED():
    7918             :  *             global __pyx_memoryview_thread_locks_used
    7919             :  *             if __pyx_memoryview_thread_locks_used < 8:             # <<<<<<<<<<<<<<
    7920             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]
    7921             :  *                 __pyx_memoryview_thread_locks_used += 1
    7922             :  */
    7923             :     }
    7924             : 
    7925             :     /* "View.MemoryView":363
    7926             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]
    7927             :  *                 __pyx_memoryview_thread_locks_used += 1
    7928             :  *             if self.lock is NULL:             # <<<<<<<<<<<<<<
    7929             :  *                 self.lock = PyThread_allocate_lock()
    7930             :  *                 if self.lock is NULL:
    7931             :  */
    7932             :     __pyx_t_1 = (__pyx_v_self->lock == NULL);
    7933             :     if (__pyx_t_1) {
    7934             : 
    7935             :       /* "View.MemoryView":364
    7936             :  *                 __pyx_memoryview_thread_locks_used += 1
    7937             :  *             if self.lock is NULL:
    7938             :  *                 self.lock = PyThread_allocate_lock()             # <<<<<<<<<<<<<<
    7939             :  *                 if self.lock is NULL:
    7940             :  *                     raise MemoryError
    7941             :  */
    7942             :       __pyx_v_self->lock = PyThread_allocate_lock();
    7943             : 
    7944             :       /* "View.MemoryView":365
    7945             :  *             if self.lock is NULL:
    7946             :  *                 self.lock = PyThread_allocate_lock()
    7947             :  *                 if self.lock is NULL:             # <<<<<<<<<<<<<<
    7948             :  *                     raise MemoryError
    7949             :  * 
    7950             :  */
    7951             :       __pyx_t_1 = (__pyx_v_self->lock == NULL);
    7952             :       if (unlikely(__pyx_t_1)) {
    7953             : 
    7954             :         /* "View.MemoryView":366
    7955             :  *                 self.lock = PyThread_allocate_lock()
    7956             :  *                 if self.lock is NULL:
    7957             :  *                     raise MemoryError             # <<<<<<<<<<<<<<
    7958             :  * 
    7959             :  *         if flags & PyBUF_FORMAT:
    7960             :  */
    7961             :         PyErr_NoMemory(); __PYX_ERR(1, 366, __pyx_L1_error)
    7962             : 
    7963             :         /* "View.MemoryView":365
    7964             :  *             if self.lock is NULL:
    7965             :  *                 self.lock = PyThread_allocate_lock()
    7966             :  *                 if self.lock is NULL:             # <<<<<<<<<<<<<<
    7967             :  *                     raise MemoryError
    7968             :  * 
    7969             :  */
    7970             :       }
    7971             : 
    7972             :       /* "View.MemoryView":363
    7973             :  *                 self.lock = __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]
    7974             :  *                 __pyx_memoryview_thread_locks_used += 1
    7975             :  *             if self.lock is NULL:             # <<<<<<<<<<<<<<
    7976             :  *                 self.lock = PyThread_allocate_lock()
    7977             :  *                 if self.lock is NULL:
    7978             :  */
    7979             :     }
    7980             : 
    7981             :     /* "View.MemoryView":358
    7982             :  *                 Py_INCREF(Py_None)
    7983             :  * 
    7984             :  *         if not __PYX_CYTHON_ATOMICS_ENABLED():             # <<<<<<<<<<<<<<
    7985             :  *             global __pyx_memoryview_thread_locks_used
    7986             :  *             if __pyx_memoryview_thread_locks_used < 8:
    7987             :  */
    7988             :   }
    7989             : 
    7990             :   /* "View.MemoryView":368
    7991             :  *                     raise MemoryError
    7992             :  * 
    7993             :  *         if flags & PyBUF_FORMAT:             # <<<<<<<<<<<<<<
    7994             :  *             self.dtype_is_object = (self.view.format[0] == b'O' and self.view.format[1] == b'\0')
    7995             :  *         else:
    7996             :  */
    7997           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
    7998           0 :   if (__pyx_t_1) {
    7999             : 
    8000             :     /* "View.MemoryView":369
    8001             :  * 
    8002             :  *         if flags & PyBUF_FORMAT:
    8003             :  *             self.dtype_is_object = (self.view.format[0] == b'O' and self.view.format[1] == b'\0')             # <<<<<<<<<<<<<<
    8004             :  *         else:
    8005             :  *             self.dtype_is_object = dtype_is_object
    8006             :  */
    8007           0 :     __pyx_t_2 = ((__pyx_v_self->view.format[0]) == 'O');
    8008           0 :     if (__pyx_t_2) {
    8009           0 :     } else {
    8010           0 :       __pyx_t_1 = __pyx_t_2;
    8011           0 :       goto __pyx_L12_bool_binop_done;
    8012             :     }
    8013           0 :     __pyx_t_2 = ((__pyx_v_self->view.format[1]) == '\x00');
    8014           0 :     __pyx_t_1 = __pyx_t_2;
    8015           0 :     __pyx_L12_bool_binop_done:;
    8016           0 :     __pyx_v_self->dtype_is_object = __pyx_t_1;
    8017             : 
    8018             :     /* "View.MemoryView":368
    8019             :  *                     raise MemoryError
    8020             :  * 
    8021             :  *         if flags & PyBUF_FORMAT:             # <<<<<<<<<<<<<<
    8022             :  *             self.dtype_is_object = (self.view.format[0] == b'O' and self.view.format[1] == b'\0')
    8023             :  *         else:
    8024             :  */
    8025           0 :     goto __pyx_L11;
    8026             :   }
    8027             : 
    8028             :   /* "View.MemoryView":371
    8029             :  *             self.dtype_is_object = (self.view.format[0] == b'O' and self.view.format[1] == b'\0')
    8030             :  *         else:
    8031             :  *             self.dtype_is_object = dtype_is_object             # <<<<<<<<<<<<<<
    8032             :  * 
    8033             :  *         assert <Py_intptr_t><void*>(&self.acquisition_count) % sizeof(__pyx_atomic_int_type) == 0
    8034             :  */
    8035             :   /*else*/ {
    8036           0 :     __pyx_v_self->dtype_is_object = __pyx_v_dtype_is_object;
    8037             :   }
    8038           0 :   __pyx_L11:;
    8039             : 
    8040             :   /* "View.MemoryView":373
    8041             :  *             self.dtype_is_object = dtype_is_object
    8042             :  * 
    8043             :  *         assert <Py_intptr_t><void*>(&self.acquisition_count) % sizeof(__pyx_atomic_int_type) == 0             # <<<<<<<<<<<<<<
    8044             :  *         self.typeinfo = NULL
    8045             :  * 
    8046             :  */
    8047             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
    8048           0 :   if (unlikely(__pyx_assertions_enabled())) {
    8049           0 :     __pyx_t_4 = ((Py_intptr_t)((void *)(&__pyx_v_self->acquisition_count)));
    8050           0 :     __pyx_t_5 = (sizeof(__pyx_atomic_int_type));
    8051           0 :     if (unlikely(__pyx_t_5 == 0)) {
    8052             :       PyErr_SetString(PyExc_ZeroDivisionError, "integer division or modulo by zero");
    8053             :       __PYX_ERR(1, 373, __pyx_L1_error)
    8054             :     }
    8055           0 :     __pyx_t_1 = ((__pyx_t_4 % __pyx_t_5) == 0);
    8056           0 :     if (unlikely(!__pyx_t_1)) {
    8057           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, 0, 0, 0);
    8058           0 :       __PYX_ERR(1, 373, __pyx_L1_error)
    8059             :     }
    8060             :   }
    8061             :   #else
    8062             :   if ((1)); else __PYX_ERR(1, 373, __pyx_L1_error)
    8063             :   #endif
    8064             : 
    8065             :   /* "View.MemoryView":374
    8066             :  * 
    8067             :  *         assert <Py_intptr_t><void*>(&self.acquisition_count) % sizeof(__pyx_atomic_int_type) == 0
    8068             :  *         self.typeinfo = NULL             # <<<<<<<<<<<<<<
    8069             :  * 
    8070             :  *     def __dealloc__(memoryview self):
    8071             :  */
    8072           0 :   __pyx_v_self->typeinfo = NULL;
    8073             : 
    8074             :   /* "View.MemoryView":349
    8075             :  *     cdef __Pyx_TypeInfo *typeinfo
    8076             :  * 
    8077             :  *     def __cinit__(memoryview self, object obj, int flags, bint dtype_is_object=False):             # <<<<<<<<<<<<<<
    8078             :  *         self.obj = obj
    8079             :  *         self.flags = flags
    8080             :  */
    8081             : 
    8082             :   /* function exit code */
    8083           0 :   __pyx_r = 0;
    8084           0 :   goto __pyx_L0;
    8085           0 :   __pyx_L1_error:;
    8086           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    8087           0 :   __pyx_r = -1;
    8088           0 :   __pyx_L0:;
    8089           0 :   __Pyx_RefNannyFinishContext();
    8090           0 :   return __pyx_r;
    8091             : }
    8092             : 
    8093             : /* "View.MemoryView":376
    8094             :  *         self.typeinfo = NULL
    8095             :  * 
    8096             :  *     def __dealloc__(memoryview self):             # <<<<<<<<<<<<<<
    8097             :  *         if self.obj is not None:
    8098             :  *             __Pyx_ReleaseBuffer(&self.view)
    8099             :  */
    8100             : 
    8101             : /* Python wrapper */
    8102             : static void __pyx_memoryview___dealloc__(PyObject *__pyx_v_self); /*proto*/
    8103           0 : static void __pyx_memoryview___dealloc__(PyObject *__pyx_v_self) {
    8104           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    8105             :   __Pyx_RefNannyDeclarations
    8106           0 :   __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
    8107           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    8108           0 :   __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(((struct __pyx_memoryview_obj *)__pyx_v_self));
    8109             : 
    8110             :   /* function exit code */
    8111           0 :   __Pyx_RefNannyFinishContext();
    8112             : }
    8113             : 
    8114           0 : static void __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(struct __pyx_memoryview_obj *__pyx_v_self) {
    8115           0 :   int __pyx_v_i;
    8116           0 :   int __pyx_t_1;
    8117           0 :   int __pyx_t_2;
    8118           0 :   int __pyx_t_3;
    8119           0 :   int __pyx_t_4;
    8120           0 :   PyThread_type_lock __pyx_t_5;
    8121           0 :   PyThread_type_lock __pyx_t_6;
    8122             : 
    8123             :   /* "View.MemoryView":377
    8124             :  * 
    8125             :  *     def __dealloc__(memoryview self):
    8126             :  *         if self.obj is not None:             # <<<<<<<<<<<<<<
    8127             :  *             __Pyx_ReleaseBuffer(&self.view)
    8128             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:
    8129             :  */
    8130           0 :   __pyx_t_1 = (__pyx_v_self->obj != Py_None);
    8131           0 :   if (__pyx_t_1) {
    8132             : 
    8133             :     /* "View.MemoryView":378
    8134             :  *     def __dealloc__(memoryview self):
    8135             :  *         if self.obj is not None:
    8136             :  *             __Pyx_ReleaseBuffer(&self.view)             # <<<<<<<<<<<<<<
    8137             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:
    8138             :  * 
    8139             :  */
    8140           0 :     __Pyx_ReleaseBuffer((&__pyx_v_self->view));
    8141             : 
    8142             :     /* "View.MemoryView":377
    8143             :  * 
    8144             :  *     def __dealloc__(memoryview self):
    8145             :  *         if self.obj is not None:             # <<<<<<<<<<<<<<
    8146             :  *             __Pyx_ReleaseBuffer(&self.view)
    8147             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:
    8148             :  */
    8149           0 :     goto __pyx_L3;
    8150             :   }
    8151             : 
    8152             :   /* "View.MemoryView":379
    8153             :  *         if self.obj is not None:
    8154             :  *             __Pyx_ReleaseBuffer(&self.view)
    8155             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:             # <<<<<<<<<<<<<<
    8156             :  * 
    8157             :  *             (<__pyx_buffer *> &self.view).obj = NULL
    8158             :  */
    8159           0 :   __pyx_t_1 = (((Py_buffer *)(&__pyx_v_self->view))->obj == Py_None);
    8160           0 :   if (__pyx_t_1) {
    8161             : 
    8162             :     /* "View.MemoryView":381
    8163             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:
    8164             :  * 
    8165             :  *             (<__pyx_buffer *> &self.view).obj = NULL             # <<<<<<<<<<<<<<
    8166             :  *             Py_DECREF(Py_None)
    8167             :  * 
    8168             :  */
    8169           0 :     ((Py_buffer *)(&__pyx_v_self->view))->obj = NULL;
    8170             : 
    8171             :     /* "View.MemoryView":382
    8172             :  * 
    8173             :  *             (<__pyx_buffer *> &self.view).obj = NULL
    8174             :  *             Py_DECREF(Py_None)             # <<<<<<<<<<<<<<
    8175             :  * 
    8176             :  *         cdef int i
    8177             :  */
    8178           0 :     Py_DECREF(Py_None);
    8179             : 
    8180             :     /* "View.MemoryView":379
    8181             :  *         if self.obj is not None:
    8182             :  *             __Pyx_ReleaseBuffer(&self.view)
    8183             :  *         elif (<__pyx_buffer *> &self.view).obj == Py_None:             # <<<<<<<<<<<<<<
    8184             :  * 
    8185             :  *             (<__pyx_buffer *> &self.view).obj = NULL
    8186             :  */
    8187             :   }
    8188           0 :   __pyx_L3:;
    8189             : 
    8190             :   /* "View.MemoryView":386
    8191             :  *         cdef int i
    8192             :  *         global __pyx_memoryview_thread_locks_used
    8193             :  *         if self.lock != NULL:             # <<<<<<<<<<<<<<
    8194             :  *             for i in range(__pyx_memoryview_thread_locks_used):
    8195             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8196             :  */
    8197           0 :   __pyx_t_1 = (__pyx_v_self->lock != NULL);
    8198           0 :   if (__pyx_t_1) {
    8199             : 
    8200             :     /* "View.MemoryView":387
    8201             :  *         global __pyx_memoryview_thread_locks_used
    8202             :  *         if self.lock != NULL:
    8203             :  *             for i in range(__pyx_memoryview_thread_locks_used):             # <<<<<<<<<<<<<<
    8204             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8205             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8206             :  */
    8207           0 :     __pyx_t_2 = __pyx_memoryview_thread_locks_used;
    8208           0 :     __pyx_t_3 = __pyx_t_2;
    8209           0 :     for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
    8210           0 :       __pyx_v_i = __pyx_t_4;
    8211             : 
    8212             :       /* "View.MemoryView":388
    8213             :  *         if self.lock != NULL:
    8214             :  *             for i in range(__pyx_memoryview_thread_locks_used):
    8215             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:             # <<<<<<<<<<<<<<
    8216             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8217             :  *                     if i != __pyx_memoryview_thread_locks_used:
    8218             :  */
    8219           0 :       __pyx_t_1 = ((__pyx_memoryview_thread_locks[__pyx_v_i]) == __pyx_v_self->lock);
    8220           0 :       if (__pyx_t_1) {
    8221             : 
    8222             :         /* "View.MemoryView":389
    8223             :  *             for i in range(__pyx_memoryview_thread_locks_used):
    8224             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8225             :  *                     __pyx_memoryview_thread_locks_used -= 1             # <<<<<<<<<<<<<<
    8226             :  *                     if i != __pyx_memoryview_thread_locks_used:
    8227             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (
    8228             :  */
    8229           0 :         __pyx_memoryview_thread_locks_used = (__pyx_memoryview_thread_locks_used - 1);
    8230             : 
    8231             :         /* "View.MemoryView":390
    8232             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8233             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8234             :  *                     if i != __pyx_memoryview_thread_locks_used:             # <<<<<<<<<<<<<<
    8235             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (
    8236             :  *                             __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used], __pyx_memoryview_thread_locks[i])
    8237             :  */
    8238           0 :         __pyx_t_1 = (__pyx_v_i != __pyx_memoryview_thread_locks_used);
    8239           0 :         if (__pyx_t_1) {
    8240             : 
    8241             :           /* "View.MemoryView":392
    8242             :  *                     if i != __pyx_memoryview_thread_locks_used:
    8243             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (
    8244             :  *                             __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used], __pyx_memoryview_thread_locks[i])             # <<<<<<<<<<<<<<
    8245             :  *                     break
    8246             :  *             else:
    8247             :  */
    8248           0 :           __pyx_t_5 = (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]);
    8249           0 :           __pyx_t_6 = (__pyx_memoryview_thread_locks[__pyx_v_i]);
    8250             : 
    8251             :           /* "View.MemoryView":391
    8252             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8253             :  *                     if i != __pyx_memoryview_thread_locks_used:
    8254             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (             # <<<<<<<<<<<<<<
    8255             :  *                             __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used], __pyx_memoryview_thread_locks[i])
    8256             :  *                     break
    8257             :  */
    8258           0 :           (__pyx_memoryview_thread_locks[__pyx_v_i]) = __pyx_t_5;
    8259           0 :           (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]) = __pyx_t_6;
    8260             : 
    8261             :           /* "View.MemoryView":390
    8262             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8263             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8264             :  *                     if i != __pyx_memoryview_thread_locks_used:             # <<<<<<<<<<<<<<
    8265             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (
    8266             :  *                             __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used], __pyx_memoryview_thread_locks[i])
    8267             :  */
    8268             :         }
    8269             : 
    8270             :         /* "View.MemoryView":393
    8271             :  *                         __pyx_memoryview_thread_locks[i], __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used] = (
    8272             :  *                             __pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used], __pyx_memoryview_thread_locks[i])
    8273             :  *                     break             # <<<<<<<<<<<<<<
    8274             :  *             else:
    8275             :  *                 PyThread_free_lock(self.lock)
    8276             :  */
    8277           0 :         goto __pyx_L6_break;
    8278             : 
    8279             :         /* "View.MemoryView":388
    8280             :  *         if self.lock != NULL:
    8281             :  *             for i in range(__pyx_memoryview_thread_locks_used):
    8282             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:             # <<<<<<<<<<<<<<
    8283             :  *                     __pyx_memoryview_thread_locks_used -= 1
    8284             :  *                     if i != __pyx_memoryview_thread_locks_used:
    8285             :  */
    8286             :       }
    8287             :     }
    8288             :     /*else*/ {
    8289             : 
    8290             :       /* "View.MemoryView":395
    8291             :  *                     break
    8292             :  *             else:
    8293             :  *                 PyThread_free_lock(self.lock)             # <<<<<<<<<<<<<<
    8294             :  * 
    8295             :  *     cdef char *get_item_pointer(memoryview self, object index) except NULL:
    8296             :  */
    8297           0 :       PyThread_free_lock(__pyx_v_self->lock);
    8298             :     }
    8299           0 :     __pyx_L6_break:;
    8300             : 
    8301             :     /* "View.MemoryView":386
    8302             :  *         cdef int i
    8303             :  *         global __pyx_memoryview_thread_locks_used
    8304             :  *         if self.lock != NULL:             # <<<<<<<<<<<<<<
    8305             :  *             for i in range(__pyx_memoryview_thread_locks_used):
    8306             :  *                 if __pyx_memoryview_thread_locks[i] is self.lock:
    8307             :  */
    8308             :   }
    8309             : 
    8310             :   /* "View.MemoryView":376
    8311             :  *         self.typeinfo = NULL
    8312             :  * 
    8313             :  *     def __dealloc__(memoryview self):             # <<<<<<<<<<<<<<
    8314             :  *         if self.obj is not None:
    8315             :  *             __Pyx_ReleaseBuffer(&self.view)
    8316             :  */
    8317             : 
    8318             :   /* function exit code */
    8319           0 : }
    8320             : 
    8321             : /* "View.MemoryView":397
    8322             :  *                 PyThread_free_lock(self.lock)
    8323             :  * 
    8324             :  *     cdef char *get_item_pointer(memoryview self, object index) except NULL:             # <<<<<<<<<<<<<<
    8325             :  *         cdef Py_ssize_t dim
    8326             :  *         cdef char *itemp = <char *> self.view.buf
    8327             :  */
    8328             : 
    8329           0 : static char *__pyx_memoryview_get_item_pointer(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index) {
    8330           0 :   Py_ssize_t __pyx_v_dim;
    8331           0 :   char *__pyx_v_itemp;
    8332           0 :   PyObject *__pyx_v_idx = NULL;
    8333           0 :   char *__pyx_r;
    8334             :   __Pyx_RefNannyDeclarations
    8335           0 :   Py_ssize_t __pyx_t_1;
    8336           0 :   PyObject *__pyx_t_2 = NULL;
    8337           0 :   Py_ssize_t __pyx_t_3;
    8338           0 :   PyObject *(*__pyx_t_4)(PyObject *);
    8339           0 :   PyObject *__pyx_t_5 = NULL;
    8340           0 :   Py_ssize_t __pyx_t_6;
    8341           0 :   char *__pyx_t_7;
    8342           0 :   int __pyx_lineno = 0;
    8343           0 :   const char *__pyx_filename = NULL;
    8344           0 :   int __pyx_clineno = 0;
    8345           0 :   __Pyx_RefNannySetupContext("get_item_pointer", 1);
    8346             : 
    8347             :   /* "View.MemoryView":399
    8348             :  *     cdef char *get_item_pointer(memoryview self, object index) except NULL:
    8349             :  *         cdef Py_ssize_t dim
    8350             :  *         cdef char *itemp = <char *> self.view.buf             # <<<<<<<<<<<<<<
    8351             :  * 
    8352             :  *         for dim, idx in enumerate(index):
    8353             :  */
    8354           0 :   __pyx_v_itemp = ((char *)__pyx_v_self->view.buf);
    8355             : 
    8356             :   /* "View.MemoryView":401
    8357             :  *         cdef char *itemp = <char *> self.view.buf
    8358             :  * 
    8359             :  *         for dim, idx in enumerate(index):             # <<<<<<<<<<<<<<
    8360             :  *             itemp = pybuffer_index(&self.view, itemp, idx, dim)
    8361             :  * 
    8362             :  */
    8363           0 :   __pyx_t_1 = 0;
    8364           0 :   if (likely(PyList_CheckExact(__pyx_v_index)) || PyTuple_CheckExact(__pyx_v_index)) {
    8365           0 :     __pyx_t_2 = __pyx_v_index; __Pyx_INCREF(__pyx_t_2);
    8366           0 :     __pyx_t_3 = 0;
    8367           0 :     __pyx_t_4 = NULL;
    8368             :   } else {
    8369           0 :     __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_index); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 401, __pyx_L1_error)
    8370           0 :     __Pyx_GOTREF(__pyx_t_2);
    8371           0 :     __pyx_t_4 = __Pyx_PyObject_GetIterNextFunc(__pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 401, __pyx_L1_error)
    8372             :   }
    8373           0 :   for (;;) {
    8374           0 :     if (likely(!__pyx_t_4)) {
    8375           0 :       if (likely(PyList_CheckExact(__pyx_t_2))) {
    8376             :         {
    8377           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_2);
    8378             :           #if !CYTHON_ASSUME_SAFE_MACROS
    8379             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 401, __pyx_L1_error)
    8380             :           #endif
    8381           0 :           if (__pyx_t_3 >= __pyx_temp) break;
    8382             :         }
    8383             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    8384           0 :         __pyx_t_5 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely((0 < 0))) __PYX_ERR(1, 401, __pyx_L1_error)
    8385             :         #else
    8386             :         __pyx_t_5 = __Pyx_PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 401, __pyx_L1_error)
    8387             :         __Pyx_GOTREF(__pyx_t_5);
    8388             :         #endif
    8389             :       } else {
    8390             :         {
    8391           0 :           Py_ssize_t __pyx_temp = __Pyx_PyTuple_GET_SIZE(__pyx_t_2);
    8392             :           #if !CYTHON_ASSUME_SAFE_MACROS
    8393             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 401, __pyx_L1_error)
    8394             :           #endif
    8395           0 :           if (__pyx_t_3 >= __pyx_temp) break;
    8396             :         }
    8397             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    8398           0 :         __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely((0 < 0))) __PYX_ERR(1, 401, __pyx_L1_error)
    8399             :         #else
    8400             :         __pyx_t_5 = __Pyx_PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 401, __pyx_L1_error)
    8401             :         __Pyx_GOTREF(__pyx_t_5);
    8402             :         #endif
    8403             :       }
    8404             :     } else {
    8405           0 :       __pyx_t_5 = __pyx_t_4(__pyx_t_2);
    8406           0 :       if (unlikely(!__pyx_t_5)) {
    8407           0 :         PyObject* exc_type = PyErr_Occurred();
    8408           0 :         if (exc_type) {
    8409           0 :           if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
    8410           0 :           else __PYX_ERR(1, 401, __pyx_L1_error)
    8411             :         }
    8412             :         break;
    8413             :       }
    8414           0 :       __Pyx_GOTREF(__pyx_t_5);
    8415             :     }
    8416           0 :     __Pyx_XDECREF_SET(__pyx_v_idx, __pyx_t_5);
    8417           0 :     __pyx_t_5 = 0;
    8418           0 :     __pyx_v_dim = __pyx_t_1;
    8419           0 :     __pyx_t_1 = (__pyx_t_1 + 1);
    8420             : 
    8421             :     /* "View.MemoryView":402
    8422             :  * 
    8423             :  *         for dim, idx in enumerate(index):
    8424             :  *             itemp = pybuffer_index(&self.view, itemp, idx, dim)             # <<<<<<<<<<<<<<
    8425             :  * 
    8426             :  *         return itemp
    8427             :  */
    8428           0 :     __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_idx); if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 402, __pyx_L1_error)
    8429           0 :     __pyx_t_7 = __pyx_pybuffer_index((&__pyx_v_self->view), __pyx_v_itemp, __pyx_t_6, __pyx_v_dim); if (unlikely(__pyx_t_7 == ((char *)NULL))) __PYX_ERR(1, 402, __pyx_L1_error)
    8430             :     __pyx_v_itemp = __pyx_t_7;
    8431             : 
    8432             :     /* "View.MemoryView":401
    8433             :  *         cdef char *itemp = <char *> self.view.buf
    8434             :  * 
    8435             :  *         for dim, idx in enumerate(index):             # <<<<<<<<<<<<<<
    8436             :  *             itemp = pybuffer_index(&self.view, itemp, idx, dim)
    8437             :  * 
    8438             :  */
    8439             :   }
    8440           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    8441             : 
    8442             :   /* "View.MemoryView":404
    8443             :  *             itemp = pybuffer_index(&self.view, itemp, idx, dim)
    8444             :  * 
    8445             :  *         return itemp             # <<<<<<<<<<<<<<
    8446             :  * 
    8447             :  * 
    8448             :  */
    8449           0 :   __pyx_r = __pyx_v_itemp;
    8450           0 :   goto __pyx_L0;
    8451             : 
    8452             :   /* "View.MemoryView":397
    8453             :  *                 PyThread_free_lock(self.lock)
    8454             :  * 
    8455             :  *     cdef char *get_item_pointer(memoryview self, object index) except NULL:             # <<<<<<<<<<<<<<
    8456             :  *         cdef Py_ssize_t dim
    8457             :  *         cdef char *itemp = <char *> self.view.buf
    8458             :  */
    8459             : 
    8460             :   /* function exit code */
    8461           0 :   __pyx_L1_error:;
    8462           0 :   __Pyx_XDECREF(__pyx_t_2);
    8463           0 :   __Pyx_XDECREF(__pyx_t_5);
    8464           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.get_item_pointer", __pyx_clineno, __pyx_lineno, __pyx_filename);
    8465           0 :   __pyx_r = NULL;
    8466           0 :   __pyx_L0:;
    8467           0 :   __Pyx_XDECREF(__pyx_v_idx);
    8468           0 :   __Pyx_RefNannyFinishContext();
    8469           0 :   return __pyx_r;
    8470             : }
    8471             : 
    8472             : /* "View.MemoryView":407
    8473             :  * 
    8474             :  * 
    8475             :  *     def __getitem__(memoryview self, object index):             # <<<<<<<<<<<<<<
    8476             :  *         if index is Ellipsis:
    8477             :  *             return self
    8478             :  */
    8479             : 
    8480             : /* Python wrapper */
    8481             : static PyObject *__pyx_memoryview___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index); /*proto*/
    8482           0 : static PyObject *__pyx_memoryview___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index) {
    8483           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    8484           0 :   PyObject *__pyx_r = 0;
    8485             :   __Pyx_RefNannyDeclarations
    8486           0 :   __Pyx_RefNannySetupContext("__getitem__ (wrapper)", 0);
    8487           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    8488           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(((struct __pyx_memoryview_obj *)__pyx_v_self), ((PyObject *)__pyx_v_index));
    8489             : 
    8490             :   /* function exit code */
    8491           0 :   __Pyx_RefNannyFinishContext();
    8492           0 :   return __pyx_r;
    8493             : }
    8494             : 
    8495           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index) {
    8496           0 :   PyObject *__pyx_v_have_slices = NULL;
    8497           0 :   PyObject *__pyx_v_indices = NULL;
    8498           0 :   char *__pyx_v_itemp;
    8499           0 :   PyObject *__pyx_r = NULL;
    8500             :   __Pyx_RefNannyDeclarations
    8501           0 :   int __pyx_t_1;
    8502           0 :   PyObject *__pyx_t_2 = NULL;
    8503           0 :   PyObject *__pyx_t_3 = NULL;
    8504           0 :   PyObject *__pyx_t_4 = NULL;
    8505           0 :   char *__pyx_t_5;
    8506           0 :   int __pyx_lineno = 0;
    8507           0 :   const char *__pyx_filename = NULL;
    8508           0 :   int __pyx_clineno = 0;
    8509           0 :   __Pyx_RefNannySetupContext("__getitem__", 1);
    8510             : 
    8511             :   /* "View.MemoryView":408
    8512             :  * 
    8513             :  *     def __getitem__(memoryview self, object index):
    8514             :  *         if index is Ellipsis:             # <<<<<<<<<<<<<<
    8515             :  *             return self
    8516             :  * 
    8517             :  */
    8518           0 :   __pyx_t_1 = (__pyx_v_index == __pyx_builtin_Ellipsis);
    8519           0 :   if (__pyx_t_1) {
    8520             : 
    8521             :     /* "View.MemoryView":409
    8522             :  *     def __getitem__(memoryview self, object index):
    8523             :  *         if index is Ellipsis:
    8524             :  *             return self             # <<<<<<<<<<<<<<
    8525             :  * 
    8526             :  *         have_slices, indices = _unellipsify(index, self.view.ndim)
    8527             :  */
    8528           0 :     __Pyx_XDECREF(__pyx_r);
    8529           0 :     __Pyx_INCREF((PyObject *)__pyx_v_self);
    8530           0 :     __pyx_r = ((PyObject *)__pyx_v_self);
    8531           0 :     goto __pyx_L0;
    8532             : 
    8533             :     /* "View.MemoryView":408
    8534             :  * 
    8535             :  *     def __getitem__(memoryview self, object index):
    8536             :  *         if index is Ellipsis:             # <<<<<<<<<<<<<<
    8537             :  *             return self
    8538             :  * 
    8539             :  */
    8540             :   }
    8541             : 
    8542             :   /* "View.MemoryView":411
    8543             :  *             return self
    8544             :  * 
    8545             :  *         have_slices, indices = _unellipsify(index, self.view.ndim)             # <<<<<<<<<<<<<<
    8546             :  * 
    8547             :  *         cdef char *itemp
    8548             :  */
    8549           0 :   __pyx_t_2 = _unellipsify(__pyx_v_index, __pyx_v_self->view.ndim); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 411, __pyx_L1_error)
    8550           0 :   __Pyx_GOTREF(__pyx_t_2);
    8551           0 :   if (likely(__pyx_t_2 != Py_None)) {
    8552           0 :     PyObject* sequence = __pyx_t_2;
    8553           0 :     Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
    8554           0 :     if (unlikely(size != 2)) {
    8555           0 :       if (size > 2) __Pyx_RaiseTooManyValuesError(2);
    8556           0 :       else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
    8557           0 :       __PYX_ERR(1, 411, __pyx_L1_error)
    8558             :     }
    8559             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    8560           0 :     __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0); 
    8561           0 :     __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1); 
    8562           0 :     __Pyx_INCREF(__pyx_t_3);
    8563           0 :     __Pyx_INCREF(__pyx_t_4);
    8564             :     #else
    8565             :     __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 411, __pyx_L1_error)
    8566             :     __Pyx_GOTREF(__pyx_t_3);
    8567             :     __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 411, __pyx_L1_error)
    8568             :     __Pyx_GOTREF(__pyx_t_4);
    8569             :     #endif
    8570           0 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    8571             :   } else {
    8572           0 :     __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(1, 411, __pyx_L1_error)
    8573             :   }
    8574           0 :   __pyx_v_have_slices = __pyx_t_3;
    8575           0 :   __pyx_t_3 = 0;
    8576           0 :   __pyx_v_indices = __pyx_t_4;
    8577           0 :   __pyx_t_4 = 0;
    8578             : 
    8579             :   /* "View.MemoryView":414
    8580             :  * 
    8581             :  *         cdef char *itemp
    8582             :  *         if have_slices:             # <<<<<<<<<<<<<<
    8583             :  *             return memview_slice(self, indices)
    8584             :  *         else:
    8585             :  */
    8586           0 :   __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_have_slices); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 414, __pyx_L1_error)
    8587           0 :   if (__pyx_t_1) {
    8588             : 
    8589             :     /* "View.MemoryView":415
    8590             :  *         cdef char *itemp
    8591             :  *         if have_slices:
    8592             :  *             return memview_slice(self, indices)             # <<<<<<<<<<<<<<
    8593             :  *         else:
    8594             :  *             itemp = self.get_item_pointer(indices)
    8595             :  */
    8596           0 :     __Pyx_XDECREF(__pyx_r);
    8597           0 :     __pyx_t_2 = ((PyObject *)__pyx_memview_slice(__pyx_v_self, __pyx_v_indices)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 415, __pyx_L1_error)
    8598           0 :     __Pyx_GOTREF(__pyx_t_2);
    8599           0 :     __pyx_r = __pyx_t_2;
    8600           0 :     __pyx_t_2 = 0;
    8601           0 :     goto __pyx_L0;
    8602             : 
    8603             :     /* "View.MemoryView":414
    8604             :  * 
    8605             :  *         cdef char *itemp
    8606             :  *         if have_slices:             # <<<<<<<<<<<<<<
    8607             :  *             return memview_slice(self, indices)
    8608             :  *         else:
    8609             :  */
    8610             :   }
    8611             : 
    8612             :   /* "View.MemoryView":417
    8613             :  *             return memview_slice(self, indices)
    8614             :  *         else:
    8615             :  *             itemp = self.get_item_pointer(indices)             # <<<<<<<<<<<<<<
    8616             :  *             return self.convert_item_to_object(itemp)
    8617             :  * 
    8618             :  */
    8619             :   /*else*/ {
    8620           0 :     __pyx_t_5 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->get_item_pointer(__pyx_v_self, __pyx_v_indices); if (unlikely(__pyx_t_5 == ((char *)NULL))) __PYX_ERR(1, 417, __pyx_L1_error)
    8621           0 :     __pyx_v_itemp = __pyx_t_5;
    8622             : 
    8623             :     /* "View.MemoryView":418
    8624             :  *         else:
    8625             :  *             itemp = self.get_item_pointer(indices)
    8626             :  *             return self.convert_item_to_object(itemp)             # <<<<<<<<<<<<<<
    8627             :  * 
    8628             :  *     def __setitem__(memoryview self, object index, object value):
    8629             :  */
    8630           0 :     __Pyx_XDECREF(__pyx_r);
    8631           0 :     __pyx_t_2 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->convert_item_to_object(__pyx_v_self, __pyx_v_itemp); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 418, __pyx_L1_error)
    8632           0 :     __Pyx_GOTREF(__pyx_t_2);
    8633           0 :     __pyx_r = __pyx_t_2;
    8634           0 :     __pyx_t_2 = 0;
    8635           0 :     goto __pyx_L0;
    8636             :   }
    8637             : 
    8638             :   /* "View.MemoryView":407
    8639             :  * 
    8640             :  * 
    8641             :  *     def __getitem__(memoryview self, object index):             # <<<<<<<<<<<<<<
    8642             :  *         if index is Ellipsis:
    8643             :  *             return self
    8644             :  */
    8645             : 
    8646             :   /* function exit code */
    8647           0 :   __pyx_L1_error:;
    8648           0 :   __Pyx_XDECREF(__pyx_t_2);
    8649           0 :   __Pyx_XDECREF(__pyx_t_3);
    8650           0 :   __Pyx_XDECREF(__pyx_t_4);
    8651           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    8652           0 :   __pyx_r = NULL;
    8653           0 :   __pyx_L0:;
    8654           0 :   __Pyx_XDECREF(__pyx_v_have_slices);
    8655           0 :   __Pyx_XDECREF(__pyx_v_indices);
    8656           0 :   __Pyx_XGIVEREF(__pyx_r);
    8657           0 :   __Pyx_RefNannyFinishContext();
    8658           0 :   return __pyx_r;
    8659             : }
    8660             : 
    8661             : /* "View.MemoryView":420
    8662             :  *             return self.convert_item_to_object(itemp)
    8663             :  * 
    8664             :  *     def __setitem__(memoryview self, object index, object value):             # <<<<<<<<<<<<<<
    8665             :  *         if self.view.readonly:
    8666             :  *             raise TypeError, "Cannot assign to read-only memoryview"
    8667             :  */
    8668             : 
    8669             : /* Python wrapper */
    8670             : static int __pyx_memoryview___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value); /*proto*/
    8671           0 : static int __pyx_memoryview___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
    8672           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
    8673           0 :   int __pyx_r;
    8674             :   __Pyx_RefNannyDeclarations
    8675           0 :   __Pyx_RefNannySetupContext("__setitem__ (wrapper)", 0);
    8676           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
    8677           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(((struct __pyx_memoryview_obj *)__pyx_v_self), ((PyObject *)__pyx_v_index), ((PyObject *)__pyx_v_value));
    8678             : 
    8679             :   /* function exit code */
    8680           0 :   __Pyx_RefNannyFinishContext();
    8681           0 :   return __pyx_r;
    8682             : }
    8683             : 
    8684           0 : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
    8685           0 :   PyObject *__pyx_v_have_slices = NULL;
    8686           0 :   PyObject *__pyx_v_obj = NULL;
    8687           0 :   int __pyx_r;
    8688             :   __Pyx_RefNannyDeclarations
    8689           0 :   PyObject *__pyx_t_1 = NULL;
    8690           0 :   PyObject *__pyx_t_2 = NULL;
    8691           0 :   PyObject *__pyx_t_3 = NULL;
    8692           0 :   int __pyx_t_4;
    8693           0 :   int __pyx_lineno = 0;
    8694           0 :   const char *__pyx_filename = NULL;
    8695           0 :   int __pyx_clineno = 0;
    8696           0 :   __Pyx_RefNannySetupContext("__setitem__", 0);
    8697           0 :   __Pyx_INCREF(__pyx_v_index);
    8698             : 
    8699             :   /* "View.MemoryView":421
    8700             :  * 
    8701             :  *     def __setitem__(memoryview self, object index, object value):
    8702             :  *         if self.view.readonly:             # <<<<<<<<<<<<<<
    8703             :  *             raise TypeError, "Cannot assign to read-only memoryview"
    8704             :  * 
    8705             :  */
    8706           0 :   if (unlikely(__pyx_v_self->view.readonly)) {
    8707             : 
    8708             :     /* "View.MemoryView":422
    8709             :  *     def __setitem__(memoryview self, object index, object value):
    8710             :  *         if self.view.readonly:
    8711             :  *             raise TypeError, "Cannot assign to read-only memoryview"             # <<<<<<<<<<<<<<
    8712             :  * 
    8713             :  *         have_slices, index = _unellipsify(index, self.view.ndim)
    8714             :  */
    8715           0 :     __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_Cannot_assign_to_read_only_memor, 0, 0);
    8716           0 :     __PYX_ERR(1, 422, __pyx_L1_error)
    8717             : 
    8718             :     /* "View.MemoryView":421
    8719             :  * 
    8720             :  *     def __setitem__(memoryview self, object index, object value):
    8721             :  *         if self.view.readonly:             # <<<<<<<<<<<<<<
    8722             :  *             raise TypeError, "Cannot assign to read-only memoryview"
    8723             :  * 
    8724             :  */
    8725             :   }
    8726             : 
    8727             :   /* "View.MemoryView":424
    8728             :  *             raise TypeError, "Cannot assign to read-only memoryview"
    8729             :  * 
    8730             :  *         have_slices, index = _unellipsify(index, self.view.ndim)             # <<<<<<<<<<<<<<
    8731             :  * 
    8732             :  *         if have_slices:
    8733             :  */
    8734           0 :   __pyx_t_1 = _unellipsify(__pyx_v_index, __pyx_v_self->view.ndim); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 424, __pyx_L1_error)
    8735           0 :   __Pyx_GOTREF(__pyx_t_1);
    8736           0 :   if (likely(__pyx_t_1 != Py_None)) {
    8737           0 :     PyObject* sequence = __pyx_t_1;
    8738           0 :     Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
    8739           0 :     if (unlikely(size != 2)) {
    8740           0 :       if (size > 2) __Pyx_RaiseTooManyValuesError(2);
    8741           0 :       else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
    8742           0 :       __PYX_ERR(1, 424, __pyx_L1_error)
    8743             :     }
    8744             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    8745           0 :     __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); 
    8746           0 :     __pyx_t_3 = PyTuple_GET_ITEM(sequence, 1); 
    8747           0 :     __Pyx_INCREF(__pyx_t_2);
    8748           0 :     __Pyx_INCREF(__pyx_t_3);
    8749             :     #else
    8750             :     __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 424, __pyx_L1_error)
    8751             :     __Pyx_GOTREF(__pyx_t_2);
    8752             :     __pyx_t_3 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 424, __pyx_L1_error)
    8753             :     __Pyx_GOTREF(__pyx_t_3);
    8754             :     #endif
    8755           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    8756             :   } else {
    8757           0 :     __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(1, 424, __pyx_L1_error)
    8758             :   }
    8759           0 :   __pyx_v_have_slices = __pyx_t_2;
    8760           0 :   __pyx_t_2 = 0;
    8761           0 :   __Pyx_DECREF_SET(__pyx_v_index, __pyx_t_3);
    8762           0 :   __pyx_t_3 = 0;
    8763             : 
    8764             :   /* "View.MemoryView":426
    8765             :  *         have_slices, index = _unellipsify(index, self.view.ndim)
    8766             :  * 
    8767             :  *         if have_slices:             # <<<<<<<<<<<<<<
    8768             :  *             obj = self.is_slice(value)
    8769             :  *             if obj is not None:
    8770             :  */
    8771           0 :   __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_have_slices); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(1, 426, __pyx_L1_error)
    8772           0 :   if (__pyx_t_4) {
    8773             : 
    8774             :     /* "View.MemoryView":427
    8775             :  * 
    8776             :  *         if have_slices:
    8777             :  *             obj = self.is_slice(value)             # <<<<<<<<<<<<<<
    8778             :  *             if obj is not None:
    8779             :  *                 self.setitem_slice_assignment(self[index], obj)
    8780             :  */
    8781           0 :     __pyx_t_1 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->is_slice(__pyx_v_self, __pyx_v_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 427, __pyx_L1_error)
    8782           0 :     __Pyx_GOTREF(__pyx_t_1);
    8783           0 :     __pyx_v_obj = __pyx_t_1;
    8784           0 :     __pyx_t_1 = 0;
    8785             : 
    8786             :     /* "View.MemoryView":428
    8787             :  *         if have_slices:
    8788             :  *             obj = self.is_slice(value)
    8789             :  *             if obj is not None:             # <<<<<<<<<<<<<<
    8790             :  *                 self.setitem_slice_assignment(self[index], obj)
    8791             :  *             else:
    8792             :  */
    8793           0 :     __pyx_t_4 = (__pyx_v_obj != Py_None);
    8794           0 :     if (__pyx_t_4) {
    8795             : 
    8796             :       /* "View.MemoryView":429
    8797             :  *             obj = self.is_slice(value)
    8798             :  *             if obj is not None:
    8799             :  *                 self.setitem_slice_assignment(self[index], obj)             # <<<<<<<<<<<<<<
    8800             :  *             else:
    8801             :  *                 self.setitem_slice_assign_scalar(self[index], value)
    8802             :  */
    8803           0 :       __pyx_t_1 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_self), __pyx_v_index); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 429, __pyx_L1_error)
    8804           0 :       __Pyx_GOTREF(__pyx_t_1);
    8805           0 :       __pyx_t_3 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_slice_assignment(__pyx_v_self, __pyx_t_1, __pyx_v_obj); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 429, __pyx_L1_error)
    8806           0 :       __Pyx_GOTREF(__pyx_t_3);
    8807           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    8808           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    8809             : 
    8810             :       /* "View.MemoryView":428
    8811             :  *         if have_slices:
    8812             :  *             obj = self.is_slice(value)
    8813             :  *             if obj is not None:             # <<<<<<<<<<<<<<
    8814             :  *                 self.setitem_slice_assignment(self[index], obj)
    8815             :  *             else:
    8816             :  */
    8817           0 :       goto __pyx_L5;
    8818             :     }
    8819             : 
    8820             :     /* "View.MemoryView":431
    8821             :  *                 self.setitem_slice_assignment(self[index], obj)
    8822             :  *             else:
    8823             :  *                 self.setitem_slice_assign_scalar(self[index], value)             # <<<<<<<<<<<<<<
    8824             :  *         else:
    8825             :  *             self.setitem_indexed(index, value)
    8826             :  */
    8827             :     /*else*/ {
    8828           0 :       __pyx_t_3 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_self), __pyx_v_index); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 431, __pyx_L1_error)
    8829           0 :       __Pyx_GOTREF(__pyx_t_3);
    8830           0 :       if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_memoryview_type))))) __PYX_ERR(1, 431, __pyx_L1_error)
    8831           0 :       __pyx_t_1 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_slice_assign_scalar(__pyx_v_self, ((struct __pyx_memoryview_obj *)__pyx_t_3), __pyx_v_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 431, __pyx_L1_error)
    8832           0 :       __Pyx_GOTREF(__pyx_t_1);
    8833           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    8834           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    8835             :     }
    8836           0 :     __pyx_L5:;
    8837             : 
    8838             :     /* "View.MemoryView":426
    8839             :  *         have_slices, index = _unellipsify(index, self.view.ndim)
    8840             :  * 
    8841             :  *         if have_slices:             # <<<<<<<<<<<<<<
    8842             :  *             obj = self.is_slice(value)
    8843             :  *             if obj is not None:
    8844             :  */
    8845           0 :     goto __pyx_L4;
    8846             :   }
    8847             : 
    8848             :   /* "View.MemoryView":433
    8849             :  *                 self.setitem_slice_assign_scalar(self[index], value)
    8850             :  *         else:
    8851             :  *             self.setitem_indexed(index, value)             # <<<<<<<<<<<<<<
    8852             :  * 
    8853             :  *     cdef is_slice(self, obj):
    8854             :  */
    8855             :   /*else*/ {
    8856           0 :     __pyx_t_1 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_indexed(__pyx_v_self, __pyx_v_index, __pyx_v_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 433, __pyx_L1_error)
    8857           0 :     __Pyx_GOTREF(__pyx_t_1);
    8858           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    8859             :   }
    8860           0 :   __pyx_L4:;
    8861             : 
    8862             :   /* "View.MemoryView":420
    8863             :  *             return self.convert_item_to_object(itemp)
    8864             :  * 
    8865             :  *     def __setitem__(memoryview self, object index, object value):             # <<<<<<<<<<<<<<
    8866             :  *         if self.view.readonly:
    8867             :  *             raise TypeError, "Cannot assign to read-only memoryview"
    8868             :  */
    8869             : 
    8870             :   /* function exit code */
    8871           0 :   __pyx_r = 0;
    8872           0 :   goto __pyx_L0;
    8873           0 :   __pyx_L1_error:;
    8874           0 :   __Pyx_XDECREF(__pyx_t_1);
    8875           0 :   __Pyx_XDECREF(__pyx_t_2);
    8876           0 :   __Pyx_XDECREF(__pyx_t_3);
    8877           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__setitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
    8878           0 :   __pyx_r = -1;
    8879           0 :   __pyx_L0:;
    8880           0 :   __Pyx_XDECREF(__pyx_v_have_slices);
    8881           0 :   __Pyx_XDECREF(__pyx_v_obj);
    8882           0 :   __Pyx_XDECREF(__pyx_v_index);
    8883           0 :   __Pyx_RefNannyFinishContext();
    8884           0 :   return __pyx_r;
    8885             : }
    8886             : 
    8887             : /* "View.MemoryView":435
    8888             :  *             self.setitem_indexed(index, value)
    8889             :  * 
    8890             :  *     cdef is_slice(self, obj):             # <<<<<<<<<<<<<<
    8891             :  *         if not isinstance(obj, memoryview):
    8892             :  *             try:
    8893             :  */
    8894             : 
    8895           0 : static PyObject *__pyx_memoryview_is_slice(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj) {
    8896           0 :   PyObject *__pyx_r = NULL;
    8897             :   __Pyx_RefNannyDeclarations
    8898           0 :   int __pyx_t_1;
    8899           0 :   int __pyx_t_2;
    8900           0 :   PyObject *__pyx_t_3 = NULL;
    8901           0 :   PyObject *__pyx_t_4 = NULL;
    8902           0 :   PyObject *__pyx_t_5 = NULL;
    8903           0 :   PyObject *__pyx_t_6 = NULL;
    8904           0 :   PyObject *__pyx_t_7 = NULL;
    8905           0 :   PyObject *__pyx_t_8 = NULL;
    8906           0 :   int __pyx_t_9;
    8907           0 :   int __pyx_lineno = 0;
    8908           0 :   const char *__pyx_filename = NULL;
    8909           0 :   int __pyx_clineno = 0;
    8910           0 :   __Pyx_RefNannySetupContext("is_slice", 0);
    8911           0 :   __Pyx_INCREF(__pyx_v_obj);
    8912             : 
    8913             :   /* "View.MemoryView":436
    8914             :  * 
    8915             :  *     cdef is_slice(self, obj):
    8916             :  *         if not isinstance(obj, memoryview):             # <<<<<<<<<<<<<<
    8917             :  *             try:
    8918             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    8919             :  */
    8920           0 :   __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_obj, __pyx_memoryview_type); 
    8921           0 :   __pyx_t_2 = (!__pyx_t_1);
    8922           0 :   if (__pyx_t_2) {
    8923             : 
    8924             :     /* "View.MemoryView":437
    8925             :  *     cdef is_slice(self, obj):
    8926             :  *         if not isinstance(obj, memoryview):
    8927             :  *             try:             # <<<<<<<<<<<<<<
    8928             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    8929             :  *                                  self.dtype_is_object)
    8930             :  */
    8931             :     {
    8932           0 :       __Pyx_PyThreadState_declare
    8933           0 :       __Pyx_PyThreadState_assign
    8934           0 :       __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_4, &__pyx_t_5);
    8935           0 :       __Pyx_XGOTREF(__pyx_t_3);
    8936           0 :       __Pyx_XGOTREF(__pyx_t_4);
    8937           0 :       __Pyx_XGOTREF(__pyx_t_5);
    8938             :       /*try:*/ {
    8939             : 
    8940             :         /* "View.MemoryView":438
    8941             :  *         if not isinstance(obj, memoryview):
    8942             :  *             try:
    8943             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,             # <<<<<<<<<<<<<<
    8944             :  *                                  self.dtype_is_object)
    8945             :  *             except TypeError:
    8946             :  */
    8947           0 :         __pyx_t_6 = __Pyx_PyInt_From_int(((__pyx_v_self->flags & (~PyBUF_WRITABLE)) | PyBUF_ANY_CONTIGUOUS)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 438, __pyx_L4_error)
    8948           0 :         __Pyx_GOTREF(__pyx_t_6);
    8949             : 
    8950             :         /* "View.MemoryView":439
    8951             :  *             try:
    8952             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    8953             :  *                                  self.dtype_is_object)             # <<<<<<<<<<<<<<
    8954             :  *             except TypeError:
    8955             :  *                 return None
    8956             :  */
    8957           0 :         __pyx_t_7 = __Pyx_PyBool_FromLong(__pyx_v_self->dtype_is_object); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 439, __pyx_L4_error)
    8958           0 :         __Pyx_GOTREF(__pyx_t_7);
    8959             : 
    8960             :         /* "View.MemoryView":438
    8961             :  *         if not isinstance(obj, memoryview):
    8962             :  *             try:
    8963             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,             # <<<<<<<<<<<<<<
    8964             :  *                                  self.dtype_is_object)
    8965             :  *             except TypeError:
    8966             :  */
    8967           0 :         __pyx_t_8 = PyTuple_New(3); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 438, __pyx_L4_error)
    8968           0 :         __Pyx_GOTREF(__pyx_t_8);
    8969           0 :         __Pyx_INCREF(__pyx_v_obj);
    8970           0 :         __Pyx_GIVEREF(__pyx_v_obj);
    8971           0 :         if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_v_obj)) __PYX_ERR(1, 438, __pyx_L4_error);
    8972           0 :         __Pyx_GIVEREF(__pyx_t_6);
    8973           0 :         if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_6)) __PYX_ERR(1, 438, __pyx_L4_error);
    8974           0 :         __Pyx_GIVEREF(__pyx_t_7);
    8975           0 :         if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, 2, __pyx_t_7)) __PYX_ERR(1, 438, __pyx_L4_error);
    8976           0 :         __pyx_t_6 = 0;
    8977           0 :         __pyx_t_7 = 0;
    8978           0 :         __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_8, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 438, __pyx_L4_error)
    8979           0 :         __Pyx_GOTREF(__pyx_t_7);
    8980           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    8981           0 :         __Pyx_DECREF_SET(__pyx_v_obj, __pyx_t_7);
    8982           0 :         __pyx_t_7 = 0;
    8983             : 
    8984             :         /* "View.MemoryView":437
    8985             :  *     cdef is_slice(self, obj):
    8986             :  *         if not isinstance(obj, memoryview):
    8987             :  *             try:             # <<<<<<<<<<<<<<
    8988             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    8989             :  *                                  self.dtype_is_object)
    8990             :  */
    8991             :       }
    8992           0 :       __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
    8993           0 :       __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    8994           0 :       __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
    8995           0 :       goto __pyx_L9_try_end;
    8996           0 :       __pyx_L4_error:;
    8997           0 :       __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
    8998           0 :       __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
    8999           0 :       __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
    9000             : 
    9001             :       /* "View.MemoryView":440
    9002             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    9003             :  *                                  self.dtype_is_object)
    9004             :  *             except TypeError:             # <<<<<<<<<<<<<<
    9005             :  *                 return None
    9006             :  * 
    9007             :  */
    9008           0 :       __pyx_t_9 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_TypeError);
    9009           0 :       if (__pyx_t_9) {
    9010           0 :         __Pyx_AddTraceback("View.MemoryView.memoryview.is_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9011           0 :         if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_8, &__pyx_t_6) < 0) __PYX_ERR(1, 440, __pyx_L6_except_error)
    9012           0 :         __Pyx_XGOTREF(__pyx_t_7);
    9013           0 :         __Pyx_XGOTREF(__pyx_t_8);
    9014           0 :         __Pyx_XGOTREF(__pyx_t_6);
    9015             : 
    9016             :         /* "View.MemoryView":441
    9017             :  *                                  self.dtype_is_object)
    9018             :  *             except TypeError:
    9019             :  *                 return None             # <<<<<<<<<<<<<<
    9020             :  * 
    9021             :  *         return obj
    9022             :  */
    9023           0 :         __Pyx_XDECREF(__pyx_r);
    9024           0 :         __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    9025           0 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    9026           0 :         __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    9027           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    9028           0 :         goto __pyx_L7_except_return;
    9029             :       }
    9030           0 :       goto __pyx_L6_except_error;
    9031             : 
    9032             :       /* "View.MemoryView":437
    9033             :  *     cdef is_slice(self, obj):
    9034             :  *         if not isinstance(obj, memoryview):
    9035             :  *             try:             # <<<<<<<<<<<<<<
    9036             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    9037             :  *                                  self.dtype_is_object)
    9038             :  */
    9039           0 :       __pyx_L6_except_error:;
    9040           0 :       __Pyx_XGIVEREF(__pyx_t_3);
    9041           0 :       __Pyx_XGIVEREF(__pyx_t_4);
    9042           0 :       __Pyx_XGIVEREF(__pyx_t_5);
    9043           0 :       __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
    9044           0 :       goto __pyx_L1_error;
    9045           0 :       __pyx_L7_except_return:;
    9046           0 :       __Pyx_XGIVEREF(__pyx_t_3);
    9047           0 :       __Pyx_XGIVEREF(__pyx_t_4);
    9048           0 :       __Pyx_XGIVEREF(__pyx_t_5);
    9049           0 :       __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
    9050           0 :       goto __pyx_L0;
    9051           0 :       __pyx_L9_try_end:;
    9052             :     }
    9053             : 
    9054             :     /* "View.MemoryView":436
    9055             :  * 
    9056             :  *     cdef is_slice(self, obj):
    9057             :  *         if not isinstance(obj, memoryview):             # <<<<<<<<<<<<<<
    9058             :  *             try:
    9059             :  *                 obj = memoryview(obj, self.flags & ~PyBUF_WRITABLE | PyBUF_ANY_CONTIGUOUS,
    9060             :  */
    9061             :   }
    9062             : 
    9063             :   /* "View.MemoryView":443
    9064             :  *                 return None
    9065             :  * 
    9066             :  *         return obj             # <<<<<<<<<<<<<<
    9067             :  * 
    9068             :  *     cdef setitem_slice_assignment(self, dst, src):
    9069             :  */
    9070           0 :   __Pyx_XDECREF(__pyx_r);
    9071           0 :   __Pyx_INCREF(__pyx_v_obj);
    9072           0 :   __pyx_r = __pyx_v_obj;
    9073           0 :   goto __pyx_L0;
    9074             : 
    9075             :   /* "View.MemoryView":435
    9076             :  *             self.setitem_indexed(index, value)
    9077             :  * 
    9078             :  *     cdef is_slice(self, obj):             # <<<<<<<<<<<<<<
    9079             :  *         if not isinstance(obj, memoryview):
    9080             :  *             try:
    9081             :  */
    9082             : 
    9083             :   /* function exit code */
    9084           0 :   __pyx_L1_error:;
    9085           0 :   __Pyx_XDECREF(__pyx_t_6);
    9086           0 :   __Pyx_XDECREF(__pyx_t_7);
    9087           0 :   __Pyx_XDECREF(__pyx_t_8);
    9088           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.is_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9089           0 :   __pyx_r = 0;
    9090           0 :   __pyx_L0:;
    9091           0 :   __Pyx_XDECREF(__pyx_v_obj);
    9092           0 :   __Pyx_XGIVEREF(__pyx_r);
    9093           0 :   __Pyx_RefNannyFinishContext();
    9094           0 :   return __pyx_r;
    9095             : }
    9096             : 
    9097             : /* "View.MemoryView":445
    9098             :  *         return obj
    9099             :  * 
    9100             :  *     cdef setitem_slice_assignment(self, dst, src):             # <<<<<<<<<<<<<<
    9101             :  *         cdef __Pyx_memviewslice dst_slice
    9102             :  *         cdef __Pyx_memviewslice src_slice
    9103             :  */
    9104             : 
    9105           0 : static PyObject *__pyx_memoryview_setitem_slice_assignment(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_dst, PyObject *__pyx_v_src) {
    9106           0 :   __Pyx_memviewslice __pyx_v_dst_slice;
    9107           0 :   __Pyx_memviewslice __pyx_v_src_slice;
    9108           0 :   __Pyx_memviewslice __pyx_v_msrc;
    9109           0 :   __Pyx_memviewslice __pyx_v_mdst;
    9110           0 :   PyObject *__pyx_r = NULL;
    9111             :   __Pyx_RefNannyDeclarations
    9112           0 :   __Pyx_memviewslice *__pyx_t_1;
    9113           0 :   PyObject *__pyx_t_2 = NULL;
    9114           0 :   int __pyx_t_3;
    9115           0 :   int __pyx_t_4;
    9116           0 :   int __pyx_t_5;
    9117           0 :   int __pyx_lineno = 0;
    9118           0 :   const char *__pyx_filename = NULL;
    9119           0 :   int __pyx_clineno = 0;
    9120           0 :   __Pyx_RefNannySetupContext("setitem_slice_assignment", 1);
    9121             : 
    9122             :   /* "View.MemoryView":448
    9123             :  *         cdef __Pyx_memviewslice dst_slice
    9124             :  *         cdef __Pyx_memviewslice src_slice
    9125             :  *         cdef __Pyx_memviewslice msrc = get_slice_from_memview(src, &src_slice)[0]             # <<<<<<<<<<<<<<
    9126             :  *         cdef __Pyx_memviewslice mdst = get_slice_from_memview(dst, &dst_slice)[0]
    9127             :  * 
    9128             :  */
    9129           0 :   if (!(likely(((__pyx_v_src) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_src, __pyx_memoryview_type))))) __PYX_ERR(1, 448, __pyx_L1_error)
    9130           0 :   __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(((struct __pyx_memoryview_obj *)__pyx_v_src), (&__pyx_v_src_slice)); if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(1, 448, __pyx_L1_error)
    9131           0 :   __pyx_v_msrc = (__pyx_t_1[0]);
    9132             : 
    9133             :   /* "View.MemoryView":449
    9134             :  *         cdef __Pyx_memviewslice src_slice
    9135             :  *         cdef __Pyx_memviewslice msrc = get_slice_from_memview(src, &src_slice)[0]
    9136             :  *         cdef __Pyx_memviewslice mdst = get_slice_from_memview(dst, &dst_slice)[0]             # <<<<<<<<<<<<<<
    9137             :  * 
    9138             :  *         memoryview_copy_contents(msrc, mdst, src.ndim, dst.ndim, self.dtype_is_object)
    9139             :  */
    9140           0 :   if (!(likely(((__pyx_v_dst) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_dst, __pyx_memoryview_type))))) __PYX_ERR(1, 449, __pyx_L1_error)
    9141           0 :   __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(((struct __pyx_memoryview_obj *)__pyx_v_dst), (&__pyx_v_dst_slice)); if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(1, 449, __pyx_L1_error)
    9142           0 :   __pyx_v_mdst = (__pyx_t_1[0]);
    9143             : 
    9144             :   /* "View.MemoryView":451
    9145             :  *         cdef __Pyx_memviewslice mdst = get_slice_from_memview(dst, &dst_slice)[0]
    9146             :  * 
    9147             :  *         memoryview_copy_contents(msrc, mdst, src.ndim, dst.ndim, self.dtype_is_object)             # <<<<<<<<<<<<<<
    9148             :  * 
    9149             :  *     cdef setitem_slice_assign_scalar(self, memoryview dst, value):
    9150             :  */
    9151           0 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_src, __pyx_n_s_ndim); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 451, __pyx_L1_error)
    9152           0 :   __Pyx_GOTREF(__pyx_t_2);
    9153           0 :   __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_t_2); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 451, __pyx_L1_error)
    9154           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    9155           0 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_dst, __pyx_n_s_ndim); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 451, __pyx_L1_error)
    9156           0 :   __Pyx_GOTREF(__pyx_t_2);
    9157           0 :   __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_2); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 451, __pyx_L1_error)
    9158           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    9159           0 :   __pyx_t_5 = __pyx_memoryview_copy_contents(__pyx_v_msrc, __pyx_v_mdst, __pyx_t_3, __pyx_t_4, __pyx_v_self->dtype_is_object); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 451, __pyx_L1_error)
    9160             : 
    9161             :   /* "View.MemoryView":445
    9162             :  *         return obj
    9163             :  * 
    9164             :  *     cdef setitem_slice_assignment(self, dst, src):             # <<<<<<<<<<<<<<
    9165             :  *         cdef __Pyx_memviewslice dst_slice
    9166             :  *         cdef __Pyx_memviewslice src_slice
    9167             :  */
    9168             : 
    9169             :   /* function exit code */
    9170           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    9171           0 :   goto __pyx_L0;
    9172           0 :   __pyx_L1_error:;
    9173           0 :   __Pyx_XDECREF(__pyx_t_2);
    9174           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.setitem_slice_assignment", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9175           0 :   __pyx_r = 0;
    9176           0 :   __pyx_L0:;
    9177           0 :   __Pyx_XGIVEREF(__pyx_r);
    9178           0 :   __Pyx_RefNannyFinishContext();
    9179           0 :   return __pyx_r;
    9180             : }
    9181             : 
    9182             : /* "View.MemoryView":453
    9183             :  *         memoryview_copy_contents(msrc, mdst, src.ndim, dst.ndim, self.dtype_is_object)
    9184             :  * 
    9185             :  *     cdef setitem_slice_assign_scalar(self, memoryview dst, value):             # <<<<<<<<<<<<<<
    9186             :  *         cdef int array[128]
    9187             :  *         cdef void *tmp = NULL
    9188             :  */
    9189             : 
    9190           0 : static PyObject *__pyx_memoryview_setitem_slice_assign_scalar(struct __pyx_memoryview_obj *__pyx_v_self, struct __pyx_memoryview_obj *__pyx_v_dst, PyObject *__pyx_v_value) {
    9191           0 :   int __pyx_v_array[0x80];
    9192           0 :   void *__pyx_v_tmp;
    9193           0 :   void *__pyx_v_item;
    9194           0 :   __Pyx_memviewslice *__pyx_v_dst_slice;
    9195           0 :   __Pyx_memviewslice __pyx_v_tmp_slice;
    9196           0 :   PyObject *__pyx_r = NULL;
    9197             :   __Pyx_RefNannyDeclarations
    9198           0 :   __Pyx_memviewslice *__pyx_t_1;
    9199           0 :   int __pyx_t_2;
    9200           0 :   PyObject *__pyx_t_3 = NULL;
    9201           0 :   int __pyx_t_4;
    9202           0 :   int __pyx_t_5;
    9203           0 :   char const *__pyx_t_6;
    9204           0 :   PyObject *__pyx_t_7 = NULL;
    9205           0 :   PyObject *__pyx_t_8 = NULL;
    9206           0 :   PyObject *__pyx_t_9 = NULL;
    9207           0 :   PyObject *__pyx_t_10 = NULL;
    9208           0 :   PyObject *__pyx_t_11 = NULL;
    9209           0 :   PyObject *__pyx_t_12 = NULL;
    9210           0 :   int __pyx_lineno = 0;
    9211           0 :   const char *__pyx_filename = NULL;
    9212           0 :   int __pyx_clineno = 0;
    9213           0 :   __Pyx_RefNannySetupContext("setitem_slice_assign_scalar", 1);
    9214             : 
    9215             :   /* "View.MemoryView":455
    9216             :  *     cdef setitem_slice_assign_scalar(self, memoryview dst, value):
    9217             :  *         cdef int array[128]
    9218             :  *         cdef void *tmp = NULL             # <<<<<<<<<<<<<<
    9219             :  *         cdef void *item
    9220             :  * 
    9221             :  */
    9222           0 :   __pyx_v_tmp = NULL;
    9223             : 
    9224             :   /* "View.MemoryView":460
    9225             :  *         cdef __Pyx_memviewslice *dst_slice
    9226             :  *         cdef __Pyx_memviewslice tmp_slice
    9227             :  *         dst_slice = get_slice_from_memview(dst, &tmp_slice)             # <<<<<<<<<<<<<<
    9228             :  * 
    9229             :  *         if <size_t>self.view.itemsize > sizeof(array):
    9230             :  */
    9231           0 :   __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_dst, (&__pyx_v_tmp_slice)); if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(1, 460, __pyx_L1_error)
    9232           0 :   __pyx_v_dst_slice = __pyx_t_1;
    9233             : 
    9234             :   /* "View.MemoryView":462
    9235             :  *         dst_slice = get_slice_from_memview(dst, &tmp_slice)
    9236             :  * 
    9237             :  *         if <size_t>self.view.itemsize > sizeof(array):             # <<<<<<<<<<<<<<
    9238             :  *             tmp = PyMem_Malloc(self.view.itemsize)
    9239             :  *             if tmp == NULL:
    9240             :  */
    9241           0 :   __pyx_t_2 = (((size_t)__pyx_v_self->view.itemsize) > (sizeof(__pyx_v_array)));
    9242           0 :   if (__pyx_t_2) {
    9243             : 
    9244             :     /* "View.MemoryView":463
    9245             :  * 
    9246             :  *         if <size_t>self.view.itemsize > sizeof(array):
    9247             :  *             tmp = PyMem_Malloc(self.view.itemsize)             # <<<<<<<<<<<<<<
    9248             :  *             if tmp == NULL:
    9249             :  *                 raise MemoryError
    9250             :  */
    9251           0 :     __pyx_v_tmp = PyMem_Malloc(__pyx_v_self->view.itemsize);
    9252             : 
    9253             :     /* "View.MemoryView":464
    9254             :  *         if <size_t>self.view.itemsize > sizeof(array):
    9255             :  *             tmp = PyMem_Malloc(self.view.itemsize)
    9256             :  *             if tmp == NULL:             # <<<<<<<<<<<<<<
    9257             :  *                 raise MemoryError
    9258             :  *             item = tmp
    9259             :  */
    9260           0 :     __pyx_t_2 = (__pyx_v_tmp == NULL);
    9261           0 :     if (unlikely(__pyx_t_2)) {
    9262             : 
    9263             :       /* "View.MemoryView":465
    9264             :  *             tmp = PyMem_Malloc(self.view.itemsize)
    9265             :  *             if tmp == NULL:
    9266             :  *                 raise MemoryError             # <<<<<<<<<<<<<<
    9267             :  *             item = tmp
    9268             :  *         else:
    9269             :  */
    9270           0 :       PyErr_NoMemory(); __PYX_ERR(1, 465, __pyx_L1_error)
    9271             : 
    9272             :       /* "View.MemoryView":464
    9273             :  *         if <size_t>self.view.itemsize > sizeof(array):
    9274             :  *             tmp = PyMem_Malloc(self.view.itemsize)
    9275             :  *             if tmp == NULL:             # <<<<<<<<<<<<<<
    9276             :  *                 raise MemoryError
    9277             :  *             item = tmp
    9278             :  */
    9279             :     }
    9280             : 
    9281             :     /* "View.MemoryView":466
    9282             :  *             if tmp == NULL:
    9283             :  *                 raise MemoryError
    9284             :  *             item = tmp             # <<<<<<<<<<<<<<
    9285             :  *         else:
    9286             :  *             item = <void *> array
    9287             :  */
    9288           0 :     __pyx_v_item = __pyx_v_tmp;
    9289             : 
    9290             :     /* "View.MemoryView":462
    9291             :  *         dst_slice = get_slice_from_memview(dst, &tmp_slice)
    9292             :  * 
    9293             :  *         if <size_t>self.view.itemsize > sizeof(array):             # <<<<<<<<<<<<<<
    9294             :  *             tmp = PyMem_Malloc(self.view.itemsize)
    9295             :  *             if tmp == NULL:
    9296             :  */
    9297           0 :     goto __pyx_L3;
    9298             :   }
    9299             : 
    9300             :   /* "View.MemoryView":468
    9301             :  *             item = tmp
    9302             :  *         else:
    9303             :  *             item = <void *> array             # <<<<<<<<<<<<<<
    9304             :  * 
    9305             :  *         try:
    9306             :  */
    9307             :   /*else*/ {
    9308             :     __pyx_v_item = ((void *)__pyx_v_array);
    9309             :   }
    9310           0 :   __pyx_L3:;
    9311             : 
    9312             :   /* "View.MemoryView":470
    9313             :  *             item = <void *> array
    9314             :  * 
    9315             :  *         try:             # <<<<<<<<<<<<<<
    9316             :  *             if self.dtype_is_object:
    9317             :  *                 (<PyObject **> item)[0] = <PyObject *> value
    9318             :  */
    9319             :   /*try:*/ {
    9320             : 
    9321             :     /* "View.MemoryView":471
    9322             :  * 
    9323             :  *         try:
    9324             :  *             if self.dtype_is_object:             # <<<<<<<<<<<<<<
    9325             :  *                 (<PyObject **> item)[0] = <PyObject *> value
    9326             :  *             else:
    9327             :  */
    9328           0 :     if (__pyx_v_self->dtype_is_object) {
    9329             : 
    9330             :       /* "View.MemoryView":472
    9331             :  *         try:
    9332             :  *             if self.dtype_is_object:
    9333             :  *                 (<PyObject **> item)[0] = <PyObject *> value             # <<<<<<<<<<<<<<
    9334             :  *             else:
    9335             :  *                 self.assign_item_from_object(<char *> item, value)
    9336             :  */
    9337           0 :       (((PyObject **)__pyx_v_item)[0]) = ((PyObject *)__pyx_v_value);
    9338             : 
    9339             :       /* "View.MemoryView":471
    9340             :  * 
    9341             :  *         try:
    9342             :  *             if self.dtype_is_object:             # <<<<<<<<<<<<<<
    9343             :  *                 (<PyObject **> item)[0] = <PyObject *> value
    9344             :  *             else:
    9345             :  */
    9346           0 :       goto __pyx_L8;
    9347             :     }
    9348             : 
    9349             :     /* "View.MemoryView":474
    9350             :  *                 (<PyObject **> item)[0] = <PyObject *> value
    9351             :  *             else:
    9352             :  *                 self.assign_item_from_object(<char *> item, value)             # <<<<<<<<<<<<<<
    9353             :  * 
    9354             :  * 
    9355             :  */
    9356             :     /*else*/ {
    9357           0 :       __pyx_t_3 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->assign_item_from_object(__pyx_v_self, ((char *)__pyx_v_item), __pyx_v_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 474, __pyx_L6_error)
    9358           0 :       __Pyx_GOTREF(__pyx_t_3);
    9359           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    9360             :     }
    9361           0 :     __pyx_L8:;
    9362             : 
    9363             :     /* "View.MemoryView":478
    9364             :  * 
    9365             :  * 
    9366             :  *             if self.view.suboffsets != NULL:             # <<<<<<<<<<<<<<
    9367             :  *                 assert_direct_dimensions(self.view.suboffsets, self.view.ndim)
    9368             :  *             slice_assign_scalar(dst_slice, dst.view.ndim, self.view.itemsize,
    9369             :  */
    9370           0 :     __pyx_t_2 = (__pyx_v_self->view.suboffsets != NULL);
    9371           0 :     if (__pyx_t_2) {
    9372             : 
    9373             :       /* "View.MemoryView":479
    9374             :  * 
    9375             :  *             if self.view.suboffsets != NULL:
    9376             :  *                 assert_direct_dimensions(self.view.suboffsets, self.view.ndim)             # <<<<<<<<<<<<<<
    9377             :  *             slice_assign_scalar(dst_slice, dst.view.ndim, self.view.itemsize,
    9378             :  *                                 item, self.dtype_is_object)
    9379             :  */
    9380           0 :       __pyx_t_4 = assert_direct_dimensions(__pyx_v_self->view.suboffsets, __pyx_v_self->view.ndim); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 479, __pyx_L6_error)
    9381             : 
    9382             :       /* "View.MemoryView":478
    9383             :  * 
    9384             :  * 
    9385             :  *             if self.view.suboffsets != NULL:             # <<<<<<<<<<<<<<
    9386             :  *                 assert_direct_dimensions(self.view.suboffsets, self.view.ndim)
    9387             :  *             slice_assign_scalar(dst_slice, dst.view.ndim, self.view.itemsize,
    9388             :  */
    9389             :     }
    9390             : 
    9391             :     /* "View.MemoryView":480
    9392             :  *             if self.view.suboffsets != NULL:
    9393             :  *                 assert_direct_dimensions(self.view.suboffsets, self.view.ndim)
    9394             :  *             slice_assign_scalar(dst_slice, dst.view.ndim, self.view.itemsize,             # <<<<<<<<<<<<<<
    9395             :  *                                 item, self.dtype_is_object)
    9396             :  *         finally:
    9397             :  */
    9398           0 :     __pyx_memoryview_slice_assign_scalar(__pyx_v_dst_slice, __pyx_v_dst->view.ndim, __pyx_v_self->view.itemsize, __pyx_v_item, __pyx_v_self->dtype_is_object);
    9399             :   }
    9400             : 
    9401             :   /* "View.MemoryView":483
    9402             :  *                                 item, self.dtype_is_object)
    9403             :  *         finally:
    9404             :  *             PyMem_Free(tmp)             # <<<<<<<<<<<<<<
    9405             :  * 
    9406             :  *     cdef setitem_indexed(self, index, value):
    9407             :  */
    9408             :   /*finally:*/ {
    9409             :     /*normal exit:*/{
    9410           0 :       PyMem_Free(__pyx_v_tmp);
    9411           0 :       goto __pyx_L7;
    9412             :     }
    9413           0 :     __pyx_L6_error:;
    9414             :     /*exception exit:*/{
    9415           0 :       __Pyx_PyThreadState_declare
    9416           0 :       __Pyx_PyThreadState_assign
    9417           0 :       __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0;
    9418           0 :       __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
    9419           0 :       if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12);
    9420           0 :       if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_7, &__pyx_t_8, &__pyx_t_9) < 0)) __Pyx_ErrFetch(&__pyx_t_7, &__pyx_t_8, &__pyx_t_9);
    9421           0 :       __Pyx_XGOTREF(__pyx_t_7);
    9422           0 :       __Pyx_XGOTREF(__pyx_t_8);
    9423           0 :       __Pyx_XGOTREF(__pyx_t_9);
    9424           0 :       __Pyx_XGOTREF(__pyx_t_10);
    9425           0 :       __Pyx_XGOTREF(__pyx_t_11);
    9426           0 :       __Pyx_XGOTREF(__pyx_t_12);
    9427           0 :       __pyx_t_4 = __pyx_lineno; __pyx_t_5 = __pyx_clineno; __pyx_t_6 = __pyx_filename;
    9428             :       {
    9429           0 :         PyMem_Free(__pyx_v_tmp);
    9430             :       }
    9431           0 :       if (PY_MAJOR_VERSION >= 3) {
    9432           0 :         __Pyx_XGIVEREF(__pyx_t_10);
    9433           0 :         __Pyx_XGIVEREF(__pyx_t_11);
    9434           0 :         __Pyx_XGIVEREF(__pyx_t_12);
    9435           0 :         __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12);
    9436             :       }
    9437           0 :       __Pyx_XGIVEREF(__pyx_t_7);
    9438           0 :       __Pyx_XGIVEREF(__pyx_t_8);
    9439           0 :       __Pyx_XGIVEREF(__pyx_t_9);
    9440           0 :       __Pyx_ErrRestore(__pyx_t_7, __pyx_t_8, __pyx_t_9);
    9441           0 :       __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0;
    9442           0 :       __pyx_lineno = __pyx_t_4; __pyx_clineno = __pyx_t_5; __pyx_filename = __pyx_t_6;
    9443           0 :       goto __pyx_L1_error;
    9444             :     }
    9445           0 :     __pyx_L7:;
    9446             :   }
    9447             : 
    9448             :   /* "View.MemoryView":453
    9449             :  *         memoryview_copy_contents(msrc, mdst, src.ndim, dst.ndim, self.dtype_is_object)
    9450             :  * 
    9451             :  *     cdef setitem_slice_assign_scalar(self, memoryview dst, value):             # <<<<<<<<<<<<<<
    9452             :  *         cdef int array[128]
    9453             :  *         cdef void *tmp = NULL
    9454             :  */
    9455             : 
    9456             :   /* function exit code */
    9457           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    9458           0 :   goto __pyx_L0;
    9459           0 :   __pyx_L1_error:;
    9460           0 :   __Pyx_XDECREF(__pyx_t_3);
    9461           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.setitem_slice_assign_scalar", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9462           0 :   __pyx_r = 0;
    9463           0 :   __pyx_L0:;
    9464           0 :   __Pyx_XGIVEREF(__pyx_r);
    9465           0 :   __Pyx_RefNannyFinishContext();
    9466           0 :   return __pyx_r;
    9467             : }
    9468             : 
    9469             : /* "View.MemoryView":485
    9470             :  *             PyMem_Free(tmp)
    9471             :  * 
    9472             :  *     cdef setitem_indexed(self, index, value):             # <<<<<<<<<<<<<<
    9473             :  *         cdef char *itemp = self.get_item_pointer(index)
    9474             :  *         self.assign_item_from_object(itemp, value)
    9475             :  */
    9476             : 
    9477           0 : static PyObject *__pyx_memoryview_setitem_indexed(struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
    9478           0 :   char *__pyx_v_itemp;
    9479           0 :   PyObject *__pyx_r = NULL;
    9480             :   __Pyx_RefNannyDeclarations
    9481           0 :   char *__pyx_t_1;
    9482           0 :   PyObject *__pyx_t_2 = NULL;
    9483           0 :   int __pyx_lineno = 0;
    9484           0 :   const char *__pyx_filename = NULL;
    9485           0 :   int __pyx_clineno = 0;
    9486           0 :   __Pyx_RefNannySetupContext("setitem_indexed", 1);
    9487             : 
    9488             :   /* "View.MemoryView":486
    9489             :  * 
    9490             :  *     cdef setitem_indexed(self, index, value):
    9491             :  *         cdef char *itemp = self.get_item_pointer(index)             # <<<<<<<<<<<<<<
    9492             :  *         self.assign_item_from_object(itemp, value)
    9493             :  * 
    9494             :  */
    9495           0 :   __pyx_t_1 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->get_item_pointer(__pyx_v_self, __pyx_v_index); if (unlikely(__pyx_t_1 == ((char *)NULL))) __PYX_ERR(1, 486, __pyx_L1_error)
    9496           0 :   __pyx_v_itemp = __pyx_t_1;
    9497             : 
    9498             :   /* "View.MemoryView":487
    9499             :  *     cdef setitem_indexed(self, index, value):
    9500             :  *         cdef char *itemp = self.get_item_pointer(index)
    9501             :  *         self.assign_item_from_object(itemp, value)             # <<<<<<<<<<<<<<
    9502             :  * 
    9503             :  *     cdef convert_item_to_object(self, char *itemp):
    9504             :  */
    9505           0 :   __pyx_t_2 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->assign_item_from_object(__pyx_v_self, __pyx_v_itemp, __pyx_v_value); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 487, __pyx_L1_error)
    9506           0 :   __Pyx_GOTREF(__pyx_t_2);
    9507           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    9508             : 
    9509             :   /* "View.MemoryView":485
    9510             :  *             PyMem_Free(tmp)
    9511             :  * 
    9512             :  *     cdef setitem_indexed(self, index, value):             # <<<<<<<<<<<<<<
    9513             :  *         cdef char *itemp = self.get_item_pointer(index)
    9514             :  *         self.assign_item_from_object(itemp, value)
    9515             :  */
    9516             : 
    9517             :   /* function exit code */
    9518           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    9519           0 :   goto __pyx_L0;
    9520           0 :   __pyx_L1_error:;
    9521           0 :   __Pyx_XDECREF(__pyx_t_2);
    9522           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.setitem_indexed", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9523           0 :   __pyx_r = 0;
    9524           0 :   __pyx_L0:;
    9525           0 :   __Pyx_XGIVEREF(__pyx_r);
    9526           0 :   __Pyx_RefNannyFinishContext();
    9527           0 :   return __pyx_r;
    9528             : }
    9529             : 
    9530             : /* "View.MemoryView":489
    9531             :  *         self.assign_item_from_object(itemp, value)
    9532             :  * 
    9533             :  *     cdef convert_item_to_object(self, char *itemp):             # <<<<<<<<<<<<<<
    9534             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9535             :  *         know how to convert the type"""
    9536             :  */
    9537             : 
    9538           0 : static PyObject *__pyx_memoryview_convert_item_to_object(struct __pyx_memoryview_obj *__pyx_v_self, char *__pyx_v_itemp) {
    9539           0 :   PyObject *__pyx_v_struct = NULL;
    9540           0 :   PyObject *__pyx_v_bytesitem = 0;
    9541           0 :   PyObject *__pyx_v_result = NULL;
    9542           0 :   PyObject *__pyx_r = NULL;
    9543             :   __Pyx_RefNannyDeclarations
    9544           0 :   PyObject *__pyx_t_1 = NULL;
    9545           0 :   PyObject *__pyx_t_2 = NULL;
    9546           0 :   PyObject *__pyx_t_3 = NULL;
    9547           0 :   PyObject *__pyx_t_4 = NULL;
    9548           0 :   PyObject *__pyx_t_5 = NULL;
    9549           0 :   PyObject *__pyx_t_6 = NULL;
    9550           0 :   PyObject *__pyx_t_7 = NULL;
    9551           0 :   unsigned int __pyx_t_8;
    9552           0 :   Py_ssize_t __pyx_t_9;
    9553           0 :   int __pyx_t_10;
    9554           0 :   int __pyx_t_11;
    9555           0 :   int __pyx_lineno = 0;
    9556           0 :   const char *__pyx_filename = NULL;
    9557           0 :   int __pyx_clineno = 0;
    9558           0 :   __Pyx_RefNannySetupContext("convert_item_to_object", 1);
    9559             : 
    9560             :   /* "View.MemoryView":492
    9561             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9562             :  *         know how to convert the type"""
    9563             :  *         import struct             # <<<<<<<<<<<<<<
    9564             :  *         cdef bytes bytesitem
    9565             :  * 
    9566             :  */
    9567           0 :   __pyx_t_1 = __Pyx_ImportDottedModule(__pyx_n_s_struct, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 492, __pyx_L1_error)
    9568           0 :   __Pyx_GOTREF(__pyx_t_1);
    9569           0 :   __pyx_v_struct = __pyx_t_1;
    9570           0 :   __pyx_t_1 = 0;
    9571             : 
    9572             :   /* "View.MemoryView":495
    9573             :  *         cdef bytes bytesitem
    9574             :  * 
    9575             :  *         bytesitem = itemp[:self.view.itemsize]             # <<<<<<<<<<<<<<
    9576             :  *         try:
    9577             :  *             result = struct.unpack(self.view.format, bytesitem)
    9578             :  */
    9579           0 :   __pyx_t_1 = __Pyx_PyBytes_FromStringAndSize(__pyx_v_itemp + 0, __pyx_v_self->view.itemsize - 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 495, __pyx_L1_error)
    9580           0 :   __Pyx_GOTREF(__pyx_t_1);
    9581           0 :   __pyx_v_bytesitem = ((PyObject*)__pyx_t_1);
    9582           0 :   __pyx_t_1 = 0;
    9583             : 
    9584             :   /* "View.MemoryView":496
    9585             :  * 
    9586             :  *         bytesitem = itemp[:self.view.itemsize]
    9587             :  *         try:             # <<<<<<<<<<<<<<
    9588             :  *             result = struct.unpack(self.view.format, bytesitem)
    9589             :  *         except struct.error:
    9590             :  */
    9591             :   {
    9592           0 :     __Pyx_PyThreadState_declare
    9593           0 :     __Pyx_PyThreadState_assign
    9594           0 :     __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4);
    9595           0 :     __Pyx_XGOTREF(__pyx_t_2);
    9596           0 :     __Pyx_XGOTREF(__pyx_t_3);
    9597           0 :     __Pyx_XGOTREF(__pyx_t_4);
    9598             :     /*try:*/ {
    9599             : 
    9600             :       /* "View.MemoryView":497
    9601             :  *         bytesitem = itemp[:self.view.itemsize]
    9602             :  *         try:
    9603             :  *             result = struct.unpack(self.view.format, bytesitem)             # <<<<<<<<<<<<<<
    9604             :  *         except struct.error:
    9605             :  *             raise ValueError, "Unable to convert item to object"
    9606             :  */
    9607           0 :       __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_unpack); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 497, __pyx_L3_error)
    9608           0 :       __Pyx_GOTREF(__pyx_t_5);
    9609           0 :       __pyx_t_6 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 497, __pyx_L3_error)
    9610           0 :       __Pyx_GOTREF(__pyx_t_6);
    9611           0 :       __pyx_t_7 = NULL;
    9612           0 :       __pyx_t_8 = 0;
    9613             :       #if CYTHON_UNPACK_METHODS
    9614           0 :       if (likely(PyMethod_Check(__pyx_t_5))) {
    9615           0 :         __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_5);
    9616           0 :         if (likely(__pyx_t_7)) {
    9617           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
    9618           0 :           __Pyx_INCREF(__pyx_t_7);
    9619           0 :           __Pyx_INCREF(function);
    9620           0 :           __Pyx_DECREF_SET(__pyx_t_5, function);
    9621             :           __pyx_t_8 = 1;
    9622             :         }
    9623             :       }
    9624             :       #endif
    9625             :       {
    9626           0 :         PyObject *__pyx_callargs[3] = {__pyx_t_7, __pyx_t_6, __pyx_v_bytesitem};
    9627           0 :         __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_5, __pyx_callargs+1-__pyx_t_8, 2+__pyx_t_8);
    9628           0 :         __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
    9629           0 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    9630           0 :         if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 497, __pyx_L3_error)
    9631           0 :         __Pyx_GOTREF(__pyx_t_1);
    9632           0 :         __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    9633             :       }
    9634           0 :       __pyx_v_result = __pyx_t_1;
    9635           0 :       __pyx_t_1 = 0;
    9636             : 
    9637             :       /* "View.MemoryView":496
    9638             :  * 
    9639             :  *         bytesitem = itemp[:self.view.itemsize]
    9640             :  *         try:             # <<<<<<<<<<<<<<
    9641             :  *             result = struct.unpack(self.view.format, bytesitem)
    9642             :  *         except struct.error:
    9643             :  */
    9644             :     }
    9645             : 
    9646             :     /* "View.MemoryView":501
    9647             :  *             raise ValueError, "Unable to convert item to object"
    9648             :  *         else:
    9649             :  *             if len(self.view.format) == 1:             # <<<<<<<<<<<<<<
    9650             :  *                 return result[0]
    9651             :  *             return result
    9652             :  */
    9653             :     /*else:*/ {
    9654           0 :       __pyx_t_9 = __Pyx_ssize_strlen(__pyx_v_self->view.format); if (unlikely(__pyx_t_9 == ((Py_ssize_t)-1))) __PYX_ERR(1, 501, __pyx_L5_except_error)
    9655           0 :       __pyx_t_10 = (__pyx_t_9 == 1);
    9656           0 :       if (__pyx_t_10) {
    9657             : 
    9658             :         /* "View.MemoryView":502
    9659             :  *         else:
    9660             :  *             if len(self.view.format) == 1:
    9661             :  *                 return result[0]             # <<<<<<<<<<<<<<
    9662             :  *             return result
    9663             :  * 
    9664             :  */
    9665           0 :         __Pyx_XDECREF(__pyx_r);
    9666           0 :         __pyx_t_1 = __Pyx_GetItemInt(__pyx_v_result, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 502, __pyx_L5_except_error)
    9667           0 :         __Pyx_GOTREF(__pyx_t_1);
    9668           0 :         __pyx_r = __pyx_t_1;
    9669           0 :         __pyx_t_1 = 0;
    9670           0 :         goto __pyx_L6_except_return;
    9671             : 
    9672             :         /* "View.MemoryView":501
    9673             :  *             raise ValueError, "Unable to convert item to object"
    9674             :  *         else:
    9675             :  *             if len(self.view.format) == 1:             # <<<<<<<<<<<<<<
    9676             :  *                 return result[0]
    9677             :  *             return result
    9678             :  */
    9679             :       }
    9680             : 
    9681             :       /* "View.MemoryView":503
    9682             :  *             if len(self.view.format) == 1:
    9683             :  *                 return result[0]
    9684             :  *             return result             # <<<<<<<<<<<<<<
    9685             :  * 
    9686             :  *     cdef assign_item_from_object(self, char *itemp, object value):
    9687             :  */
    9688           0 :       __Pyx_XDECREF(__pyx_r);
    9689           0 :       __Pyx_INCREF(__pyx_v_result);
    9690           0 :       __pyx_r = __pyx_v_result;
    9691           0 :       goto __pyx_L6_except_return;
    9692             :     }
    9693           0 :     __pyx_L3_error:;
    9694           0 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
    9695           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
    9696           0 :     __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
    9697           0 :     __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
    9698             : 
    9699             :     /* "View.MemoryView":498
    9700             :  *         try:
    9701             :  *             result = struct.unpack(self.view.format, bytesitem)
    9702             :  *         except struct.error:             # <<<<<<<<<<<<<<
    9703             :  *             raise ValueError, "Unable to convert item to object"
    9704             :  *         else:
    9705             :  */
    9706           0 :     __Pyx_ErrFetch(&__pyx_t_1, &__pyx_t_5, &__pyx_t_6);
    9707           0 :     __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_error); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 498, __pyx_L5_except_error)
    9708           0 :     __Pyx_GOTREF(__pyx_t_7);
    9709           0 :     __pyx_t_11 = __Pyx_PyErr_GivenExceptionMatches(__pyx_t_1, __pyx_t_7);
    9710           0 :     __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    9711           0 :     __Pyx_ErrRestore(__pyx_t_1, __pyx_t_5, __pyx_t_6);
    9712           0 :     __pyx_t_1 = 0; __pyx_t_5 = 0; __pyx_t_6 = 0;
    9713           0 :     if (__pyx_t_11) {
    9714           0 :       __Pyx_AddTraceback("View.MemoryView.memoryview.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9715           0 :       if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_5, &__pyx_t_1) < 0) __PYX_ERR(1, 498, __pyx_L5_except_error)
    9716           0 :       __Pyx_XGOTREF(__pyx_t_6);
    9717           0 :       __Pyx_XGOTREF(__pyx_t_5);
    9718           0 :       __Pyx_XGOTREF(__pyx_t_1);
    9719             : 
    9720             :       /* "View.MemoryView":499
    9721             :  *             result = struct.unpack(self.view.format, bytesitem)
    9722             :  *         except struct.error:
    9723             :  *             raise ValueError, "Unable to convert item to object"             # <<<<<<<<<<<<<<
    9724             :  *         else:
    9725             :  *             if len(self.view.format) == 1:
    9726             :  */
    9727           0 :       __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Unable_to_convert_item_to_object, 0, 0);
    9728           0 :       __PYX_ERR(1, 499, __pyx_L5_except_error)
    9729             :     }
    9730           0 :     goto __pyx_L5_except_error;
    9731             : 
    9732             :     /* "View.MemoryView":496
    9733             :  * 
    9734             :  *         bytesitem = itemp[:self.view.itemsize]
    9735             :  *         try:             # <<<<<<<<<<<<<<
    9736             :  *             result = struct.unpack(self.view.format, bytesitem)
    9737             :  *         except struct.error:
    9738             :  */
    9739           0 :     __pyx_L5_except_error:;
    9740           0 :     __Pyx_XGIVEREF(__pyx_t_2);
    9741           0 :     __Pyx_XGIVEREF(__pyx_t_3);
    9742           0 :     __Pyx_XGIVEREF(__pyx_t_4);
    9743           0 :     __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
    9744           0 :     goto __pyx_L1_error;
    9745           0 :     __pyx_L6_except_return:;
    9746           0 :     __Pyx_XGIVEREF(__pyx_t_2);
    9747           0 :     __Pyx_XGIVEREF(__pyx_t_3);
    9748           0 :     __Pyx_XGIVEREF(__pyx_t_4);
    9749           0 :     __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
    9750           0 :     goto __pyx_L0;
    9751             :   }
    9752             : 
    9753             :   /* "View.MemoryView":489
    9754             :  *         self.assign_item_from_object(itemp, value)
    9755             :  * 
    9756             :  *     cdef convert_item_to_object(self, char *itemp):             # <<<<<<<<<<<<<<
    9757             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9758             :  *         know how to convert the type"""
    9759             :  */
    9760             : 
    9761             :   /* function exit code */
    9762           0 :   __pyx_L1_error:;
    9763           0 :   __Pyx_XDECREF(__pyx_t_1);
    9764           0 :   __Pyx_XDECREF(__pyx_t_5);
    9765           0 :   __Pyx_XDECREF(__pyx_t_6);
    9766           0 :   __Pyx_XDECREF(__pyx_t_7);
    9767           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9768           0 :   __pyx_r = 0;
    9769           0 :   __pyx_L0:;
    9770           0 :   __Pyx_XDECREF(__pyx_v_struct);
    9771           0 :   __Pyx_XDECREF(__pyx_v_bytesitem);
    9772           0 :   __Pyx_XDECREF(__pyx_v_result);
    9773           0 :   __Pyx_XGIVEREF(__pyx_r);
    9774           0 :   __Pyx_RefNannyFinishContext();
    9775           0 :   return __pyx_r;
    9776             : }
    9777             : 
    9778             : /* "View.MemoryView":505
    9779             :  *             return result
    9780             :  * 
    9781             :  *     cdef assign_item_from_object(self, char *itemp, object value):             # <<<<<<<<<<<<<<
    9782             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9783             :  *         know how to convert the type"""
    9784             :  */
    9785             : 
    9786           0 : static PyObject *__pyx_memoryview_assign_item_from_object(struct __pyx_memoryview_obj *__pyx_v_self, char *__pyx_v_itemp, PyObject *__pyx_v_value) {
    9787           0 :   PyObject *__pyx_v_struct = NULL;
    9788           0 :   char __pyx_v_c;
    9789           0 :   PyObject *__pyx_v_bytesvalue = 0;
    9790           0 :   Py_ssize_t __pyx_v_i;
    9791           0 :   PyObject *__pyx_r = NULL;
    9792             :   __Pyx_RefNannyDeclarations
    9793           0 :   PyObject *__pyx_t_1 = NULL;
    9794           0 :   int __pyx_t_2;
    9795           0 :   PyObject *__pyx_t_3 = NULL;
    9796           0 :   PyObject *__pyx_t_4 = NULL;
    9797           0 :   PyObject *__pyx_t_5 = NULL;
    9798           0 :   unsigned int __pyx_t_6;
    9799           0 :   Py_ssize_t __pyx_t_7;
    9800           0 :   PyObject *__pyx_t_8 = NULL;
    9801           0 :   char *__pyx_t_9;
    9802           0 :   char *__pyx_t_10;
    9803           0 :   char *__pyx_t_11;
    9804           0 :   char *__pyx_t_12;
    9805           0 :   int __pyx_lineno = 0;
    9806           0 :   const char *__pyx_filename = NULL;
    9807           0 :   int __pyx_clineno = 0;
    9808           0 :   __Pyx_RefNannySetupContext("assign_item_from_object", 1);
    9809             : 
    9810             :   /* "View.MemoryView":508
    9811             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9812             :  *         know how to convert the type"""
    9813             :  *         import struct             # <<<<<<<<<<<<<<
    9814             :  *         cdef char c
    9815             :  *         cdef bytes bytesvalue
    9816             :  */
    9817           0 :   __pyx_t_1 = __Pyx_ImportDottedModule(__pyx_n_s_struct, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 508, __pyx_L1_error)
    9818           0 :   __Pyx_GOTREF(__pyx_t_1);
    9819           0 :   __pyx_v_struct = __pyx_t_1;
    9820           0 :   __pyx_t_1 = 0;
    9821             : 
    9822             :   /* "View.MemoryView":513
    9823             :  *         cdef Py_ssize_t i
    9824             :  * 
    9825             :  *         if isinstance(value, tuple):             # <<<<<<<<<<<<<<
    9826             :  *             bytesvalue = struct.pack(self.view.format, *value)
    9827             :  *         else:
    9828             :  */
    9829           0 :   __pyx_t_2 = PyTuple_Check(__pyx_v_value); 
    9830           0 :   if (__pyx_t_2) {
    9831             : 
    9832             :     /* "View.MemoryView":514
    9833             :  * 
    9834             :  *         if isinstance(value, tuple):
    9835             :  *             bytesvalue = struct.pack(self.view.format, *value)             # <<<<<<<<<<<<<<
    9836             :  *         else:
    9837             :  *             bytesvalue = struct.pack(self.view.format, value)
    9838             :  */
    9839           0 :     __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_pack); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 514, __pyx_L1_error)
    9840           0 :     __Pyx_GOTREF(__pyx_t_1);
    9841           0 :     __pyx_t_3 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 514, __pyx_L1_error)
    9842           0 :     __Pyx_GOTREF(__pyx_t_3);
    9843           0 :     __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 514, __pyx_L1_error)
    9844           0 :     __Pyx_GOTREF(__pyx_t_4);
    9845           0 :     __Pyx_GIVEREF(__pyx_t_3);
    9846           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3)) __PYX_ERR(1, 514, __pyx_L1_error);
    9847           0 :     __pyx_t_3 = 0;
    9848           0 :     __pyx_t_3 = __Pyx_PySequence_Tuple(__pyx_v_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 514, __pyx_L1_error)
    9849           0 :     __Pyx_GOTREF(__pyx_t_3);
    9850           0 :     __pyx_t_5 = PyNumber_Add(__pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 514, __pyx_L1_error)
    9851           0 :     __Pyx_GOTREF(__pyx_t_5);
    9852           0 :     __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    9853           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    9854           0 :     __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 514, __pyx_L1_error)
    9855           0 :     __Pyx_GOTREF(__pyx_t_3);
    9856           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    9857           0 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    9858           0 :     if (!(likely(PyBytes_CheckExact(__pyx_t_3))||((__pyx_t_3) == Py_None) || __Pyx_RaiseUnexpectedTypeError("bytes", __pyx_t_3))) __PYX_ERR(1, 514, __pyx_L1_error)
    9859           0 :     __pyx_v_bytesvalue = ((PyObject*)__pyx_t_3);
    9860           0 :     __pyx_t_3 = 0;
    9861             : 
    9862             :     /* "View.MemoryView":513
    9863             :  *         cdef Py_ssize_t i
    9864             :  * 
    9865             :  *         if isinstance(value, tuple):             # <<<<<<<<<<<<<<
    9866             :  *             bytesvalue = struct.pack(self.view.format, *value)
    9867             :  *         else:
    9868             :  */
    9869           0 :     goto __pyx_L3;
    9870             :   }
    9871             : 
    9872             :   /* "View.MemoryView":516
    9873             :  *             bytesvalue = struct.pack(self.view.format, *value)
    9874             :  *         else:
    9875             :  *             bytesvalue = struct.pack(self.view.format, value)             # <<<<<<<<<<<<<<
    9876             :  * 
    9877             :  *         for i, c in enumerate(bytesvalue):
    9878             :  */
    9879             :   /*else*/ {
    9880           0 :     __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_pack); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 516, __pyx_L1_error)
    9881           0 :     __Pyx_GOTREF(__pyx_t_5);
    9882           0 :     __pyx_t_1 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 516, __pyx_L1_error)
    9883           0 :     __Pyx_GOTREF(__pyx_t_1);
    9884           0 :     __pyx_t_4 = NULL;
    9885           0 :     __pyx_t_6 = 0;
    9886             :     #if CYTHON_UNPACK_METHODS
    9887           0 :     if (likely(PyMethod_Check(__pyx_t_5))) {
    9888           0 :       __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5);
    9889           0 :       if (likely(__pyx_t_4)) {
    9890           0 :         PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
    9891           0 :         __Pyx_INCREF(__pyx_t_4);
    9892           0 :         __Pyx_INCREF(function);
    9893           0 :         __Pyx_DECREF_SET(__pyx_t_5, function);
    9894             :         __pyx_t_6 = 1;
    9895             :       }
    9896             :     }
    9897             :     #endif
    9898             :     {
    9899           0 :       PyObject *__pyx_callargs[3] = {__pyx_t_4, __pyx_t_1, __pyx_v_value};
    9900           0 :       __pyx_t_3 = __Pyx_PyObject_FastCall(__pyx_t_5, __pyx_callargs+1-__pyx_t_6, 2+__pyx_t_6);
    9901           0 :       __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    9902           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    9903           0 :       if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 516, __pyx_L1_error)
    9904           0 :       __Pyx_GOTREF(__pyx_t_3);
    9905           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    9906             :     }
    9907           0 :     if (!(likely(PyBytes_CheckExact(__pyx_t_3))||((__pyx_t_3) == Py_None) || __Pyx_RaiseUnexpectedTypeError("bytes", __pyx_t_3))) __PYX_ERR(1, 516, __pyx_L1_error)
    9908             :     __pyx_v_bytesvalue = ((PyObject*)__pyx_t_3);
    9909             :     __pyx_t_3 = 0;
    9910             :   }
    9911           0 :   __pyx_L3:;
    9912             : 
    9913             :   /* "View.MemoryView":518
    9914             :  *             bytesvalue = struct.pack(self.view.format, value)
    9915             :  * 
    9916             :  *         for i, c in enumerate(bytesvalue):             # <<<<<<<<<<<<<<
    9917             :  *             itemp[i] = c
    9918             :  * 
    9919             :  */
    9920           0 :   __pyx_t_7 = 0;
    9921           0 :   if (unlikely(__pyx_v_bytesvalue == Py_None)) {
    9922           0 :     PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable");
    9923           0 :     __PYX_ERR(1, 518, __pyx_L1_error)
    9924             :   }
    9925           0 :   __Pyx_INCREF(__pyx_v_bytesvalue);
    9926           0 :   __pyx_t_8 = __pyx_v_bytesvalue;
    9927           0 :   __pyx_t_10 = PyBytes_AS_STRING(__pyx_t_8);
    9928           0 :   __pyx_t_11 = (__pyx_t_10 + PyBytes_GET_SIZE(__pyx_t_8));
    9929           0 :   for (__pyx_t_12 = __pyx_t_10; __pyx_t_12 < __pyx_t_11; __pyx_t_12++) {
    9930           0 :     __pyx_t_9 = __pyx_t_12;
    9931           0 :     __pyx_v_c = (__pyx_t_9[0]);
    9932             : 
    9933             :     /* "View.MemoryView":519
    9934             :  * 
    9935             :  *         for i, c in enumerate(bytesvalue):
    9936             :  *             itemp[i] = c             # <<<<<<<<<<<<<<
    9937             :  * 
    9938             :  *     @cname('getbuffer')
    9939             :  */
    9940           0 :     __pyx_v_i = __pyx_t_7;
    9941             : 
    9942             :     /* "View.MemoryView":518
    9943             :  *             bytesvalue = struct.pack(self.view.format, value)
    9944             :  * 
    9945             :  *         for i, c in enumerate(bytesvalue):             # <<<<<<<<<<<<<<
    9946             :  *             itemp[i] = c
    9947             :  * 
    9948             :  */
    9949           0 :     __pyx_t_7 = (__pyx_t_7 + 1);
    9950             : 
    9951             :     /* "View.MemoryView":519
    9952             :  * 
    9953             :  *         for i, c in enumerate(bytesvalue):
    9954             :  *             itemp[i] = c             # <<<<<<<<<<<<<<
    9955             :  * 
    9956             :  *     @cname('getbuffer')
    9957             :  */
    9958           0 :     (__pyx_v_itemp[__pyx_v_i]) = __pyx_v_c;
    9959             :   }
    9960           0 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    9961             : 
    9962             :   /* "View.MemoryView":505
    9963             :  *             return result
    9964             :  * 
    9965             :  *     cdef assign_item_from_object(self, char *itemp, object value):             # <<<<<<<<<<<<<<
    9966             :  *         """Only used if instantiated manually by the user, or if Cython doesn't
    9967             :  *         know how to convert the type"""
    9968             :  */
    9969             : 
    9970             :   /* function exit code */
    9971           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
    9972           0 :   goto __pyx_L0;
    9973           0 :   __pyx_L1_error:;
    9974           0 :   __Pyx_XDECREF(__pyx_t_1);
    9975           0 :   __Pyx_XDECREF(__pyx_t_3);
    9976           0 :   __Pyx_XDECREF(__pyx_t_4);
    9977           0 :   __Pyx_XDECREF(__pyx_t_5);
    9978           0 :   __Pyx_XDECREF(__pyx_t_8);
    9979           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.assign_item_from_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
    9980           0 :   __pyx_r = 0;
    9981           0 :   __pyx_L0:;
    9982           0 :   __Pyx_XDECREF(__pyx_v_struct);
    9983           0 :   __Pyx_XDECREF(__pyx_v_bytesvalue);
    9984           0 :   __Pyx_XGIVEREF(__pyx_r);
    9985           0 :   __Pyx_RefNannyFinishContext();
    9986           0 :   return __pyx_r;
    9987             : }
    9988             : 
    9989             : /* "View.MemoryView":521
    9990             :  *             itemp[i] = c
    9991             :  * 
    9992             :  *     @cname('getbuffer')             # <<<<<<<<<<<<<<
    9993             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
    9994             :  *         if flags & PyBUF_WRITABLE and self.view.readonly:
    9995             :  */
    9996             : 
    9997             : /* Python wrapper */
    9998             : CYTHON_UNUSED static int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
    9999           0 : CYTHON_UNUSED static int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
   10000           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10001           0 :   int __pyx_r;
   10002             :   __Pyx_RefNannyDeclarations
   10003           0 :   __Pyx_RefNannySetupContext("__getbuffer__ (wrapper)", 0);
   10004           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10005           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(((struct __pyx_memoryview_obj *)__pyx_v_self), ((Py_buffer *)__pyx_v_info), ((int)__pyx_v_flags));
   10006             : 
   10007             :   /* function exit code */
   10008           0 :   __Pyx_RefNannyFinishContext();
   10009           0 :   return __pyx_r;
   10010             : }
   10011             : 
   10012           0 : static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(struct __pyx_memoryview_obj *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
   10013           0 :   int __pyx_r;
   10014             :   __Pyx_RefNannyDeclarations
   10015           0 :   int __pyx_t_1;
   10016           0 :   int __pyx_t_2;
   10017           0 :   Py_ssize_t *__pyx_t_3;
   10018           0 :   char *__pyx_t_4;
   10019           0 :   void *__pyx_t_5;
   10020           0 :   int __pyx_t_6;
   10021           0 :   Py_ssize_t __pyx_t_7;
   10022           0 :   int __pyx_lineno = 0;
   10023           0 :   const char *__pyx_filename = NULL;
   10024           0 :   int __pyx_clineno = 0;
   10025           0 :   if (unlikely(__pyx_v_info == NULL)) {
   10026           0 :     PyErr_SetString(PyExc_BufferError, "PyObject_GetBuffer: view==NULL argument is obsolete");
   10027           0 :     return -1;
   10028             :   }
   10029           0 :   __Pyx_RefNannySetupContext("__getbuffer__", 0);
   10030           0 :   __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
   10031           0 :   __Pyx_GIVEREF(__pyx_v_info->obj);
   10032             : 
   10033             :   /* "View.MemoryView":523
   10034             :  *     @cname('getbuffer')
   10035             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
   10036             :  *         if flags & PyBUF_WRITABLE and self.view.readonly:             # <<<<<<<<<<<<<<
   10037             :  *             raise ValueError, "Cannot create writable memory view from read-only memoryview"
   10038             :  * 
   10039             :  */
   10040           0 :   __pyx_t_2 = ((__pyx_v_flags & PyBUF_WRITABLE) != 0);
   10041           0 :   if (__pyx_t_2) {
   10042           0 :   } else {
   10043           0 :     __pyx_t_1 = __pyx_t_2;
   10044           0 :     goto __pyx_L4_bool_binop_done;
   10045             :   }
   10046           0 :   __pyx_t_1 = __pyx_v_self->view.readonly;
   10047           0 :   __pyx_L4_bool_binop_done:;
   10048           0 :   if (unlikely(__pyx_t_1)) {
   10049             : 
   10050             :     /* "View.MemoryView":524
   10051             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
   10052             :  *         if flags & PyBUF_WRITABLE and self.view.readonly:
   10053             :  *             raise ValueError, "Cannot create writable memory view from read-only memoryview"             # <<<<<<<<<<<<<<
   10054             :  * 
   10055             :  *         if flags & PyBUF_ND:
   10056             :  */
   10057           0 :     __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Cannot_create_writable_memory_vi, 0, 0);
   10058           0 :     __PYX_ERR(1, 524, __pyx_L1_error)
   10059             : 
   10060             :     /* "View.MemoryView":523
   10061             :  *     @cname('getbuffer')
   10062             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
   10063             :  *         if flags & PyBUF_WRITABLE and self.view.readonly:             # <<<<<<<<<<<<<<
   10064             :  *             raise ValueError, "Cannot create writable memory view from read-only memoryview"
   10065             :  * 
   10066             :  */
   10067             :   }
   10068             : 
   10069             :   /* "View.MemoryView":526
   10070             :  *             raise ValueError, "Cannot create writable memory view from read-only memoryview"
   10071             :  * 
   10072             :  *         if flags & PyBUF_ND:             # <<<<<<<<<<<<<<
   10073             :  *             info.shape = self.view.shape
   10074             :  *         else:
   10075             :  */
   10076           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_ND) != 0);
   10077           0 :   if (__pyx_t_1) {
   10078             : 
   10079             :     /* "View.MemoryView":527
   10080             :  * 
   10081             :  *         if flags & PyBUF_ND:
   10082             :  *             info.shape = self.view.shape             # <<<<<<<<<<<<<<
   10083             :  *         else:
   10084             :  *             info.shape = NULL
   10085             :  */
   10086           0 :     __pyx_t_3 = __pyx_v_self->view.shape;
   10087           0 :     __pyx_v_info->shape = __pyx_t_3;
   10088             : 
   10089             :     /* "View.MemoryView":526
   10090             :  *             raise ValueError, "Cannot create writable memory view from read-only memoryview"
   10091             :  * 
   10092             :  *         if flags & PyBUF_ND:             # <<<<<<<<<<<<<<
   10093             :  *             info.shape = self.view.shape
   10094             :  *         else:
   10095             :  */
   10096           0 :     goto __pyx_L6;
   10097             :   }
   10098             : 
   10099             :   /* "View.MemoryView":529
   10100             :  *             info.shape = self.view.shape
   10101             :  *         else:
   10102             :  *             info.shape = NULL             # <<<<<<<<<<<<<<
   10103             :  * 
   10104             :  *         if flags & PyBUF_STRIDES:
   10105             :  */
   10106             :   /*else*/ {
   10107           0 :     __pyx_v_info->shape = NULL;
   10108             :   }
   10109           0 :   __pyx_L6:;
   10110             : 
   10111             :   /* "View.MemoryView":531
   10112             :  *             info.shape = NULL
   10113             :  * 
   10114             :  *         if flags & PyBUF_STRIDES:             # <<<<<<<<<<<<<<
   10115             :  *             info.strides = self.view.strides
   10116             :  *         else:
   10117             :  */
   10118           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_STRIDES) != 0);
   10119           0 :   if (__pyx_t_1) {
   10120             : 
   10121             :     /* "View.MemoryView":532
   10122             :  * 
   10123             :  *         if flags & PyBUF_STRIDES:
   10124             :  *             info.strides = self.view.strides             # <<<<<<<<<<<<<<
   10125             :  *         else:
   10126             :  *             info.strides = NULL
   10127             :  */
   10128           0 :     __pyx_t_3 = __pyx_v_self->view.strides;
   10129           0 :     __pyx_v_info->strides = __pyx_t_3;
   10130             : 
   10131             :     /* "View.MemoryView":531
   10132             :  *             info.shape = NULL
   10133             :  * 
   10134             :  *         if flags & PyBUF_STRIDES:             # <<<<<<<<<<<<<<
   10135             :  *             info.strides = self.view.strides
   10136             :  *         else:
   10137             :  */
   10138           0 :     goto __pyx_L7;
   10139             :   }
   10140             : 
   10141             :   /* "View.MemoryView":534
   10142             :  *             info.strides = self.view.strides
   10143             :  *         else:
   10144             :  *             info.strides = NULL             # <<<<<<<<<<<<<<
   10145             :  * 
   10146             :  *         if flags & PyBUF_INDIRECT:
   10147             :  */
   10148             :   /*else*/ {
   10149           0 :     __pyx_v_info->strides = NULL;
   10150             :   }
   10151           0 :   __pyx_L7:;
   10152             : 
   10153             :   /* "View.MemoryView":536
   10154             :  *             info.strides = NULL
   10155             :  * 
   10156             :  *         if flags & PyBUF_INDIRECT:             # <<<<<<<<<<<<<<
   10157             :  *             info.suboffsets = self.view.suboffsets
   10158             :  *         else:
   10159             :  */
   10160           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_INDIRECT) != 0);
   10161           0 :   if (__pyx_t_1) {
   10162             : 
   10163             :     /* "View.MemoryView":537
   10164             :  * 
   10165             :  *         if flags & PyBUF_INDIRECT:
   10166             :  *             info.suboffsets = self.view.suboffsets             # <<<<<<<<<<<<<<
   10167             :  *         else:
   10168             :  *             info.suboffsets = NULL
   10169             :  */
   10170           0 :     __pyx_t_3 = __pyx_v_self->view.suboffsets;
   10171           0 :     __pyx_v_info->suboffsets = __pyx_t_3;
   10172             : 
   10173             :     /* "View.MemoryView":536
   10174             :  *             info.strides = NULL
   10175             :  * 
   10176             :  *         if flags & PyBUF_INDIRECT:             # <<<<<<<<<<<<<<
   10177             :  *             info.suboffsets = self.view.suboffsets
   10178             :  *         else:
   10179             :  */
   10180           0 :     goto __pyx_L8;
   10181             :   }
   10182             : 
   10183             :   /* "View.MemoryView":539
   10184             :  *             info.suboffsets = self.view.suboffsets
   10185             :  *         else:
   10186             :  *             info.suboffsets = NULL             # <<<<<<<<<<<<<<
   10187             :  * 
   10188             :  *         if flags & PyBUF_FORMAT:
   10189             :  */
   10190             :   /*else*/ {
   10191           0 :     __pyx_v_info->suboffsets = NULL;
   10192             :   }
   10193           0 :   __pyx_L8:;
   10194             : 
   10195             :   /* "View.MemoryView":541
   10196             :  *             info.suboffsets = NULL
   10197             :  * 
   10198             :  *         if flags & PyBUF_FORMAT:             # <<<<<<<<<<<<<<
   10199             :  *             info.format = self.view.format
   10200             :  *         else:
   10201             :  */
   10202           0 :   __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
   10203           0 :   if (__pyx_t_1) {
   10204             : 
   10205             :     /* "View.MemoryView":542
   10206             :  * 
   10207             :  *         if flags & PyBUF_FORMAT:
   10208             :  *             info.format = self.view.format             # <<<<<<<<<<<<<<
   10209             :  *         else:
   10210             :  *             info.format = NULL
   10211             :  */
   10212           0 :     __pyx_t_4 = __pyx_v_self->view.format;
   10213           0 :     __pyx_v_info->format = __pyx_t_4;
   10214             : 
   10215             :     /* "View.MemoryView":541
   10216             :  *             info.suboffsets = NULL
   10217             :  * 
   10218             :  *         if flags & PyBUF_FORMAT:             # <<<<<<<<<<<<<<
   10219             :  *             info.format = self.view.format
   10220             :  *         else:
   10221             :  */
   10222           0 :     goto __pyx_L9;
   10223             :   }
   10224             : 
   10225             :   /* "View.MemoryView":544
   10226             :  *             info.format = self.view.format
   10227             :  *         else:
   10228             :  *             info.format = NULL             # <<<<<<<<<<<<<<
   10229             :  * 
   10230             :  *         info.buf = self.view.buf
   10231             :  */
   10232             :   /*else*/ {
   10233           0 :     __pyx_v_info->format = NULL;
   10234             :   }
   10235           0 :   __pyx_L9:;
   10236             : 
   10237             :   /* "View.MemoryView":546
   10238             :  *             info.format = NULL
   10239             :  * 
   10240             :  *         info.buf = self.view.buf             # <<<<<<<<<<<<<<
   10241             :  *         info.ndim = self.view.ndim
   10242             :  *         info.itemsize = self.view.itemsize
   10243             :  */
   10244           0 :   __pyx_t_5 = __pyx_v_self->view.buf;
   10245           0 :   __pyx_v_info->buf = __pyx_t_5;
   10246             : 
   10247             :   /* "View.MemoryView":547
   10248             :  * 
   10249             :  *         info.buf = self.view.buf
   10250             :  *         info.ndim = self.view.ndim             # <<<<<<<<<<<<<<
   10251             :  *         info.itemsize = self.view.itemsize
   10252             :  *         info.len = self.view.len
   10253             :  */
   10254           0 :   __pyx_t_6 = __pyx_v_self->view.ndim;
   10255           0 :   __pyx_v_info->ndim = __pyx_t_6;
   10256             : 
   10257             :   /* "View.MemoryView":548
   10258             :  *         info.buf = self.view.buf
   10259             :  *         info.ndim = self.view.ndim
   10260             :  *         info.itemsize = self.view.itemsize             # <<<<<<<<<<<<<<
   10261             :  *         info.len = self.view.len
   10262             :  *         info.readonly = self.view.readonly
   10263             :  */
   10264           0 :   __pyx_t_7 = __pyx_v_self->view.itemsize;
   10265           0 :   __pyx_v_info->itemsize = __pyx_t_7;
   10266             : 
   10267             :   /* "View.MemoryView":549
   10268             :  *         info.ndim = self.view.ndim
   10269             :  *         info.itemsize = self.view.itemsize
   10270             :  *         info.len = self.view.len             # <<<<<<<<<<<<<<
   10271             :  *         info.readonly = self.view.readonly
   10272             :  *         info.obj = self
   10273             :  */
   10274           0 :   __pyx_t_7 = __pyx_v_self->view.len;
   10275           0 :   __pyx_v_info->len = __pyx_t_7;
   10276             : 
   10277             :   /* "View.MemoryView":550
   10278             :  *         info.itemsize = self.view.itemsize
   10279             :  *         info.len = self.view.len
   10280             :  *         info.readonly = self.view.readonly             # <<<<<<<<<<<<<<
   10281             :  *         info.obj = self
   10282             :  * 
   10283             :  */
   10284           0 :   __pyx_t_1 = __pyx_v_self->view.readonly;
   10285           0 :   __pyx_v_info->readonly = __pyx_t_1;
   10286             : 
   10287             :   /* "View.MemoryView":551
   10288             :  *         info.len = self.view.len
   10289             :  *         info.readonly = self.view.readonly
   10290             :  *         info.obj = self             # <<<<<<<<<<<<<<
   10291             :  * 
   10292             :  * 
   10293             :  */
   10294           0 :   __Pyx_INCREF((PyObject *)__pyx_v_self);
   10295           0 :   __Pyx_GIVEREF((PyObject *)__pyx_v_self);
   10296           0 :   __Pyx_GOTREF(__pyx_v_info->obj);
   10297           0 :   __Pyx_DECREF(__pyx_v_info->obj);
   10298           0 :   __pyx_v_info->obj = ((PyObject *)__pyx_v_self);
   10299             : 
   10300             :   /* "View.MemoryView":521
   10301             :  *             itemp[i] = c
   10302             :  * 
   10303             :  *     @cname('getbuffer')             # <<<<<<<<<<<<<<
   10304             :  *     def __getbuffer__(self, Py_buffer *info, int flags):
   10305             :  *         if flags & PyBUF_WRITABLE and self.view.readonly:
   10306             :  */
   10307             : 
   10308             :   /* function exit code */
   10309           0 :   __pyx_r = 0;
   10310           0 :   goto __pyx_L0;
   10311           0 :   __pyx_L1_error:;
   10312           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__getbuffer__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10313           0 :   __pyx_r = -1;
   10314           0 :   if (__pyx_v_info->obj != NULL) {
   10315           0 :     __Pyx_GOTREF(__pyx_v_info->obj);
   10316           0 :     __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
   10317             :   }
   10318           0 :   goto __pyx_L2;
   10319           0 :   __pyx_L0:;
   10320           0 :   if (__pyx_v_info->obj == Py_None) {
   10321           0 :     __Pyx_GOTREF(__pyx_v_info->obj);
   10322           0 :     __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
   10323             :   }
   10324           0 :   __pyx_L2:;
   10325             :   __Pyx_RefNannyFinishContext();
   10326             :   return __pyx_r;
   10327             : }
   10328             : 
   10329             : /* "View.MemoryView":554
   10330             :  * 
   10331             :  * 
   10332             :  *     @property             # <<<<<<<<<<<<<<
   10333             :  *     def T(self):
   10334             :  *         cdef _memoryviewslice result = memoryview_copy(self)
   10335             :  */
   10336             : 
   10337             : /* Python wrapper */
   10338             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(PyObject *__pyx_v_self); /*proto*/
   10339           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(PyObject *__pyx_v_self) {
   10340           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10341           0 :   PyObject *__pyx_r = 0;
   10342             :   __Pyx_RefNannyDeclarations
   10343           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10344           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10345           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10346             : 
   10347             :   /* function exit code */
   10348           0 :   __Pyx_RefNannyFinishContext();
   10349           0 :   return __pyx_r;
   10350             : }
   10351             : 
   10352           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10353           0 :   struct __pyx_memoryviewslice_obj *__pyx_v_result = 0;
   10354           0 :   PyObject *__pyx_r = NULL;
   10355             :   __Pyx_RefNannyDeclarations
   10356           0 :   PyObject *__pyx_t_1 = NULL;
   10357           0 :   int __pyx_t_2;
   10358           0 :   int __pyx_lineno = 0;
   10359           0 :   const char *__pyx_filename = NULL;
   10360           0 :   int __pyx_clineno = 0;
   10361           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10362             : 
   10363             :   /* "View.MemoryView":556
   10364             :  *     @property
   10365             :  *     def T(self):
   10366             :  *         cdef _memoryviewslice result = memoryview_copy(self)             # <<<<<<<<<<<<<<
   10367             :  *         transpose_memslice(&result.from_slice)
   10368             :  *         return result
   10369             :  */
   10370           0 :   __pyx_t_1 = __pyx_memoryview_copy_object(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 556, __pyx_L1_error)
   10371           0 :   __Pyx_GOTREF(__pyx_t_1);
   10372           0 :   if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_memoryviewslice_type))))) __PYX_ERR(1, 556, __pyx_L1_error)
   10373           0 :   __pyx_v_result = ((struct __pyx_memoryviewslice_obj *)__pyx_t_1);
   10374           0 :   __pyx_t_1 = 0;
   10375             : 
   10376             :   /* "View.MemoryView":557
   10377             :  *     def T(self):
   10378             :  *         cdef _memoryviewslice result = memoryview_copy(self)
   10379             :  *         transpose_memslice(&result.from_slice)             # <<<<<<<<<<<<<<
   10380             :  *         return result
   10381             :  * 
   10382             :  */
   10383           0 :   __pyx_t_2 = __pyx_memslice_transpose((&__pyx_v_result->from_slice)); if (unlikely(__pyx_t_2 == ((int)-1))) __PYX_ERR(1, 557, __pyx_L1_error)
   10384             : 
   10385             :   /* "View.MemoryView":558
   10386             :  *         cdef _memoryviewslice result = memoryview_copy(self)
   10387             :  *         transpose_memslice(&result.from_slice)
   10388             :  *         return result             # <<<<<<<<<<<<<<
   10389             :  * 
   10390             :  *     @property
   10391             :  */
   10392           0 :   __Pyx_XDECREF(__pyx_r);
   10393           0 :   __Pyx_INCREF((PyObject *)__pyx_v_result);
   10394           0 :   __pyx_r = ((PyObject *)__pyx_v_result);
   10395           0 :   goto __pyx_L0;
   10396             : 
   10397             :   /* "View.MemoryView":554
   10398             :  * 
   10399             :  * 
   10400             :  *     @property             # <<<<<<<<<<<<<<
   10401             :  *     def T(self):
   10402             :  *         cdef _memoryviewslice result = memoryview_copy(self)
   10403             :  */
   10404             : 
   10405             :   /* function exit code */
   10406           0 :   __pyx_L1_error:;
   10407           0 :   __Pyx_XDECREF(__pyx_t_1);
   10408           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.T.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10409           0 :   __pyx_r = NULL;
   10410           0 :   __pyx_L0:;
   10411           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_result);
   10412           0 :   __Pyx_XGIVEREF(__pyx_r);
   10413           0 :   __Pyx_RefNannyFinishContext();
   10414           0 :   return __pyx_r;
   10415             : }
   10416             : 
   10417             : /* "View.MemoryView":560
   10418             :  *         return result
   10419             :  * 
   10420             :  *     @property             # <<<<<<<<<<<<<<
   10421             :  *     def base(self):
   10422             :  *         return self._get_base()
   10423             :  */
   10424             : 
   10425             : /* Python wrapper */
   10426             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(PyObject *__pyx_v_self); /*proto*/
   10427           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(PyObject *__pyx_v_self) {
   10428           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10429           0 :   PyObject *__pyx_r = 0;
   10430             :   __Pyx_RefNannyDeclarations
   10431           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10432           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10433           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10434             : 
   10435             :   /* function exit code */
   10436           0 :   __Pyx_RefNannyFinishContext();
   10437           0 :   return __pyx_r;
   10438             : }
   10439             : 
   10440           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10441           0 :   PyObject *__pyx_r = NULL;
   10442             :   __Pyx_RefNannyDeclarations
   10443           0 :   PyObject *__pyx_t_1 = NULL;
   10444           0 :   int __pyx_lineno = 0;
   10445           0 :   const char *__pyx_filename = NULL;
   10446           0 :   int __pyx_clineno = 0;
   10447           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10448             : 
   10449             :   /* "View.MemoryView":562
   10450             :  *     @property
   10451             :  *     def base(self):
   10452             :  *         return self._get_base()             # <<<<<<<<<<<<<<
   10453             :  * 
   10454             :  *     cdef _get_base(self):
   10455             :  */
   10456           0 :   __Pyx_XDECREF(__pyx_r);
   10457           0 :   __pyx_t_1 = ((struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->_get_base(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 562, __pyx_L1_error)
   10458           0 :   __Pyx_GOTREF(__pyx_t_1);
   10459           0 :   __pyx_r = __pyx_t_1;
   10460           0 :   __pyx_t_1 = 0;
   10461           0 :   goto __pyx_L0;
   10462             : 
   10463             :   /* "View.MemoryView":560
   10464             :  *         return result
   10465             :  * 
   10466             :  *     @property             # <<<<<<<<<<<<<<
   10467             :  *     def base(self):
   10468             :  *         return self._get_base()
   10469             :  */
   10470             : 
   10471             :   /* function exit code */
   10472           0 :   __pyx_L1_error:;
   10473           0 :   __Pyx_XDECREF(__pyx_t_1);
   10474           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.base.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10475           0 :   __pyx_r = NULL;
   10476           0 :   __pyx_L0:;
   10477           0 :   __Pyx_XGIVEREF(__pyx_r);
   10478           0 :   __Pyx_RefNannyFinishContext();
   10479           0 :   return __pyx_r;
   10480             : }
   10481             : 
   10482             : /* "View.MemoryView":564
   10483             :  *         return self._get_base()
   10484             :  * 
   10485             :  *     cdef _get_base(self):             # <<<<<<<<<<<<<<
   10486             :  *         return self.obj
   10487             :  * 
   10488             :  */
   10489             : 
   10490           0 : static PyObject *__pyx_memoryview__get_base(struct __pyx_memoryview_obj *__pyx_v_self) {
   10491           0 :   PyObject *__pyx_r = NULL;
   10492             :   __Pyx_RefNannyDeclarations
   10493           0 :   __Pyx_RefNannySetupContext("_get_base", 1);
   10494             : 
   10495             :   /* "View.MemoryView":565
   10496             :  * 
   10497             :  *     cdef _get_base(self):
   10498             :  *         return self.obj             # <<<<<<<<<<<<<<
   10499             :  * 
   10500             :  *     @property
   10501             :  */
   10502           0 :   __Pyx_XDECREF(__pyx_r);
   10503           0 :   __Pyx_INCREF(__pyx_v_self->obj);
   10504           0 :   __pyx_r = __pyx_v_self->obj;
   10505           0 :   goto __pyx_L0;
   10506             : 
   10507             :   /* "View.MemoryView":564
   10508             :  *         return self._get_base()
   10509             :  * 
   10510             :  *     cdef _get_base(self):             # <<<<<<<<<<<<<<
   10511             :  *         return self.obj
   10512             :  * 
   10513             :  */
   10514             : 
   10515             :   /* function exit code */
   10516           0 :   __pyx_L0:;
   10517           0 :   __Pyx_XGIVEREF(__pyx_r);
   10518           0 :   __Pyx_RefNannyFinishContext();
   10519           0 :   return __pyx_r;
   10520             : }
   10521             : 
   10522             : /* "View.MemoryView":567
   10523             :  *         return self.obj
   10524             :  * 
   10525             :  *     @property             # <<<<<<<<<<<<<<
   10526             :  *     def shape(self):
   10527             :  *         return tuple([length for length in self.view.shape[:self.view.ndim]])
   10528             :  */
   10529             : 
   10530             : /* Python wrapper */
   10531             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(PyObject *__pyx_v_self); /*proto*/
   10532           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(PyObject *__pyx_v_self) {
   10533           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10534           0 :   PyObject *__pyx_r = 0;
   10535             :   __Pyx_RefNannyDeclarations
   10536           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10537           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10538           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10539             : 
   10540             :   /* function exit code */
   10541           0 :   __Pyx_RefNannyFinishContext();
   10542           0 :   return __pyx_r;
   10543             : }
   10544             : 
   10545           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10546           0 :   Py_ssize_t __pyx_7genexpr__pyx_v_length;
   10547           0 :   PyObject *__pyx_r = NULL;
   10548             :   __Pyx_RefNannyDeclarations
   10549           0 :   PyObject *__pyx_t_1 = NULL;
   10550           0 :   Py_ssize_t *__pyx_t_2;
   10551           0 :   Py_ssize_t *__pyx_t_3;
   10552           0 :   Py_ssize_t *__pyx_t_4;
   10553           0 :   PyObject *__pyx_t_5 = NULL;
   10554           0 :   int __pyx_lineno = 0;
   10555           0 :   const char *__pyx_filename = NULL;
   10556           0 :   int __pyx_clineno = 0;
   10557           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10558             : 
   10559             :   /* "View.MemoryView":569
   10560             :  *     @property
   10561             :  *     def shape(self):
   10562             :  *         return tuple([length for length in self.view.shape[:self.view.ndim]])             # <<<<<<<<<<<<<<
   10563             :  * 
   10564             :  *     @property
   10565             :  */
   10566           0 :   __Pyx_XDECREF(__pyx_r);
   10567             :   { /* enter inner scope */
   10568           0 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 569, __pyx_L1_error)
   10569           0 :     __Pyx_GOTREF(__pyx_t_1);
   10570           0 :     __pyx_t_3 = (__pyx_v_self->view.shape + __pyx_v_self->view.ndim);
   10571           0 :     for (__pyx_t_4 = __pyx_v_self->view.shape; __pyx_t_4 < __pyx_t_3; __pyx_t_4++) {
   10572           0 :       __pyx_t_2 = __pyx_t_4;
   10573           0 :       __pyx_7genexpr__pyx_v_length = (__pyx_t_2[0]);
   10574           0 :       __pyx_t_5 = PyInt_FromSsize_t(__pyx_7genexpr__pyx_v_length); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 569, __pyx_L1_error)
   10575           0 :       __Pyx_GOTREF(__pyx_t_5);
   10576           0 :       if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_t_5))) __PYX_ERR(1, 569, __pyx_L1_error)
   10577           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   10578             :     }
   10579             :   } /* exit inner scope */
   10580           0 :   __pyx_t_5 = PyList_AsTuple(((PyObject*)__pyx_t_1)); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 569, __pyx_L1_error)
   10581           0 :   __Pyx_GOTREF(__pyx_t_5);
   10582           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   10583           0 :   __pyx_r = __pyx_t_5;
   10584           0 :   __pyx_t_5 = 0;
   10585           0 :   goto __pyx_L0;
   10586             : 
   10587             :   /* "View.MemoryView":567
   10588             :  *         return self.obj
   10589             :  * 
   10590             :  *     @property             # <<<<<<<<<<<<<<
   10591             :  *     def shape(self):
   10592             :  *         return tuple([length for length in self.view.shape[:self.view.ndim]])
   10593             :  */
   10594             : 
   10595             :   /* function exit code */
   10596           0 :   __pyx_L1_error:;
   10597           0 :   __Pyx_XDECREF(__pyx_t_1);
   10598           0 :   __Pyx_XDECREF(__pyx_t_5);
   10599           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.shape.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10600           0 :   __pyx_r = NULL;
   10601           0 :   __pyx_L0:;
   10602           0 :   __Pyx_XGIVEREF(__pyx_r);
   10603           0 :   __Pyx_RefNannyFinishContext();
   10604           0 :   return __pyx_r;
   10605             : }
   10606             : 
   10607             : /* "View.MemoryView":571
   10608             :  *         return tuple([length for length in self.view.shape[:self.view.ndim]])
   10609             :  * 
   10610             :  *     @property             # <<<<<<<<<<<<<<
   10611             :  *     def strides(self):
   10612             :  *         if self.view.strides == NULL:
   10613             :  */
   10614             : 
   10615             : /* Python wrapper */
   10616             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(PyObject *__pyx_v_self); /*proto*/
   10617           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(PyObject *__pyx_v_self) {
   10618           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10619           0 :   PyObject *__pyx_r = 0;
   10620             :   __Pyx_RefNannyDeclarations
   10621           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10622           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10623           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10624             : 
   10625             :   /* function exit code */
   10626           0 :   __Pyx_RefNannyFinishContext();
   10627           0 :   return __pyx_r;
   10628             : }
   10629             : 
   10630           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10631           0 :   Py_ssize_t __pyx_8genexpr1__pyx_v_stride;
   10632           0 :   PyObject *__pyx_r = NULL;
   10633             :   __Pyx_RefNannyDeclarations
   10634           0 :   int __pyx_t_1;
   10635           0 :   PyObject *__pyx_t_2 = NULL;
   10636           0 :   Py_ssize_t *__pyx_t_3;
   10637           0 :   Py_ssize_t *__pyx_t_4;
   10638           0 :   Py_ssize_t *__pyx_t_5;
   10639           0 :   PyObject *__pyx_t_6 = NULL;
   10640           0 :   int __pyx_lineno = 0;
   10641           0 :   const char *__pyx_filename = NULL;
   10642           0 :   int __pyx_clineno = 0;
   10643           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10644             : 
   10645             :   /* "View.MemoryView":573
   10646             :  *     @property
   10647             :  *     def strides(self):
   10648             :  *         if self.view.strides == NULL:             # <<<<<<<<<<<<<<
   10649             :  * 
   10650             :  *             raise ValueError, "Buffer view does not expose strides"
   10651             :  */
   10652           0 :   __pyx_t_1 = (__pyx_v_self->view.strides == NULL);
   10653           0 :   if (unlikely(__pyx_t_1)) {
   10654             : 
   10655             :     /* "View.MemoryView":575
   10656             :  *         if self.view.strides == NULL:
   10657             :  * 
   10658             :  *             raise ValueError, "Buffer view does not expose strides"             # <<<<<<<<<<<<<<
   10659             :  * 
   10660             :  *         return tuple([stride for stride in self.view.strides[:self.view.ndim]])
   10661             :  */
   10662           0 :     __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Buffer_view_does_not_expose_stri, 0, 0);
   10663           0 :     __PYX_ERR(1, 575, __pyx_L1_error)
   10664             : 
   10665             :     /* "View.MemoryView":573
   10666             :  *     @property
   10667             :  *     def strides(self):
   10668             :  *         if self.view.strides == NULL:             # <<<<<<<<<<<<<<
   10669             :  * 
   10670             :  *             raise ValueError, "Buffer view does not expose strides"
   10671             :  */
   10672             :   }
   10673             : 
   10674             :   /* "View.MemoryView":577
   10675             :  *             raise ValueError, "Buffer view does not expose strides"
   10676             :  * 
   10677             :  *         return tuple([stride for stride in self.view.strides[:self.view.ndim]])             # <<<<<<<<<<<<<<
   10678             :  * 
   10679             :  *     @property
   10680             :  */
   10681           0 :   __Pyx_XDECREF(__pyx_r);
   10682             :   { /* enter inner scope */
   10683           0 :     __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 577, __pyx_L1_error)
   10684           0 :     __Pyx_GOTREF(__pyx_t_2);
   10685           0 :     __pyx_t_4 = (__pyx_v_self->view.strides + __pyx_v_self->view.ndim);
   10686           0 :     for (__pyx_t_5 = __pyx_v_self->view.strides; __pyx_t_5 < __pyx_t_4; __pyx_t_5++) {
   10687           0 :       __pyx_t_3 = __pyx_t_5;
   10688           0 :       __pyx_8genexpr1__pyx_v_stride = (__pyx_t_3[0]);
   10689           0 :       __pyx_t_6 = PyInt_FromSsize_t(__pyx_8genexpr1__pyx_v_stride); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 577, __pyx_L1_error)
   10690           0 :       __Pyx_GOTREF(__pyx_t_6);
   10691           0 :       if (unlikely(__Pyx_ListComp_Append(__pyx_t_2, (PyObject*)__pyx_t_6))) __PYX_ERR(1, 577, __pyx_L1_error)
   10692           0 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   10693             :     }
   10694             :   } /* exit inner scope */
   10695           0 :   __pyx_t_6 = PyList_AsTuple(((PyObject*)__pyx_t_2)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 577, __pyx_L1_error)
   10696           0 :   __Pyx_GOTREF(__pyx_t_6);
   10697           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   10698           0 :   __pyx_r = __pyx_t_6;
   10699           0 :   __pyx_t_6 = 0;
   10700           0 :   goto __pyx_L0;
   10701             : 
   10702             :   /* "View.MemoryView":571
   10703             :  *         return tuple([length for length in self.view.shape[:self.view.ndim]])
   10704             :  * 
   10705             :  *     @property             # <<<<<<<<<<<<<<
   10706             :  *     def strides(self):
   10707             :  *         if self.view.strides == NULL:
   10708             :  */
   10709             : 
   10710             :   /* function exit code */
   10711           0 :   __pyx_L1_error:;
   10712           0 :   __Pyx_XDECREF(__pyx_t_2);
   10713           0 :   __Pyx_XDECREF(__pyx_t_6);
   10714           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.strides.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10715           0 :   __pyx_r = NULL;
   10716           0 :   __pyx_L0:;
   10717           0 :   __Pyx_XGIVEREF(__pyx_r);
   10718           0 :   __Pyx_RefNannyFinishContext();
   10719           0 :   return __pyx_r;
   10720             : }
   10721             : 
   10722             : /* "View.MemoryView":579
   10723             :  *         return tuple([stride for stride in self.view.strides[:self.view.ndim]])
   10724             :  * 
   10725             :  *     @property             # <<<<<<<<<<<<<<
   10726             :  *     def suboffsets(self):
   10727             :  *         if self.view.suboffsets == NULL:
   10728             :  */
   10729             : 
   10730             : /* Python wrapper */
   10731             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(PyObject *__pyx_v_self); /*proto*/
   10732           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(PyObject *__pyx_v_self) {
   10733           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10734           0 :   PyObject *__pyx_r = 0;
   10735             :   __Pyx_RefNannyDeclarations
   10736           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10737           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10738           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10739             : 
   10740             :   /* function exit code */
   10741           0 :   __Pyx_RefNannyFinishContext();
   10742           0 :   return __pyx_r;
   10743             : }
   10744             : 
   10745           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10746           0 :   Py_ssize_t __pyx_8genexpr2__pyx_v_suboffset;
   10747           0 :   PyObject *__pyx_r = NULL;
   10748             :   __Pyx_RefNannyDeclarations
   10749           0 :   int __pyx_t_1;
   10750           0 :   PyObject *__pyx_t_2 = NULL;
   10751           0 :   Py_ssize_t *__pyx_t_3;
   10752           0 :   Py_ssize_t *__pyx_t_4;
   10753           0 :   Py_ssize_t *__pyx_t_5;
   10754           0 :   PyObject *__pyx_t_6 = NULL;
   10755           0 :   int __pyx_lineno = 0;
   10756           0 :   const char *__pyx_filename = NULL;
   10757           0 :   int __pyx_clineno = 0;
   10758           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10759             : 
   10760             :   /* "View.MemoryView":581
   10761             :  *     @property
   10762             :  *     def suboffsets(self):
   10763             :  *         if self.view.suboffsets == NULL:             # <<<<<<<<<<<<<<
   10764             :  *             return (-1,) * self.view.ndim
   10765             :  * 
   10766             :  */
   10767           0 :   __pyx_t_1 = (__pyx_v_self->view.suboffsets == NULL);
   10768           0 :   if (__pyx_t_1) {
   10769             : 
   10770             :     /* "View.MemoryView":582
   10771             :  *     def suboffsets(self):
   10772             :  *         if self.view.suboffsets == NULL:
   10773             :  *             return (-1,) * self.view.ndim             # <<<<<<<<<<<<<<
   10774             :  * 
   10775             :  *         return tuple([suboffset for suboffset in self.view.suboffsets[:self.view.ndim]])
   10776             :  */
   10777           0 :     __Pyx_XDECREF(__pyx_r);
   10778           0 :     __pyx_t_2 = __Pyx_PySequence_Multiply(__pyx_tuple__4, __pyx_v_self->view.ndim); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 582, __pyx_L1_error)
   10779           0 :     __Pyx_GOTREF(__pyx_t_2);
   10780           0 :     __pyx_r = __pyx_t_2;
   10781           0 :     __pyx_t_2 = 0;
   10782           0 :     goto __pyx_L0;
   10783             : 
   10784             :     /* "View.MemoryView":581
   10785             :  *     @property
   10786             :  *     def suboffsets(self):
   10787             :  *         if self.view.suboffsets == NULL:             # <<<<<<<<<<<<<<
   10788             :  *             return (-1,) * self.view.ndim
   10789             :  * 
   10790             :  */
   10791             :   }
   10792             : 
   10793             :   /* "View.MemoryView":584
   10794             :  *             return (-1,) * self.view.ndim
   10795             :  * 
   10796             :  *         return tuple([suboffset for suboffset in self.view.suboffsets[:self.view.ndim]])             # <<<<<<<<<<<<<<
   10797             :  * 
   10798             :  *     @property
   10799             :  */
   10800           0 :   __Pyx_XDECREF(__pyx_r);
   10801             :   { /* enter inner scope */
   10802           0 :     __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 584, __pyx_L1_error)
   10803           0 :     __Pyx_GOTREF(__pyx_t_2);
   10804           0 :     __pyx_t_4 = (__pyx_v_self->view.suboffsets + __pyx_v_self->view.ndim);
   10805           0 :     for (__pyx_t_5 = __pyx_v_self->view.suboffsets; __pyx_t_5 < __pyx_t_4; __pyx_t_5++) {
   10806           0 :       __pyx_t_3 = __pyx_t_5;
   10807           0 :       __pyx_8genexpr2__pyx_v_suboffset = (__pyx_t_3[0]);
   10808           0 :       __pyx_t_6 = PyInt_FromSsize_t(__pyx_8genexpr2__pyx_v_suboffset); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 584, __pyx_L1_error)
   10809           0 :       __Pyx_GOTREF(__pyx_t_6);
   10810           0 :       if (unlikely(__Pyx_ListComp_Append(__pyx_t_2, (PyObject*)__pyx_t_6))) __PYX_ERR(1, 584, __pyx_L1_error)
   10811           0 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   10812             :     }
   10813             :   } /* exit inner scope */
   10814           0 :   __pyx_t_6 = PyList_AsTuple(((PyObject*)__pyx_t_2)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 584, __pyx_L1_error)
   10815           0 :   __Pyx_GOTREF(__pyx_t_6);
   10816           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   10817           0 :   __pyx_r = __pyx_t_6;
   10818           0 :   __pyx_t_6 = 0;
   10819           0 :   goto __pyx_L0;
   10820             : 
   10821             :   /* "View.MemoryView":579
   10822             :  *         return tuple([stride for stride in self.view.strides[:self.view.ndim]])
   10823             :  * 
   10824             :  *     @property             # <<<<<<<<<<<<<<
   10825             :  *     def suboffsets(self):
   10826             :  *         if self.view.suboffsets == NULL:
   10827             :  */
   10828             : 
   10829             :   /* function exit code */
   10830           0 :   __pyx_L1_error:;
   10831           0 :   __Pyx_XDECREF(__pyx_t_2);
   10832           0 :   __Pyx_XDECREF(__pyx_t_6);
   10833           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.suboffsets.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10834           0 :   __pyx_r = NULL;
   10835           0 :   __pyx_L0:;
   10836           0 :   __Pyx_XGIVEREF(__pyx_r);
   10837           0 :   __Pyx_RefNannyFinishContext();
   10838           0 :   return __pyx_r;
   10839             : }
   10840             : 
   10841             : /* "View.MemoryView":586
   10842             :  *         return tuple([suboffset for suboffset in self.view.suboffsets[:self.view.ndim]])
   10843             :  * 
   10844             :  *     @property             # <<<<<<<<<<<<<<
   10845             :  *     def ndim(self):
   10846             :  *         return self.view.ndim
   10847             :  */
   10848             : 
   10849             : /* Python wrapper */
   10850             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(PyObject *__pyx_v_self); /*proto*/
   10851           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(PyObject *__pyx_v_self) {
   10852           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10853           0 :   PyObject *__pyx_r = 0;
   10854             :   __Pyx_RefNannyDeclarations
   10855           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10856           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10857           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10858             : 
   10859             :   /* function exit code */
   10860           0 :   __Pyx_RefNannyFinishContext();
   10861           0 :   return __pyx_r;
   10862             : }
   10863             : 
   10864           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10865           0 :   PyObject *__pyx_r = NULL;
   10866             :   __Pyx_RefNannyDeclarations
   10867           0 :   PyObject *__pyx_t_1 = NULL;
   10868           0 :   int __pyx_lineno = 0;
   10869           0 :   const char *__pyx_filename = NULL;
   10870           0 :   int __pyx_clineno = 0;
   10871           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10872             : 
   10873             :   /* "View.MemoryView":588
   10874             :  *     @property
   10875             :  *     def ndim(self):
   10876             :  *         return self.view.ndim             # <<<<<<<<<<<<<<
   10877             :  * 
   10878             :  *     @property
   10879             :  */
   10880           0 :   __Pyx_XDECREF(__pyx_r);
   10881           0 :   __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->view.ndim); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 588, __pyx_L1_error)
   10882           0 :   __Pyx_GOTREF(__pyx_t_1);
   10883           0 :   __pyx_r = __pyx_t_1;
   10884           0 :   __pyx_t_1 = 0;
   10885           0 :   goto __pyx_L0;
   10886             : 
   10887             :   /* "View.MemoryView":586
   10888             :  *         return tuple([suboffset for suboffset in self.view.suboffsets[:self.view.ndim]])
   10889             :  * 
   10890             :  *     @property             # <<<<<<<<<<<<<<
   10891             :  *     def ndim(self):
   10892             :  *         return self.view.ndim
   10893             :  */
   10894             : 
   10895             :   /* function exit code */
   10896           0 :   __pyx_L1_error:;
   10897           0 :   __Pyx_XDECREF(__pyx_t_1);
   10898           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.ndim.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10899           0 :   __pyx_r = NULL;
   10900           0 :   __pyx_L0:;
   10901           0 :   __Pyx_XGIVEREF(__pyx_r);
   10902           0 :   __Pyx_RefNannyFinishContext();
   10903           0 :   return __pyx_r;
   10904             : }
   10905             : 
   10906             : /* "View.MemoryView":590
   10907             :  *         return self.view.ndim
   10908             :  * 
   10909             :  *     @property             # <<<<<<<<<<<<<<
   10910             :  *     def itemsize(self):
   10911             :  *         return self.view.itemsize
   10912             :  */
   10913             : 
   10914             : /* Python wrapper */
   10915             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(PyObject *__pyx_v_self); /*proto*/
   10916           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(PyObject *__pyx_v_self) {
   10917           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10918           0 :   PyObject *__pyx_r = 0;
   10919             :   __Pyx_RefNannyDeclarations
   10920           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10921           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10922           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10923             : 
   10924             :   /* function exit code */
   10925           0 :   __Pyx_RefNannyFinishContext();
   10926           0 :   return __pyx_r;
   10927             : }
   10928             : 
   10929           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10930           0 :   PyObject *__pyx_r = NULL;
   10931             :   __Pyx_RefNannyDeclarations
   10932           0 :   PyObject *__pyx_t_1 = NULL;
   10933           0 :   int __pyx_lineno = 0;
   10934           0 :   const char *__pyx_filename = NULL;
   10935           0 :   int __pyx_clineno = 0;
   10936           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   10937             : 
   10938             :   /* "View.MemoryView":592
   10939             :  *     @property
   10940             :  *     def itemsize(self):
   10941             :  *         return self.view.itemsize             # <<<<<<<<<<<<<<
   10942             :  * 
   10943             :  *     @property
   10944             :  */
   10945           0 :   __Pyx_XDECREF(__pyx_r);
   10946           0 :   __pyx_t_1 = PyInt_FromSsize_t(__pyx_v_self->view.itemsize); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 592, __pyx_L1_error)
   10947           0 :   __Pyx_GOTREF(__pyx_t_1);
   10948           0 :   __pyx_r = __pyx_t_1;
   10949           0 :   __pyx_t_1 = 0;
   10950           0 :   goto __pyx_L0;
   10951             : 
   10952             :   /* "View.MemoryView":590
   10953             :  *         return self.view.ndim
   10954             :  * 
   10955             :  *     @property             # <<<<<<<<<<<<<<
   10956             :  *     def itemsize(self):
   10957             :  *         return self.view.itemsize
   10958             :  */
   10959             : 
   10960             :   /* function exit code */
   10961           0 :   __pyx_L1_error:;
   10962           0 :   __Pyx_XDECREF(__pyx_t_1);
   10963           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.itemsize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   10964           0 :   __pyx_r = NULL;
   10965           0 :   __pyx_L0:;
   10966           0 :   __Pyx_XGIVEREF(__pyx_r);
   10967           0 :   __Pyx_RefNannyFinishContext();
   10968           0 :   return __pyx_r;
   10969             : }
   10970             : 
   10971             : /* "View.MemoryView":594
   10972             :  *         return self.view.itemsize
   10973             :  * 
   10974             :  *     @property             # <<<<<<<<<<<<<<
   10975             :  *     def nbytes(self):
   10976             :  *         return self.size * self.view.itemsize
   10977             :  */
   10978             : 
   10979             : /* Python wrapper */
   10980             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(PyObject *__pyx_v_self); /*proto*/
   10981           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(PyObject *__pyx_v_self) {
   10982           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   10983           0 :   PyObject *__pyx_r = 0;
   10984             :   __Pyx_RefNannyDeclarations
   10985           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   10986           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   10987           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   10988             : 
   10989             :   /* function exit code */
   10990           0 :   __Pyx_RefNannyFinishContext();
   10991           0 :   return __pyx_r;
   10992             : }
   10993             : 
   10994           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   10995           0 :   PyObject *__pyx_r = NULL;
   10996             :   __Pyx_RefNannyDeclarations
   10997           0 :   PyObject *__pyx_t_1 = NULL;
   10998           0 :   PyObject *__pyx_t_2 = NULL;
   10999           0 :   PyObject *__pyx_t_3 = NULL;
   11000           0 :   int __pyx_lineno = 0;
   11001           0 :   const char *__pyx_filename = NULL;
   11002           0 :   int __pyx_clineno = 0;
   11003           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   11004             : 
   11005             :   /* "View.MemoryView":596
   11006             :  *     @property
   11007             :  *     def nbytes(self):
   11008             :  *         return self.size * self.view.itemsize             # <<<<<<<<<<<<<<
   11009             :  * 
   11010             :  *     @property
   11011             :  */
   11012           0 :   __Pyx_XDECREF(__pyx_r);
   11013           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 596, __pyx_L1_error)
   11014           0 :   __Pyx_GOTREF(__pyx_t_1);
   11015           0 :   __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_self->view.itemsize); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 596, __pyx_L1_error)
   11016           0 :   __Pyx_GOTREF(__pyx_t_2);
   11017           0 :   __pyx_t_3 = PyNumber_Multiply(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 596, __pyx_L1_error)
   11018           0 :   __Pyx_GOTREF(__pyx_t_3);
   11019           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   11020           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   11021           0 :   __pyx_r = __pyx_t_3;
   11022           0 :   __pyx_t_3 = 0;
   11023           0 :   goto __pyx_L0;
   11024             : 
   11025             :   /* "View.MemoryView":594
   11026             :  *         return self.view.itemsize
   11027             :  * 
   11028             :  *     @property             # <<<<<<<<<<<<<<
   11029             :  *     def nbytes(self):
   11030             :  *         return self.size * self.view.itemsize
   11031             :  */
   11032             : 
   11033             :   /* function exit code */
   11034           0 :   __pyx_L1_error:;
   11035           0 :   __Pyx_XDECREF(__pyx_t_1);
   11036           0 :   __Pyx_XDECREF(__pyx_t_2);
   11037           0 :   __Pyx_XDECREF(__pyx_t_3);
   11038           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.nbytes.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11039           0 :   __pyx_r = NULL;
   11040           0 :   __pyx_L0:;
   11041           0 :   __Pyx_XGIVEREF(__pyx_r);
   11042           0 :   __Pyx_RefNannyFinishContext();
   11043           0 :   return __pyx_r;
   11044             : }
   11045             : 
   11046             : /* "View.MemoryView":598
   11047             :  *         return self.size * self.view.itemsize
   11048             :  * 
   11049             :  *     @property             # <<<<<<<<<<<<<<
   11050             :  *     def size(self):
   11051             :  *         if self._size is None:
   11052             :  */
   11053             : 
   11054             : /* Python wrapper */
   11055             : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(PyObject *__pyx_v_self); /*proto*/
   11056           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(PyObject *__pyx_v_self) {
   11057           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11058           0 :   PyObject *__pyx_r = 0;
   11059             :   __Pyx_RefNannyDeclarations
   11060           0 :   __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
   11061           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   11062           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11063             : 
   11064             :   /* function exit code */
   11065           0 :   __Pyx_RefNannyFinishContext();
   11066           0 :   return __pyx_r;
   11067             : }
   11068             : 
   11069           0 : static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(struct __pyx_memoryview_obj *__pyx_v_self) {
   11070           0 :   PyObject *__pyx_v_result = NULL;
   11071           0 :   PyObject *__pyx_v_length = NULL;
   11072           0 :   PyObject *__pyx_r = NULL;
   11073             :   __Pyx_RefNannyDeclarations
   11074           0 :   int __pyx_t_1;
   11075           0 :   Py_ssize_t *__pyx_t_2;
   11076           0 :   Py_ssize_t *__pyx_t_3;
   11077           0 :   Py_ssize_t *__pyx_t_4;
   11078           0 :   PyObject *__pyx_t_5 = NULL;
   11079           0 :   int __pyx_lineno = 0;
   11080           0 :   const char *__pyx_filename = NULL;
   11081           0 :   int __pyx_clineno = 0;
   11082           0 :   __Pyx_RefNannySetupContext("__get__", 1);
   11083             : 
   11084             :   /* "View.MemoryView":600
   11085             :  *     @property
   11086             :  *     def size(self):
   11087             :  *         if self._size is None:             # <<<<<<<<<<<<<<
   11088             :  *             result = 1
   11089             :  * 
   11090             :  */
   11091           0 :   __pyx_t_1 = (__pyx_v_self->_size == Py_None);
   11092           0 :   if (__pyx_t_1) {
   11093             : 
   11094             :     /* "View.MemoryView":601
   11095             :  *     def size(self):
   11096             :  *         if self._size is None:
   11097             :  *             result = 1             # <<<<<<<<<<<<<<
   11098             :  * 
   11099             :  *             for length in self.view.shape[:self.view.ndim]:
   11100             :  */
   11101           0 :     __Pyx_INCREF(__pyx_int_1);
   11102           0 :     __pyx_v_result = __pyx_int_1;
   11103             : 
   11104             :     /* "View.MemoryView":603
   11105             :  *             result = 1
   11106             :  * 
   11107             :  *             for length in self.view.shape[:self.view.ndim]:             # <<<<<<<<<<<<<<
   11108             :  *                 result *= length
   11109             :  * 
   11110             :  */
   11111           0 :     __pyx_t_3 = (__pyx_v_self->view.shape + __pyx_v_self->view.ndim);
   11112           0 :     for (__pyx_t_4 = __pyx_v_self->view.shape; __pyx_t_4 < __pyx_t_3; __pyx_t_4++) {
   11113           0 :       __pyx_t_2 = __pyx_t_4;
   11114           0 :       __pyx_t_5 = PyInt_FromSsize_t((__pyx_t_2[0])); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 603, __pyx_L1_error)
   11115           0 :       __Pyx_GOTREF(__pyx_t_5);
   11116           0 :       __Pyx_XDECREF_SET(__pyx_v_length, __pyx_t_5);
   11117           0 :       __pyx_t_5 = 0;
   11118             : 
   11119             :       /* "View.MemoryView":604
   11120             :  * 
   11121             :  *             for length in self.view.shape[:self.view.ndim]:
   11122             :  *                 result *= length             # <<<<<<<<<<<<<<
   11123             :  * 
   11124             :  *             self._size = result
   11125             :  */
   11126           0 :       __pyx_t_5 = PyNumber_InPlaceMultiply(__pyx_v_result, __pyx_v_length); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 604, __pyx_L1_error)
   11127           0 :       __Pyx_GOTREF(__pyx_t_5);
   11128           0 :       __Pyx_DECREF_SET(__pyx_v_result, __pyx_t_5);
   11129           0 :       __pyx_t_5 = 0;
   11130             :     }
   11131             : 
   11132             :     /* "View.MemoryView":606
   11133             :  *                 result *= length
   11134             :  * 
   11135             :  *             self._size = result             # <<<<<<<<<<<<<<
   11136             :  * 
   11137             :  *         return self._size
   11138             :  */
   11139           0 :     __Pyx_INCREF(__pyx_v_result);
   11140           0 :     __Pyx_GIVEREF(__pyx_v_result);
   11141           0 :     __Pyx_GOTREF(__pyx_v_self->_size);
   11142           0 :     __Pyx_DECREF(__pyx_v_self->_size);
   11143           0 :     __pyx_v_self->_size = __pyx_v_result;
   11144             : 
   11145             :     /* "View.MemoryView":600
   11146             :  *     @property
   11147             :  *     def size(self):
   11148             :  *         if self._size is None:             # <<<<<<<<<<<<<<
   11149             :  *             result = 1
   11150             :  * 
   11151             :  */
   11152             :   }
   11153             : 
   11154             :   /* "View.MemoryView":608
   11155             :  *             self._size = result
   11156             :  * 
   11157             :  *         return self._size             # <<<<<<<<<<<<<<
   11158             :  * 
   11159             :  *     def __len__(self):
   11160             :  */
   11161           0 :   __Pyx_XDECREF(__pyx_r);
   11162           0 :   __Pyx_INCREF(__pyx_v_self->_size);
   11163           0 :   __pyx_r = __pyx_v_self->_size;
   11164           0 :   goto __pyx_L0;
   11165             : 
   11166             :   /* "View.MemoryView":598
   11167             :  *         return self.size * self.view.itemsize
   11168             :  * 
   11169             :  *     @property             # <<<<<<<<<<<<<<
   11170             :  *     def size(self):
   11171             :  *         if self._size is None:
   11172             :  */
   11173             : 
   11174             :   /* function exit code */
   11175           0 :   __pyx_L1_error:;
   11176           0 :   __Pyx_XDECREF(__pyx_t_5);
   11177           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.size.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11178           0 :   __pyx_r = NULL;
   11179           0 :   __pyx_L0:;
   11180           0 :   __Pyx_XDECREF(__pyx_v_result);
   11181           0 :   __Pyx_XDECREF(__pyx_v_length);
   11182           0 :   __Pyx_XGIVEREF(__pyx_r);
   11183           0 :   __Pyx_RefNannyFinishContext();
   11184           0 :   return __pyx_r;
   11185             : }
   11186             : 
   11187             : /* "View.MemoryView":610
   11188             :  *         return self._size
   11189             :  * 
   11190             :  *     def __len__(self):             # <<<<<<<<<<<<<<
   11191             :  *         if self.view.ndim >= 1:
   11192             :  *             return self.view.shape[0]
   11193             :  */
   11194             : 
   11195             : /* Python wrapper */
   11196             : static Py_ssize_t __pyx_memoryview___len__(PyObject *__pyx_v_self); /*proto*/
   11197           0 : static Py_ssize_t __pyx_memoryview___len__(PyObject *__pyx_v_self) {
   11198           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11199           0 :   Py_ssize_t __pyx_r;
   11200             :   __Pyx_RefNannyDeclarations
   11201           0 :   __Pyx_RefNannySetupContext("__len__ (wrapper)", 0);
   11202           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   11203           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11204             : 
   11205             :   /* function exit code */
   11206           0 :   __Pyx_RefNannyFinishContext();
   11207           0 :   return __pyx_r;
   11208             : }
   11209             : 
   11210           0 : static Py_ssize_t __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(struct __pyx_memoryview_obj *__pyx_v_self) {
   11211           0 :   Py_ssize_t __pyx_r;
   11212           0 :   int __pyx_t_1;
   11213             : 
   11214             :   /* "View.MemoryView":611
   11215             :  * 
   11216             :  *     def __len__(self):
   11217             :  *         if self.view.ndim >= 1:             # <<<<<<<<<<<<<<
   11218             :  *             return self.view.shape[0]
   11219             :  * 
   11220             :  */
   11221           0 :   __pyx_t_1 = (__pyx_v_self->view.ndim >= 1);
   11222           0 :   if (__pyx_t_1) {
   11223             : 
   11224             :     /* "View.MemoryView":612
   11225             :  *     def __len__(self):
   11226             :  *         if self.view.ndim >= 1:
   11227             :  *             return self.view.shape[0]             # <<<<<<<<<<<<<<
   11228             :  * 
   11229             :  *         return 0
   11230             :  */
   11231           0 :     __pyx_r = (__pyx_v_self->view.shape[0]);
   11232           0 :     goto __pyx_L0;
   11233             : 
   11234             :     /* "View.MemoryView":611
   11235             :  * 
   11236             :  *     def __len__(self):
   11237             :  *         if self.view.ndim >= 1:             # <<<<<<<<<<<<<<
   11238             :  *             return self.view.shape[0]
   11239             :  * 
   11240             :  */
   11241             :   }
   11242             : 
   11243             :   /* "View.MemoryView":614
   11244             :  *             return self.view.shape[0]
   11245             :  * 
   11246             :  *         return 0             # <<<<<<<<<<<<<<
   11247             :  * 
   11248             :  *     def __repr__(self):
   11249             :  */
   11250           0 :   __pyx_r = 0;
   11251           0 :   goto __pyx_L0;
   11252             : 
   11253             :   /* "View.MemoryView":610
   11254             :  *         return self._size
   11255             :  * 
   11256             :  *     def __len__(self):             # <<<<<<<<<<<<<<
   11257             :  *         if self.view.ndim >= 1:
   11258             :  *             return self.view.shape[0]
   11259             :  */
   11260             : 
   11261             :   /* function exit code */
   11262           0 :   __pyx_L0:;
   11263           0 :   return __pyx_r;
   11264             : }
   11265             : 
   11266             : /* "View.MemoryView":616
   11267             :  *         return 0
   11268             :  * 
   11269             :  *     def __repr__(self):             # <<<<<<<<<<<<<<
   11270             :  *         return "<MemoryView of %r at 0x%x>" % (self.base.__class__.__name__,
   11271             :  *                                                id(self))
   11272             :  */
   11273             : 
   11274             : /* Python wrapper */
   11275             : static PyObject *__pyx_memoryview___repr__(PyObject *__pyx_v_self); /*proto*/
   11276           0 : static PyObject *__pyx_memoryview___repr__(PyObject *__pyx_v_self) {
   11277           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11278           0 :   PyObject *__pyx_r = 0;
   11279             :   __Pyx_RefNannyDeclarations
   11280           0 :   __Pyx_RefNannySetupContext("__repr__ (wrapper)", 0);
   11281           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   11282           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11283             : 
   11284             :   /* function exit code */
   11285           0 :   __Pyx_RefNannyFinishContext();
   11286           0 :   return __pyx_r;
   11287             : }
   11288             : 
   11289           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(struct __pyx_memoryview_obj *__pyx_v_self) {
   11290           0 :   PyObject *__pyx_r = NULL;
   11291             :   __Pyx_RefNannyDeclarations
   11292           0 :   PyObject *__pyx_t_1 = NULL;
   11293           0 :   PyObject *__pyx_t_2 = NULL;
   11294           0 :   PyObject *__pyx_t_3 = NULL;
   11295           0 :   int __pyx_lineno = 0;
   11296           0 :   const char *__pyx_filename = NULL;
   11297           0 :   int __pyx_clineno = 0;
   11298           0 :   __Pyx_RefNannySetupContext("__repr__", 1);
   11299             : 
   11300             :   /* "View.MemoryView":617
   11301             :  * 
   11302             :  *     def __repr__(self):
   11303             :  *         return "<MemoryView of %r at 0x%x>" % (self.base.__class__.__name__,             # <<<<<<<<<<<<<<
   11304             :  *                                                id(self))
   11305             :  * 
   11306             :  */
   11307           0 :   __Pyx_XDECREF(__pyx_r);
   11308           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_base); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 617, __pyx_L1_error)
   11309           0 :   __Pyx_GOTREF(__pyx_t_1);
   11310           0 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 617, __pyx_L1_error)
   11311           0 :   __Pyx_GOTREF(__pyx_t_2);
   11312           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   11313           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_name_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 617, __pyx_L1_error)
   11314           0 :   __Pyx_GOTREF(__pyx_t_1);
   11315           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   11316             : 
   11317             :   /* "View.MemoryView":618
   11318             :  *     def __repr__(self):
   11319             :  *         return "<MemoryView of %r at 0x%x>" % (self.base.__class__.__name__,
   11320             :  *                                                id(self))             # <<<<<<<<<<<<<<
   11321             :  * 
   11322             :  *     def __str__(self):
   11323             :  */
   11324           0 :   __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 618, __pyx_L1_error)
   11325           0 :   __Pyx_GOTREF(__pyx_t_2);
   11326             : 
   11327             :   /* "View.MemoryView":617
   11328             :  * 
   11329             :  *     def __repr__(self):
   11330             :  *         return "<MemoryView of %r at 0x%x>" % (self.base.__class__.__name__,             # <<<<<<<<<<<<<<
   11331             :  *                                                id(self))
   11332             :  * 
   11333             :  */
   11334           0 :   __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 617, __pyx_L1_error)
   11335           0 :   __Pyx_GOTREF(__pyx_t_3);
   11336           0 :   __Pyx_GIVEREF(__pyx_t_1);
   11337           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1)) __PYX_ERR(1, 617, __pyx_L1_error);
   11338           0 :   __Pyx_GIVEREF(__pyx_t_2);
   11339           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2)) __PYX_ERR(1, 617, __pyx_L1_error);
   11340           0 :   __pyx_t_1 = 0;
   11341           0 :   __pyx_t_2 = 0;
   11342           0 :   __pyx_t_2 = __Pyx_PyString_Format(__pyx_kp_s_MemoryView_of_r_at_0x_x, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 617, __pyx_L1_error)
   11343           0 :   __Pyx_GOTREF(__pyx_t_2);
   11344           0 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   11345           0 :   __pyx_r = __pyx_t_2;
   11346           0 :   __pyx_t_2 = 0;
   11347           0 :   goto __pyx_L0;
   11348             : 
   11349             :   /* "View.MemoryView":616
   11350             :  *         return 0
   11351             :  * 
   11352             :  *     def __repr__(self):             # <<<<<<<<<<<<<<
   11353             :  *         return "<MemoryView of %r at 0x%x>" % (self.base.__class__.__name__,
   11354             :  *                                                id(self))
   11355             :  */
   11356             : 
   11357             :   /* function exit code */
   11358           0 :   __pyx_L1_error:;
   11359           0 :   __Pyx_XDECREF(__pyx_t_1);
   11360           0 :   __Pyx_XDECREF(__pyx_t_2);
   11361           0 :   __Pyx_XDECREF(__pyx_t_3);
   11362           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__repr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11363           0 :   __pyx_r = NULL;
   11364           0 :   __pyx_L0:;
   11365           0 :   __Pyx_XGIVEREF(__pyx_r);
   11366           0 :   __Pyx_RefNannyFinishContext();
   11367           0 :   return __pyx_r;
   11368             : }
   11369             : 
   11370             : /* "View.MemoryView":620
   11371             :  *                                                id(self))
   11372             :  * 
   11373             :  *     def __str__(self):             # <<<<<<<<<<<<<<
   11374             :  *         return "<MemoryView of %r object>" % (self.base.__class__.__name__,)
   11375             :  * 
   11376             :  */
   11377             : 
   11378             : /* Python wrapper */
   11379             : static PyObject *__pyx_memoryview___str__(PyObject *__pyx_v_self); /*proto*/
   11380           0 : static PyObject *__pyx_memoryview___str__(PyObject *__pyx_v_self) {
   11381           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11382           0 :   PyObject *__pyx_r = 0;
   11383             :   __Pyx_RefNannyDeclarations
   11384           0 :   __Pyx_RefNannySetupContext("__str__ (wrapper)", 0);
   11385           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   11386           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11387             : 
   11388             :   /* function exit code */
   11389           0 :   __Pyx_RefNannyFinishContext();
   11390           0 :   return __pyx_r;
   11391             : }
   11392             : 
   11393           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(struct __pyx_memoryview_obj *__pyx_v_self) {
   11394           0 :   PyObject *__pyx_r = NULL;
   11395             :   __Pyx_RefNannyDeclarations
   11396           0 :   PyObject *__pyx_t_1 = NULL;
   11397           0 :   PyObject *__pyx_t_2 = NULL;
   11398           0 :   int __pyx_lineno = 0;
   11399           0 :   const char *__pyx_filename = NULL;
   11400           0 :   int __pyx_clineno = 0;
   11401           0 :   __Pyx_RefNannySetupContext("__str__", 1);
   11402             : 
   11403             :   /* "View.MemoryView":621
   11404             :  * 
   11405             :  *     def __str__(self):
   11406             :  *         return "<MemoryView of %r object>" % (self.base.__class__.__name__,)             # <<<<<<<<<<<<<<
   11407             :  * 
   11408             :  * 
   11409             :  */
   11410           0 :   __Pyx_XDECREF(__pyx_r);
   11411           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_base); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 621, __pyx_L1_error)
   11412           0 :   __Pyx_GOTREF(__pyx_t_1);
   11413           0 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_class); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 621, __pyx_L1_error)
   11414           0 :   __Pyx_GOTREF(__pyx_t_2);
   11415           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   11416           0 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_name_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 621, __pyx_L1_error)
   11417           0 :   __Pyx_GOTREF(__pyx_t_1);
   11418           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   11419           0 :   __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 621, __pyx_L1_error)
   11420           0 :   __Pyx_GOTREF(__pyx_t_2);
   11421           0 :   __Pyx_GIVEREF(__pyx_t_1);
   11422           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1)) __PYX_ERR(1, 621, __pyx_L1_error);
   11423           0 :   __pyx_t_1 = 0;
   11424           0 :   __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_MemoryView_of_r_object, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 621, __pyx_L1_error)
   11425           0 :   __Pyx_GOTREF(__pyx_t_1);
   11426           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   11427           0 :   __pyx_r = __pyx_t_1;
   11428           0 :   __pyx_t_1 = 0;
   11429           0 :   goto __pyx_L0;
   11430             : 
   11431             :   /* "View.MemoryView":620
   11432             :  *                                                id(self))
   11433             :  * 
   11434             :  *     def __str__(self):             # <<<<<<<<<<<<<<
   11435             :  *         return "<MemoryView of %r object>" % (self.base.__class__.__name__,)
   11436             :  * 
   11437             :  */
   11438             : 
   11439             :   /* function exit code */
   11440           0 :   __pyx_L1_error:;
   11441           0 :   __Pyx_XDECREF(__pyx_t_1);
   11442           0 :   __Pyx_XDECREF(__pyx_t_2);
   11443           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11444           0 :   __pyx_r = NULL;
   11445           0 :   __pyx_L0:;
   11446           0 :   __Pyx_XGIVEREF(__pyx_r);
   11447           0 :   __Pyx_RefNannyFinishContext();
   11448           0 :   return __pyx_r;
   11449             : }
   11450             : 
   11451             : /* "View.MemoryView":624
   11452             :  * 
   11453             :  * 
   11454             :  *     def is_c_contig(self):             # <<<<<<<<<<<<<<
   11455             :  *         cdef __Pyx_memviewslice *mslice
   11456             :  *         cdef __Pyx_memviewslice tmp
   11457             :  */
   11458             : 
   11459             : /* Python wrapper */
   11460             : static PyObject *__pyx_memoryview_is_c_contig(PyObject *__pyx_v_self, 
   11461             : #if CYTHON_METH_FASTCALL
   11462             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11463             : #else
   11464             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11465             : #endif
   11466             : ); /*proto*/
   11467           0 : static PyObject *__pyx_memoryview_is_c_contig(PyObject *__pyx_v_self, 
   11468             : #if CYTHON_METH_FASTCALL
   11469             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11470             : #else
   11471             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11472             : #endif
   11473             : ) {
   11474             :   #if !CYTHON_METH_FASTCALL
   11475             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   11476             :   #endif
   11477           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11478           0 :   PyObject *__pyx_r = 0;
   11479             :   __Pyx_RefNannyDeclarations
   11480           0 :   __Pyx_RefNannySetupContext("is_c_contig (wrapper)", 0);
   11481             :   #if !CYTHON_METH_FASTCALL
   11482             :   #if CYTHON_ASSUME_SAFE_MACROS
   11483             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   11484             :   #else
   11485             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   11486             :   #endif
   11487             :   #endif
   11488           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   11489           0 :   if (unlikely(__pyx_nargs > 0)) {
   11490           0 :     __Pyx_RaiseArgtupleInvalid("is_c_contig", 1, 0, 0, __pyx_nargs); return NULL;}
   11491           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "is_c_contig", 0))) return NULL;
   11492           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11493             : 
   11494             :   /* function exit code */
   11495           0 :   __Pyx_RefNannyFinishContext();
   11496           0 :   return __pyx_r;
   11497             : }
   11498             : 
   11499           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(struct __pyx_memoryview_obj *__pyx_v_self) {
   11500           0 :   __Pyx_memviewslice *__pyx_v_mslice;
   11501           0 :   __Pyx_memviewslice __pyx_v_tmp;
   11502           0 :   PyObject *__pyx_r = NULL;
   11503             :   __Pyx_RefNannyDeclarations
   11504           0 :   __Pyx_memviewslice *__pyx_t_1;
   11505           0 :   PyObject *__pyx_t_2 = NULL;
   11506           0 :   int __pyx_lineno = 0;
   11507           0 :   const char *__pyx_filename = NULL;
   11508           0 :   int __pyx_clineno = 0;
   11509           0 :   __Pyx_RefNannySetupContext("is_c_contig", 1);
   11510             : 
   11511             :   /* "View.MemoryView":627
   11512             :  *         cdef __Pyx_memviewslice *mslice
   11513             :  *         cdef __Pyx_memviewslice tmp
   11514             :  *         mslice = get_slice_from_memview(self, &tmp)             # <<<<<<<<<<<<<<
   11515             :  *         return slice_is_contig(mslice[0], 'C', self.view.ndim)
   11516             :  * 
   11517             :  */
   11518           0 :   __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_self, (&__pyx_v_tmp)); if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(1, 627, __pyx_L1_error)
   11519           0 :   __pyx_v_mslice = __pyx_t_1;
   11520             : 
   11521             :   /* "View.MemoryView":628
   11522             :  *         cdef __Pyx_memviewslice tmp
   11523             :  *         mslice = get_slice_from_memview(self, &tmp)
   11524             :  *         return slice_is_contig(mslice[0], 'C', self.view.ndim)             # <<<<<<<<<<<<<<
   11525             :  * 
   11526             :  *     def is_f_contig(self):
   11527             :  */
   11528           0 :   __Pyx_XDECREF(__pyx_r);
   11529           0 :   __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_memviewslice_is_contig((__pyx_v_mslice[0]), 'C', __pyx_v_self->view.ndim)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 628, __pyx_L1_error)
   11530           0 :   __Pyx_GOTREF(__pyx_t_2);
   11531           0 :   __pyx_r = __pyx_t_2;
   11532           0 :   __pyx_t_2 = 0;
   11533           0 :   goto __pyx_L0;
   11534             : 
   11535             :   /* "View.MemoryView":624
   11536             :  * 
   11537             :  * 
   11538             :  *     def is_c_contig(self):             # <<<<<<<<<<<<<<
   11539             :  *         cdef __Pyx_memviewslice *mslice
   11540             :  *         cdef __Pyx_memviewslice tmp
   11541             :  */
   11542             : 
   11543             :   /* function exit code */
   11544           0 :   __pyx_L1_error:;
   11545           0 :   __Pyx_XDECREF(__pyx_t_2);
   11546           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.is_c_contig", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11547           0 :   __pyx_r = NULL;
   11548           0 :   __pyx_L0:;
   11549           0 :   __Pyx_XGIVEREF(__pyx_r);
   11550           0 :   __Pyx_RefNannyFinishContext();
   11551           0 :   return __pyx_r;
   11552             : }
   11553             : 
   11554             : /* "View.MemoryView":630
   11555             :  *         return slice_is_contig(mslice[0], 'C', self.view.ndim)
   11556             :  * 
   11557             :  *     def is_f_contig(self):             # <<<<<<<<<<<<<<
   11558             :  *         cdef __Pyx_memviewslice *mslice
   11559             :  *         cdef __Pyx_memviewslice tmp
   11560             :  */
   11561             : 
   11562             : /* Python wrapper */
   11563             : static PyObject *__pyx_memoryview_is_f_contig(PyObject *__pyx_v_self, 
   11564             : #if CYTHON_METH_FASTCALL
   11565             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11566             : #else
   11567             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11568             : #endif
   11569             : ); /*proto*/
   11570           0 : static PyObject *__pyx_memoryview_is_f_contig(PyObject *__pyx_v_self, 
   11571             : #if CYTHON_METH_FASTCALL
   11572             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11573             : #else
   11574             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11575             : #endif
   11576             : ) {
   11577             :   #if !CYTHON_METH_FASTCALL
   11578             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   11579             :   #endif
   11580           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11581           0 :   PyObject *__pyx_r = 0;
   11582             :   __Pyx_RefNannyDeclarations
   11583           0 :   __Pyx_RefNannySetupContext("is_f_contig (wrapper)", 0);
   11584             :   #if !CYTHON_METH_FASTCALL
   11585             :   #if CYTHON_ASSUME_SAFE_MACROS
   11586             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   11587             :   #else
   11588             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   11589             :   #endif
   11590             :   #endif
   11591           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   11592           0 :   if (unlikely(__pyx_nargs > 0)) {
   11593           0 :     __Pyx_RaiseArgtupleInvalid("is_f_contig", 1, 0, 0, __pyx_nargs); return NULL;}
   11594           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "is_f_contig", 0))) return NULL;
   11595           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11596             : 
   11597             :   /* function exit code */
   11598           0 :   __Pyx_RefNannyFinishContext();
   11599           0 :   return __pyx_r;
   11600             : }
   11601             : 
   11602           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(struct __pyx_memoryview_obj *__pyx_v_self) {
   11603           0 :   __Pyx_memviewslice *__pyx_v_mslice;
   11604           0 :   __Pyx_memviewslice __pyx_v_tmp;
   11605           0 :   PyObject *__pyx_r = NULL;
   11606             :   __Pyx_RefNannyDeclarations
   11607           0 :   __Pyx_memviewslice *__pyx_t_1;
   11608           0 :   PyObject *__pyx_t_2 = NULL;
   11609           0 :   int __pyx_lineno = 0;
   11610           0 :   const char *__pyx_filename = NULL;
   11611           0 :   int __pyx_clineno = 0;
   11612           0 :   __Pyx_RefNannySetupContext("is_f_contig", 1);
   11613             : 
   11614             :   /* "View.MemoryView":633
   11615             :  *         cdef __Pyx_memviewslice *mslice
   11616             :  *         cdef __Pyx_memviewslice tmp
   11617             :  *         mslice = get_slice_from_memview(self, &tmp)             # <<<<<<<<<<<<<<
   11618             :  *         return slice_is_contig(mslice[0], 'F', self.view.ndim)
   11619             :  * 
   11620             :  */
   11621           0 :   __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_self, (&__pyx_v_tmp)); if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(1, 633, __pyx_L1_error)
   11622           0 :   __pyx_v_mslice = __pyx_t_1;
   11623             : 
   11624             :   /* "View.MemoryView":634
   11625             :  *         cdef __Pyx_memviewslice tmp
   11626             :  *         mslice = get_slice_from_memview(self, &tmp)
   11627             :  *         return slice_is_contig(mslice[0], 'F', self.view.ndim)             # <<<<<<<<<<<<<<
   11628             :  * 
   11629             :  *     def copy(self):
   11630             :  */
   11631           0 :   __Pyx_XDECREF(__pyx_r);
   11632           0 :   __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_memviewslice_is_contig((__pyx_v_mslice[0]), 'F', __pyx_v_self->view.ndim)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 634, __pyx_L1_error)
   11633           0 :   __Pyx_GOTREF(__pyx_t_2);
   11634           0 :   __pyx_r = __pyx_t_2;
   11635           0 :   __pyx_t_2 = 0;
   11636           0 :   goto __pyx_L0;
   11637             : 
   11638             :   /* "View.MemoryView":630
   11639             :  *         return slice_is_contig(mslice[0], 'C', self.view.ndim)
   11640             :  * 
   11641             :  *     def is_f_contig(self):             # <<<<<<<<<<<<<<
   11642             :  *         cdef __Pyx_memviewslice *mslice
   11643             :  *         cdef __Pyx_memviewslice tmp
   11644             :  */
   11645             : 
   11646             :   /* function exit code */
   11647           0 :   __pyx_L1_error:;
   11648           0 :   __Pyx_XDECREF(__pyx_t_2);
   11649           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.is_f_contig", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11650           0 :   __pyx_r = NULL;
   11651           0 :   __pyx_L0:;
   11652           0 :   __Pyx_XGIVEREF(__pyx_r);
   11653           0 :   __Pyx_RefNannyFinishContext();
   11654           0 :   return __pyx_r;
   11655             : }
   11656             : 
   11657             : /* "View.MemoryView":636
   11658             :  *         return slice_is_contig(mslice[0], 'F', self.view.ndim)
   11659             :  * 
   11660             :  *     def copy(self):             # <<<<<<<<<<<<<<
   11661             :  *         cdef __Pyx_memviewslice mslice
   11662             :  *         cdef int flags = self.flags & ~PyBUF_F_CONTIGUOUS
   11663             :  */
   11664             : 
   11665             : /* Python wrapper */
   11666             : static PyObject *__pyx_memoryview_copy(PyObject *__pyx_v_self, 
   11667             : #if CYTHON_METH_FASTCALL
   11668             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11669             : #else
   11670             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11671             : #endif
   11672             : ); /*proto*/
   11673           0 : static PyObject *__pyx_memoryview_copy(PyObject *__pyx_v_self, 
   11674             : #if CYTHON_METH_FASTCALL
   11675             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11676             : #else
   11677             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11678             : #endif
   11679             : ) {
   11680             :   #if !CYTHON_METH_FASTCALL
   11681             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   11682             :   #endif
   11683           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11684           0 :   PyObject *__pyx_r = 0;
   11685             :   __Pyx_RefNannyDeclarations
   11686           0 :   __Pyx_RefNannySetupContext("copy (wrapper)", 0);
   11687             :   #if !CYTHON_METH_FASTCALL
   11688             :   #if CYTHON_ASSUME_SAFE_MACROS
   11689             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   11690             :   #else
   11691             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   11692             :   #endif
   11693             :   #endif
   11694           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   11695           0 :   if (unlikely(__pyx_nargs > 0)) {
   11696           0 :     __Pyx_RaiseArgtupleInvalid("copy", 1, 0, 0, __pyx_nargs); return NULL;}
   11697           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "copy", 0))) return NULL;
   11698           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11699             : 
   11700             :   /* function exit code */
   11701           0 :   __Pyx_RefNannyFinishContext();
   11702           0 :   return __pyx_r;
   11703             : }
   11704             : 
   11705           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(struct __pyx_memoryview_obj *__pyx_v_self) {
   11706           0 :   __Pyx_memviewslice __pyx_v_mslice;
   11707           0 :   int __pyx_v_flags;
   11708           0 :   PyObject *__pyx_r = NULL;
   11709             :   __Pyx_RefNannyDeclarations
   11710           0 :   __Pyx_memviewslice __pyx_t_1;
   11711           0 :   PyObject *__pyx_t_2 = NULL;
   11712           0 :   int __pyx_lineno = 0;
   11713           0 :   const char *__pyx_filename = NULL;
   11714           0 :   int __pyx_clineno = 0;
   11715           0 :   __Pyx_RefNannySetupContext("copy", 1);
   11716             : 
   11717             :   /* "View.MemoryView":638
   11718             :  *     def copy(self):
   11719             :  *         cdef __Pyx_memviewslice mslice
   11720             :  *         cdef int flags = self.flags & ~PyBUF_F_CONTIGUOUS             # <<<<<<<<<<<<<<
   11721             :  * 
   11722             :  *         slice_copy(self, &mslice)
   11723             :  */
   11724           0 :   __pyx_v_flags = (__pyx_v_self->flags & (~PyBUF_F_CONTIGUOUS));
   11725             : 
   11726             :   /* "View.MemoryView":640
   11727             :  *         cdef int flags = self.flags & ~PyBUF_F_CONTIGUOUS
   11728             :  * 
   11729             :  *         slice_copy(self, &mslice)             # <<<<<<<<<<<<<<
   11730             :  *         mslice = slice_copy_contig(&mslice, "c", self.view.ndim,
   11731             :  *                                    self.view.itemsize,
   11732             :  */
   11733           0 :   __pyx_memoryview_slice_copy(__pyx_v_self, (&__pyx_v_mslice));
   11734             : 
   11735             :   /* "View.MemoryView":641
   11736             :  * 
   11737             :  *         slice_copy(self, &mslice)
   11738             :  *         mslice = slice_copy_contig(&mslice, "c", self.view.ndim,             # <<<<<<<<<<<<<<
   11739             :  *                                    self.view.itemsize,
   11740             :  *                                    flags|PyBUF_C_CONTIGUOUS,
   11741             :  */
   11742           0 :   __pyx_t_1 = __pyx_memoryview_copy_new_contig((&__pyx_v_mslice), ((char *)"c"), __pyx_v_self->view.ndim, __pyx_v_self->view.itemsize, (__pyx_v_flags | PyBUF_C_CONTIGUOUS), __pyx_v_self->dtype_is_object); if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 641, __pyx_L1_error)
   11743           0 :   __pyx_v_mslice = __pyx_t_1;
   11744             : 
   11745             :   /* "View.MemoryView":646
   11746             :  *                                    self.dtype_is_object)
   11747             :  * 
   11748             :  *         return memoryview_copy_from_slice(self, &mslice)             # <<<<<<<<<<<<<<
   11749             :  * 
   11750             :  *     def copy_fortran(self):
   11751             :  */
   11752           0 :   __Pyx_XDECREF(__pyx_r);
   11753           0 :   __pyx_t_2 = __pyx_memoryview_copy_object_from_slice(__pyx_v_self, (&__pyx_v_mslice)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 646, __pyx_L1_error)
   11754           0 :   __Pyx_GOTREF(__pyx_t_2);
   11755           0 :   __pyx_r = __pyx_t_2;
   11756           0 :   __pyx_t_2 = 0;
   11757           0 :   goto __pyx_L0;
   11758             : 
   11759             :   /* "View.MemoryView":636
   11760             :  *         return slice_is_contig(mslice[0], 'F', self.view.ndim)
   11761             :  * 
   11762             :  *     def copy(self):             # <<<<<<<<<<<<<<
   11763             :  *         cdef __Pyx_memviewslice mslice
   11764             :  *         cdef int flags = self.flags & ~PyBUF_F_CONTIGUOUS
   11765             :  */
   11766             : 
   11767             :   /* function exit code */
   11768           0 :   __pyx_L1_error:;
   11769           0 :   __Pyx_XDECREF(__pyx_t_2);
   11770           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11771           0 :   __pyx_r = NULL;
   11772           0 :   __pyx_L0:;
   11773           0 :   __Pyx_XGIVEREF(__pyx_r);
   11774           0 :   __Pyx_RefNannyFinishContext();
   11775           0 :   return __pyx_r;
   11776             : }
   11777             : 
   11778             : /* "View.MemoryView":648
   11779             :  *         return memoryview_copy_from_slice(self, &mslice)
   11780             :  * 
   11781             :  *     def copy_fortran(self):             # <<<<<<<<<<<<<<
   11782             :  *         cdef __Pyx_memviewslice src, dst
   11783             :  *         cdef int flags = self.flags & ~PyBUF_C_CONTIGUOUS
   11784             :  */
   11785             : 
   11786             : /* Python wrapper */
   11787             : static PyObject *__pyx_memoryview_copy_fortran(PyObject *__pyx_v_self, 
   11788             : #if CYTHON_METH_FASTCALL
   11789             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11790             : #else
   11791             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11792             : #endif
   11793             : ); /*proto*/
   11794           0 : static PyObject *__pyx_memoryview_copy_fortran(PyObject *__pyx_v_self, 
   11795             : #if CYTHON_METH_FASTCALL
   11796             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11797             : #else
   11798             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11799             : #endif
   11800             : ) {
   11801             :   #if !CYTHON_METH_FASTCALL
   11802             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   11803             :   #endif
   11804           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11805           0 :   PyObject *__pyx_r = 0;
   11806             :   __Pyx_RefNannyDeclarations
   11807           0 :   __Pyx_RefNannySetupContext("copy_fortran (wrapper)", 0);
   11808             :   #if !CYTHON_METH_FASTCALL
   11809             :   #if CYTHON_ASSUME_SAFE_MACROS
   11810             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   11811             :   #else
   11812             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   11813             :   #endif
   11814             :   #endif
   11815           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   11816           0 :   if (unlikely(__pyx_nargs > 0)) {
   11817           0 :     __Pyx_RaiseArgtupleInvalid("copy_fortran", 1, 0, 0, __pyx_nargs); return NULL;}
   11818           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "copy_fortran", 0))) return NULL;
   11819           0 :   __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11820             : 
   11821             :   /* function exit code */
   11822           0 :   __Pyx_RefNannyFinishContext();
   11823           0 :   return __pyx_r;
   11824             : }
   11825             : 
   11826           0 : static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(struct __pyx_memoryview_obj *__pyx_v_self) {
   11827           0 :   __Pyx_memviewslice __pyx_v_src;
   11828           0 :   __Pyx_memviewslice __pyx_v_dst;
   11829           0 :   int __pyx_v_flags;
   11830           0 :   PyObject *__pyx_r = NULL;
   11831             :   __Pyx_RefNannyDeclarations
   11832           0 :   __Pyx_memviewslice __pyx_t_1;
   11833           0 :   PyObject *__pyx_t_2 = NULL;
   11834           0 :   int __pyx_lineno = 0;
   11835           0 :   const char *__pyx_filename = NULL;
   11836           0 :   int __pyx_clineno = 0;
   11837           0 :   __Pyx_RefNannySetupContext("copy_fortran", 1);
   11838             : 
   11839             :   /* "View.MemoryView":650
   11840             :  *     def copy_fortran(self):
   11841             :  *         cdef __Pyx_memviewslice src, dst
   11842             :  *         cdef int flags = self.flags & ~PyBUF_C_CONTIGUOUS             # <<<<<<<<<<<<<<
   11843             :  * 
   11844             :  *         slice_copy(self, &src)
   11845             :  */
   11846           0 :   __pyx_v_flags = (__pyx_v_self->flags & (~PyBUF_C_CONTIGUOUS));
   11847             : 
   11848             :   /* "View.MemoryView":652
   11849             :  *         cdef int flags = self.flags & ~PyBUF_C_CONTIGUOUS
   11850             :  * 
   11851             :  *         slice_copy(self, &src)             # <<<<<<<<<<<<<<
   11852             :  *         dst = slice_copy_contig(&src, "fortran", self.view.ndim,
   11853             :  *                                 self.view.itemsize,
   11854             :  */
   11855           0 :   __pyx_memoryview_slice_copy(__pyx_v_self, (&__pyx_v_src));
   11856             : 
   11857             :   /* "View.MemoryView":653
   11858             :  * 
   11859             :  *         slice_copy(self, &src)
   11860             :  *         dst = slice_copy_contig(&src, "fortran", self.view.ndim,             # <<<<<<<<<<<<<<
   11861             :  *                                 self.view.itemsize,
   11862             :  *                                 flags|PyBUF_F_CONTIGUOUS,
   11863             :  */
   11864           0 :   __pyx_t_1 = __pyx_memoryview_copy_new_contig((&__pyx_v_src), ((char *)"fortran"), __pyx_v_self->view.ndim, __pyx_v_self->view.itemsize, (__pyx_v_flags | PyBUF_F_CONTIGUOUS), __pyx_v_self->dtype_is_object); if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 653, __pyx_L1_error)
   11865           0 :   __pyx_v_dst = __pyx_t_1;
   11866             : 
   11867             :   /* "View.MemoryView":658
   11868             :  *                                 self.dtype_is_object)
   11869             :  * 
   11870             :  *         return memoryview_copy_from_slice(self, &dst)             # <<<<<<<<<<<<<<
   11871             :  * 
   11872             :  * 
   11873             :  */
   11874           0 :   __Pyx_XDECREF(__pyx_r);
   11875           0 :   __pyx_t_2 = __pyx_memoryview_copy_object_from_slice(__pyx_v_self, (&__pyx_v_dst)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 658, __pyx_L1_error)
   11876           0 :   __Pyx_GOTREF(__pyx_t_2);
   11877           0 :   __pyx_r = __pyx_t_2;
   11878           0 :   __pyx_t_2 = 0;
   11879           0 :   goto __pyx_L0;
   11880             : 
   11881             :   /* "View.MemoryView":648
   11882             :  *         return memoryview_copy_from_slice(self, &mslice)
   11883             :  * 
   11884             :  *     def copy_fortran(self):             # <<<<<<<<<<<<<<
   11885             :  *         cdef __Pyx_memviewslice src, dst
   11886             :  *         cdef int flags = self.flags & ~PyBUF_C_CONTIGUOUS
   11887             :  */
   11888             : 
   11889             :   /* function exit code */
   11890           0 :   __pyx_L1_error:;
   11891           0 :   __Pyx_XDECREF(__pyx_t_2);
   11892           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.copy_fortran", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11893           0 :   __pyx_r = NULL;
   11894           0 :   __pyx_L0:;
   11895           0 :   __Pyx_XGIVEREF(__pyx_r);
   11896           0 :   __Pyx_RefNannyFinishContext();
   11897           0 :   return __pyx_r;
   11898             : }
   11899             : 
   11900             : /* "(tree fragment)":1
   11901             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
   11902             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   11903             :  * def __setstate_cython__(self, __pyx_state):
   11904             :  */
   11905             : 
   11906             : /* Python wrapper */
   11907             : static PyObject *__pyx_pw___pyx_memoryview_1__reduce_cython__(PyObject *__pyx_v_self, 
   11908             : #if CYTHON_METH_FASTCALL
   11909             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11910             : #else
   11911             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11912             : #endif
   11913             : ); /*proto*/
   11914           0 : static PyObject *__pyx_pw___pyx_memoryview_1__reduce_cython__(PyObject *__pyx_v_self, 
   11915             : #if CYTHON_METH_FASTCALL
   11916             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11917             : #else
   11918             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11919             : #endif
   11920             : ) {
   11921             :   #if !CYTHON_METH_FASTCALL
   11922             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   11923             :   #endif
   11924           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   11925           0 :   PyObject *__pyx_r = 0;
   11926             :   __Pyx_RefNannyDeclarations
   11927           0 :   __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
   11928             :   #if !CYTHON_METH_FASTCALL
   11929             :   #if CYTHON_ASSUME_SAFE_MACROS
   11930             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   11931             :   #else
   11932             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   11933             :   #endif
   11934             :   #endif
   11935           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   11936           0 :   if (unlikely(__pyx_nargs > 0)) {
   11937           0 :     __Pyx_RaiseArgtupleInvalid("__reduce_cython__", 1, 0, 0, __pyx_nargs); return NULL;}
   11938           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__reduce_cython__", 0))) return NULL;
   11939           0 :   __pyx_r = __pyx_pf___pyx_memoryview___reduce_cython__(((struct __pyx_memoryview_obj *)__pyx_v_self));
   11940             : 
   11941             :   /* function exit code */
   11942           0 :   __Pyx_RefNannyFinishContext();
   11943           0 :   return __pyx_r;
   11944             : }
   11945             : 
   11946           0 : static PyObject *__pyx_pf___pyx_memoryview___reduce_cython__(CYTHON_UNUSED struct __pyx_memoryview_obj *__pyx_v_self) {
   11947           0 :   PyObject *__pyx_r = NULL;
   11948             :   __Pyx_RefNannyDeclarations
   11949           0 :   int __pyx_lineno = 0;
   11950           0 :   const char *__pyx_filename = NULL;
   11951           0 :   int __pyx_clineno = 0;
   11952           0 :   __Pyx_RefNannySetupContext("__reduce_cython__", 1);
   11953             : 
   11954             :   /* "(tree fragment)":2
   11955             :  * def __reduce_cython__(self):
   11956             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
   11957             :  * def __setstate_cython__(self, __pyx_state):
   11958             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   11959             :  */
   11960           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
   11961           0 :   __PYX_ERR(1, 2, __pyx_L1_error)
   11962             : 
   11963             :   /* "(tree fragment)":1
   11964             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
   11965             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   11966             :  * def __setstate_cython__(self, __pyx_state):
   11967             :  */
   11968             : 
   11969             :   /* function exit code */
   11970           0 :   __pyx_L1_error:;
   11971           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   11972           0 :   __pyx_r = NULL;
   11973           0 :   __Pyx_XGIVEREF(__pyx_r);
   11974           0 :   __Pyx_RefNannyFinishContext();
   11975           0 :   return __pyx_r;
   11976             : }
   11977             : 
   11978             : /* "(tree fragment)":3
   11979             :  * def __reduce_cython__(self):
   11980             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   11981             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
   11982             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   11983             :  */
   11984             : 
   11985             : /* Python wrapper */
   11986             : static PyObject *__pyx_pw___pyx_memoryview_3__setstate_cython__(PyObject *__pyx_v_self, 
   11987             : #if CYTHON_METH_FASTCALL
   11988             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11989             : #else
   11990             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11991             : #endif
   11992             : ); /*proto*/
   11993           0 : static PyObject *__pyx_pw___pyx_memoryview_3__setstate_cython__(PyObject *__pyx_v_self, 
   11994             : #if CYTHON_METH_FASTCALL
   11995             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   11996             : #else
   11997             : PyObject *__pyx_args, PyObject *__pyx_kwds
   11998             : #endif
   11999             : ) {
   12000           0 :   CYTHON_UNUSED PyObject *__pyx_v___pyx_state = 0;
   12001             :   #if !CYTHON_METH_FASTCALL
   12002             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   12003             :   #endif
   12004           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   12005           0 :   PyObject* values[1] = {0};
   12006           0 :   int __pyx_lineno = 0;
   12007           0 :   const char *__pyx_filename = NULL;
   12008           0 :   int __pyx_clineno = 0;
   12009           0 :   PyObject *__pyx_r = 0;
   12010             :   __Pyx_RefNannyDeclarations
   12011           0 :   __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
   12012             :   #if !CYTHON_METH_FASTCALL
   12013             :   #if CYTHON_ASSUME_SAFE_MACROS
   12014             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   12015             :   #else
   12016             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   12017             :   #endif
   12018             :   #endif
   12019           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   12020             :   {
   12021           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_state,0};
   12022           0 :     if (__pyx_kwds) {
   12023           0 :       Py_ssize_t kw_args;
   12024           0 :       switch (__pyx_nargs) {
   12025           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   12026           0 :         CYTHON_FALLTHROUGH;
   12027           0 :         case  0: break;
   12028           0 :         default: goto __pyx_L5_argtuple_error;
   12029             :       }
   12030           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
   12031           0 :       switch (__pyx_nargs) {
   12032             :         case  0:
   12033           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_state)) != 0)) {
   12034           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
   12035           0 :           kw_args--;
   12036             :         }
   12037           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 3, __pyx_L3_error)
   12038           0 :         else goto __pyx_L5_argtuple_error;
   12039             :       }
   12040           0 :       if (unlikely(kw_args > 0)) {
   12041           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   12042           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__setstate_cython__") < 0)) __PYX_ERR(1, 3, __pyx_L3_error)
   12043             :       }
   12044           0 :     } else if (unlikely(__pyx_nargs != 1)) {
   12045           0 :       goto __pyx_L5_argtuple_error;
   12046             :     } else {
   12047           0 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   12048             :     }
   12049           0 :     __pyx_v___pyx_state = values[0];
   12050             :   }
   12051           0 :   goto __pyx_L6_skip;
   12052           0 :   __pyx_L5_argtuple_error:;
   12053           0 :   __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, __pyx_nargs); __PYX_ERR(1, 3, __pyx_L3_error)
   12054           0 :   __pyx_L6_skip:;
   12055           0 :   goto __pyx_L4_argument_unpacking_done;
   12056           0 :   __pyx_L3_error:;
   12057             :   {
   12058           0 :     Py_ssize_t __pyx_temp;
   12059           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   12060             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   12061             :     }
   12062             :   }
   12063           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   12064           0 :   __Pyx_RefNannyFinishContext();
   12065           0 :   return NULL;
   12066           0 :   __pyx_L4_argument_unpacking_done:;
   12067           0 :   __pyx_r = __pyx_pf___pyx_memoryview_2__setstate_cython__(((struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v___pyx_state);
   12068             : 
   12069             :   /* function exit code */
   12070             :   {
   12071           0 :     Py_ssize_t __pyx_temp;
   12072           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   12073             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   12074             :     }
   12075             :   }
   12076             :   __Pyx_RefNannyFinishContext();
   12077             :   return __pyx_r;
   12078             : }
   12079             : 
   12080           0 : static PyObject *__pyx_pf___pyx_memoryview_2__setstate_cython__(CYTHON_UNUSED struct __pyx_memoryview_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
   12081           0 :   PyObject *__pyx_r = NULL;
   12082             :   __Pyx_RefNannyDeclarations
   12083           0 :   int __pyx_lineno = 0;
   12084           0 :   const char *__pyx_filename = NULL;
   12085           0 :   int __pyx_clineno = 0;
   12086           0 :   __Pyx_RefNannySetupContext("__setstate_cython__", 1);
   12087             : 
   12088             :   /* "(tree fragment)":4
   12089             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   12090             :  * def __setstate_cython__(self, __pyx_state):
   12091             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
   12092             :  */
   12093           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
   12094           0 :   __PYX_ERR(1, 4, __pyx_L1_error)
   12095             : 
   12096             :   /* "(tree fragment)":3
   12097             :  * def __reduce_cython__(self):
   12098             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   12099             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
   12100             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   12101             :  */
   12102             : 
   12103             :   /* function exit code */
   12104           0 :   __pyx_L1_error:;
   12105           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   12106           0 :   __pyx_r = NULL;
   12107           0 :   __Pyx_XGIVEREF(__pyx_r);
   12108           0 :   __Pyx_RefNannyFinishContext();
   12109           0 :   return __pyx_r;
   12110             : }
   12111             : 
   12112             : /* "View.MemoryView":662
   12113             :  * 
   12114             :  * @cname('__pyx_memoryview_new')
   12115             :  * cdef memoryview_cwrapper(object o, int flags, bint dtype_is_object, __Pyx_TypeInfo *typeinfo):             # <<<<<<<<<<<<<<
   12116             :  *     cdef memoryview result = memoryview(o, flags, dtype_is_object)
   12117             :  *     result.typeinfo = typeinfo
   12118             :  */
   12119             : 
   12120           0 : static PyObject *__pyx_memoryview_new(PyObject *__pyx_v_o, int __pyx_v_flags, int __pyx_v_dtype_is_object, __Pyx_TypeInfo *__pyx_v_typeinfo) {
   12121           0 :   struct __pyx_memoryview_obj *__pyx_v_result = 0;
   12122           0 :   PyObject *__pyx_r = NULL;
   12123             :   __Pyx_RefNannyDeclarations
   12124           0 :   PyObject *__pyx_t_1 = NULL;
   12125           0 :   PyObject *__pyx_t_2 = NULL;
   12126           0 :   PyObject *__pyx_t_3 = NULL;
   12127           0 :   int __pyx_lineno = 0;
   12128           0 :   const char *__pyx_filename = NULL;
   12129           0 :   int __pyx_clineno = 0;
   12130           0 :   __Pyx_RefNannySetupContext("memoryview_cwrapper", 1);
   12131             : 
   12132             :   /* "View.MemoryView":663
   12133             :  * @cname('__pyx_memoryview_new')
   12134             :  * cdef memoryview_cwrapper(object o, int flags, bint dtype_is_object, __Pyx_TypeInfo *typeinfo):
   12135             :  *     cdef memoryview result = memoryview(o, flags, dtype_is_object)             # <<<<<<<<<<<<<<
   12136             :  *     result.typeinfo = typeinfo
   12137             :  *     return result
   12138             :  */
   12139           0 :   __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_flags); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 663, __pyx_L1_error)
   12140           0 :   __Pyx_GOTREF(__pyx_t_1);
   12141           0 :   __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_dtype_is_object); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 663, __pyx_L1_error)
   12142           0 :   __Pyx_GOTREF(__pyx_t_2);
   12143           0 :   __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 663, __pyx_L1_error)
   12144           0 :   __Pyx_GOTREF(__pyx_t_3);
   12145           0 :   __Pyx_INCREF(__pyx_v_o);
   12146           0 :   __Pyx_GIVEREF(__pyx_v_o);
   12147           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_o)) __PYX_ERR(1, 663, __pyx_L1_error);
   12148           0 :   __Pyx_GIVEREF(__pyx_t_1);
   12149           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1)) __PYX_ERR(1, 663, __pyx_L1_error);
   12150           0 :   __Pyx_GIVEREF(__pyx_t_2);
   12151           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2)) __PYX_ERR(1, 663, __pyx_L1_error);
   12152           0 :   __pyx_t_1 = 0;
   12153           0 :   __pyx_t_2 = 0;
   12154           0 :   __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 663, __pyx_L1_error)
   12155           0 :   __Pyx_GOTREF(__pyx_t_2);
   12156           0 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   12157           0 :   __pyx_v_result = ((struct __pyx_memoryview_obj *)__pyx_t_2);
   12158           0 :   __pyx_t_2 = 0;
   12159             : 
   12160             :   /* "View.MemoryView":664
   12161             :  * cdef memoryview_cwrapper(object o, int flags, bint dtype_is_object, __Pyx_TypeInfo *typeinfo):
   12162             :  *     cdef memoryview result = memoryview(o, flags, dtype_is_object)
   12163             :  *     result.typeinfo = typeinfo             # <<<<<<<<<<<<<<
   12164             :  *     return result
   12165             :  * 
   12166             :  */
   12167           0 :   __pyx_v_result->typeinfo = __pyx_v_typeinfo;
   12168             : 
   12169             :   /* "View.MemoryView":665
   12170             :  *     cdef memoryview result = memoryview(o, flags, dtype_is_object)
   12171             :  *     result.typeinfo = typeinfo
   12172             :  *     return result             # <<<<<<<<<<<<<<
   12173             :  * 
   12174             :  * @cname('__pyx_memoryview_check')
   12175             :  */
   12176           0 :   __Pyx_XDECREF(__pyx_r);
   12177           0 :   __Pyx_INCREF((PyObject *)__pyx_v_result);
   12178           0 :   __pyx_r = ((PyObject *)__pyx_v_result);
   12179           0 :   goto __pyx_L0;
   12180             : 
   12181             :   /* "View.MemoryView":662
   12182             :  * 
   12183             :  * @cname('__pyx_memoryview_new')
   12184             :  * cdef memoryview_cwrapper(object o, int flags, bint dtype_is_object, __Pyx_TypeInfo *typeinfo):             # <<<<<<<<<<<<<<
   12185             :  *     cdef memoryview result = memoryview(o, flags, dtype_is_object)
   12186             :  *     result.typeinfo = typeinfo
   12187             :  */
   12188             : 
   12189             :   /* function exit code */
   12190           0 :   __pyx_L1_error:;
   12191           0 :   __Pyx_XDECREF(__pyx_t_1);
   12192           0 :   __Pyx_XDECREF(__pyx_t_2);
   12193           0 :   __Pyx_XDECREF(__pyx_t_3);
   12194           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview_cwrapper", __pyx_clineno, __pyx_lineno, __pyx_filename);
   12195           0 :   __pyx_r = 0;
   12196           0 :   __pyx_L0:;
   12197           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_result);
   12198           0 :   __Pyx_XGIVEREF(__pyx_r);
   12199           0 :   __Pyx_RefNannyFinishContext();
   12200           0 :   return __pyx_r;
   12201             : }
   12202             : 
   12203             : /* "View.MemoryView":668
   12204             :  * 
   12205             :  * @cname('__pyx_memoryview_check')
   12206             :  * cdef inline bint memoryview_check(object o) noexcept:             # <<<<<<<<<<<<<<
   12207             :  *     return isinstance(o, memoryview)
   12208             :  * 
   12209             :  */
   12210             : 
   12211           0 : static CYTHON_INLINE int __pyx_memoryview_check(PyObject *__pyx_v_o) {
   12212           0 :   int __pyx_r;
   12213           0 :   int __pyx_t_1;
   12214             : 
   12215             :   /* "View.MemoryView":669
   12216             :  * @cname('__pyx_memoryview_check')
   12217             :  * cdef inline bint memoryview_check(object o) noexcept:
   12218             :  *     return isinstance(o, memoryview)             # <<<<<<<<<<<<<<
   12219             :  * 
   12220             :  * cdef tuple _unellipsify(object index, int ndim):
   12221             :  */
   12222           0 :   __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_o, __pyx_memoryview_type); 
   12223           0 :   __pyx_r = __pyx_t_1;
   12224           0 :   goto __pyx_L0;
   12225             : 
   12226             :   /* "View.MemoryView":668
   12227             :  * 
   12228             :  * @cname('__pyx_memoryview_check')
   12229             :  * cdef inline bint memoryview_check(object o) noexcept:             # <<<<<<<<<<<<<<
   12230             :  *     return isinstance(o, memoryview)
   12231             :  * 
   12232             :  */
   12233             : 
   12234             :   /* function exit code */
   12235           0 :   __pyx_L0:;
   12236           0 :   return __pyx_r;
   12237             : }
   12238             : 
   12239             : /* "View.MemoryView":671
   12240             :  *     return isinstance(o, memoryview)
   12241             :  * 
   12242             :  * cdef tuple _unellipsify(object index, int ndim):             # <<<<<<<<<<<<<<
   12243             :  *     """
   12244             :  *     Replace all ellipses with full slices and fill incomplete indices with
   12245             :  */
   12246             : 
   12247           0 : static PyObject *_unellipsify(PyObject *__pyx_v_index, int __pyx_v_ndim) {
   12248           0 :   Py_ssize_t __pyx_v_idx;
   12249           0 :   PyObject *__pyx_v_tup = NULL;
   12250           0 :   PyObject *__pyx_v_result = NULL;
   12251           0 :   int __pyx_v_have_slices;
   12252           0 :   int __pyx_v_seen_ellipsis;
   12253           0 :   PyObject *__pyx_v_item = NULL;
   12254           0 :   Py_ssize_t __pyx_v_nslices;
   12255           0 :   PyObject *__pyx_r = NULL;
   12256             :   __Pyx_RefNannyDeclarations
   12257           0 :   PyObject *__pyx_t_1 = NULL;
   12258           0 :   int __pyx_t_2;
   12259           0 :   PyObject *__pyx_t_3 = NULL;
   12260           0 :   Py_ssize_t __pyx_t_4;
   12261           0 :   Py_ssize_t __pyx_t_5;
   12262           0 :   Py_UCS4 __pyx_t_6;
   12263           0 :   PyObject *__pyx_t_7 = NULL;
   12264           0 :   int __pyx_lineno = 0;
   12265           0 :   const char *__pyx_filename = NULL;
   12266           0 :   int __pyx_clineno = 0;
   12267           0 :   __Pyx_RefNannySetupContext("_unellipsify", 1);
   12268             : 
   12269             :   /* "View.MemoryView":677
   12270             :  *     """
   12271             :  *     cdef Py_ssize_t idx
   12272             :  *     tup = <tuple>index if isinstance(index, tuple) else (index,)             # <<<<<<<<<<<<<<
   12273             :  * 
   12274             :  *     result = [slice(None)] * ndim
   12275             :  */
   12276           0 :   __pyx_t_2 = PyTuple_Check(__pyx_v_index); 
   12277           0 :   if (__pyx_t_2) {
   12278           0 :     __Pyx_INCREF(((PyObject*)__pyx_v_index));
   12279             :     __pyx_t_1 = __pyx_v_index;
   12280             :   } else {
   12281           0 :     __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 677, __pyx_L1_error)
   12282           0 :     __Pyx_GOTREF(__pyx_t_3);
   12283           0 :     __Pyx_INCREF(__pyx_v_index);
   12284           0 :     __Pyx_GIVEREF(__pyx_v_index);
   12285           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_index)) __PYX_ERR(1, 677, __pyx_L1_error);
   12286           0 :     __pyx_t_1 = __pyx_t_3;
   12287           0 :     __pyx_t_3 = 0;
   12288             :   }
   12289           0 :   __pyx_v_tup = ((PyObject*)__pyx_t_1);
   12290           0 :   __pyx_t_1 = 0;
   12291             : 
   12292             :   /* "View.MemoryView":679
   12293             :  *     tup = <tuple>index if isinstance(index, tuple) else (index,)
   12294             :  * 
   12295             :  *     result = [slice(None)] * ndim             # <<<<<<<<<<<<<<
   12296             :  *     have_slices = False
   12297             :  *     seen_ellipsis = False
   12298             :  */
   12299           0 :   __pyx_t_1 = PyList_New(1 * ((__pyx_v_ndim<0) ? 0:__pyx_v_ndim)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 679, __pyx_L1_error)
   12300             :   __Pyx_GOTREF(__pyx_t_1);
   12301             :   { Py_ssize_t __pyx_temp;
   12302           0 :     for (__pyx_temp=0; __pyx_temp < __pyx_v_ndim; __pyx_temp++) {
   12303           0 :       __Pyx_INCREF(__pyx_slice__5);
   12304           0 :       __Pyx_GIVEREF(__pyx_slice__5);
   12305           0 :       if (__Pyx_PyList_SET_ITEM(__pyx_t_1, __pyx_temp, __pyx_slice__5)) __PYX_ERR(1, 679, __pyx_L1_error);
   12306             :     }
   12307             :   }
   12308           0 :   __pyx_v_result = ((PyObject*)__pyx_t_1);
   12309           0 :   __pyx_t_1 = 0;
   12310             : 
   12311             :   /* "View.MemoryView":680
   12312             :  * 
   12313             :  *     result = [slice(None)] * ndim
   12314             :  *     have_slices = False             # <<<<<<<<<<<<<<
   12315             :  *     seen_ellipsis = False
   12316             :  *     idx = 0
   12317             :  */
   12318           0 :   __pyx_v_have_slices = 0;
   12319             : 
   12320             :   /* "View.MemoryView":681
   12321             :  *     result = [slice(None)] * ndim
   12322             :  *     have_slices = False
   12323             :  *     seen_ellipsis = False             # <<<<<<<<<<<<<<
   12324             :  *     idx = 0
   12325             :  *     for item in tup:
   12326             :  */
   12327           0 :   __pyx_v_seen_ellipsis = 0;
   12328             : 
   12329             :   /* "View.MemoryView":682
   12330             :  *     have_slices = False
   12331             :  *     seen_ellipsis = False
   12332             :  *     idx = 0             # <<<<<<<<<<<<<<
   12333             :  *     for item in tup:
   12334             :  *         if item is Ellipsis:
   12335             :  */
   12336           0 :   __pyx_v_idx = 0;
   12337             : 
   12338             :   /* "View.MemoryView":683
   12339             :  *     seen_ellipsis = False
   12340             :  *     idx = 0
   12341             :  *     for item in tup:             # <<<<<<<<<<<<<<
   12342             :  *         if item is Ellipsis:
   12343             :  *             if not seen_ellipsis:
   12344             :  */
   12345           0 :   if (unlikely(__pyx_v_tup == Py_None)) {
   12346           0 :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   12347           0 :     __PYX_ERR(1, 683, __pyx_L1_error)
   12348             :   }
   12349           0 :   __pyx_t_1 = __pyx_v_tup; __Pyx_INCREF(__pyx_t_1);
   12350             :   __pyx_t_4 = 0;
   12351           0 :   for (;;) {
   12352           0 :     {
   12353           0 :       Py_ssize_t __pyx_temp = __Pyx_PyTuple_GET_SIZE(__pyx_t_1);
   12354             :       #if !CYTHON_ASSUME_SAFE_MACROS
   12355             :       if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 683, __pyx_L1_error)
   12356             :       #endif
   12357           0 :       if (__pyx_t_4 >= __pyx_temp) break;
   12358             :     }
   12359             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   12360           0 :     __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_4); __Pyx_INCREF(__pyx_t_3); __pyx_t_4++; if (unlikely((0 < 0))) __PYX_ERR(1, 683, __pyx_L1_error)
   12361             :     #else
   12362             :     __pyx_t_3 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 683, __pyx_L1_error)
   12363             :     __Pyx_GOTREF(__pyx_t_3);
   12364             :     #endif
   12365           0 :     __Pyx_XDECREF_SET(__pyx_v_item, __pyx_t_3);
   12366           0 :     __pyx_t_3 = 0;
   12367             : 
   12368             :     /* "View.MemoryView":684
   12369             :  *     idx = 0
   12370             :  *     for item in tup:
   12371             :  *         if item is Ellipsis:             # <<<<<<<<<<<<<<
   12372             :  *             if not seen_ellipsis:
   12373             :  *                 idx += ndim - len(tup)
   12374             :  */
   12375           0 :     __pyx_t_2 = (__pyx_v_item == __pyx_builtin_Ellipsis);
   12376           0 :     if (__pyx_t_2) {
   12377             : 
   12378             :       /* "View.MemoryView":685
   12379             :  *     for item in tup:
   12380             :  *         if item is Ellipsis:
   12381             :  *             if not seen_ellipsis:             # <<<<<<<<<<<<<<
   12382             :  *                 idx += ndim - len(tup)
   12383             :  *                 seen_ellipsis = True
   12384             :  */
   12385           0 :       __pyx_t_2 = (!__pyx_v_seen_ellipsis);
   12386           0 :       if (__pyx_t_2) {
   12387             : 
   12388             :         /* "View.MemoryView":686
   12389             :  *         if item is Ellipsis:
   12390             :  *             if not seen_ellipsis:
   12391             :  *                 idx += ndim - len(tup)             # <<<<<<<<<<<<<<
   12392             :  *                 seen_ellipsis = True
   12393             :  *             have_slices = True
   12394             :  */
   12395           0 :         if (unlikely(__pyx_v_tup == Py_None)) {
   12396             :           PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   12397             :           __PYX_ERR(1, 686, __pyx_L1_error)
   12398             :         }
   12399           0 :         __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(__pyx_v_tup); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(1, 686, __pyx_L1_error)
   12400           0 :         __pyx_v_idx = (__pyx_v_idx + (__pyx_v_ndim - __pyx_t_5));
   12401             : 
   12402             :         /* "View.MemoryView":687
   12403             :  *             if not seen_ellipsis:
   12404             :  *                 idx += ndim - len(tup)
   12405             :  *                 seen_ellipsis = True             # <<<<<<<<<<<<<<
   12406             :  *             have_slices = True
   12407             :  *         else:
   12408             :  */
   12409           0 :         __pyx_v_seen_ellipsis = 1;
   12410             : 
   12411             :         /* "View.MemoryView":685
   12412             :  *     for item in tup:
   12413             :  *         if item is Ellipsis:
   12414             :  *             if not seen_ellipsis:             # <<<<<<<<<<<<<<
   12415             :  *                 idx += ndim - len(tup)
   12416             :  *                 seen_ellipsis = True
   12417             :  */
   12418             :       }
   12419             : 
   12420             :       /* "View.MemoryView":688
   12421             :  *                 idx += ndim - len(tup)
   12422             :  *                 seen_ellipsis = True
   12423             :  *             have_slices = True             # <<<<<<<<<<<<<<
   12424             :  *         else:
   12425             :  *             if isinstance(item, slice):
   12426             :  */
   12427           0 :       __pyx_v_have_slices = 1;
   12428             : 
   12429             :       /* "View.MemoryView":684
   12430             :  *     idx = 0
   12431             :  *     for item in tup:
   12432             :  *         if item is Ellipsis:             # <<<<<<<<<<<<<<
   12433             :  *             if not seen_ellipsis:
   12434             :  *                 idx += ndim - len(tup)
   12435             :  */
   12436           0 :       goto __pyx_L5;
   12437             :     }
   12438             : 
   12439             :     /* "View.MemoryView":690
   12440             :  *             have_slices = True
   12441             :  *         else:
   12442             :  *             if isinstance(item, slice):             # <<<<<<<<<<<<<<
   12443             :  *                 have_slices = True
   12444             :  *             elif not PyIndex_Check(item):
   12445             :  */
   12446             :     /*else*/ {
   12447           0 :       __pyx_t_2 = PySlice_Check(__pyx_v_item); 
   12448           0 :       if (__pyx_t_2) {
   12449             : 
   12450             :         /* "View.MemoryView":691
   12451             :  *         else:
   12452             :  *             if isinstance(item, slice):
   12453             :  *                 have_slices = True             # <<<<<<<<<<<<<<
   12454             :  *             elif not PyIndex_Check(item):
   12455             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"
   12456             :  */
   12457           0 :         __pyx_v_have_slices = 1;
   12458             : 
   12459             :         /* "View.MemoryView":690
   12460             :  *             have_slices = True
   12461             :  *         else:
   12462             :  *             if isinstance(item, slice):             # <<<<<<<<<<<<<<
   12463             :  *                 have_slices = True
   12464             :  *             elif not PyIndex_Check(item):
   12465             :  */
   12466           0 :         goto __pyx_L7;
   12467             :       }
   12468             : 
   12469             :       /* "View.MemoryView":692
   12470             :  *             if isinstance(item, slice):
   12471             :  *                 have_slices = True
   12472             :  *             elif not PyIndex_Check(item):             # <<<<<<<<<<<<<<
   12473             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"
   12474             :  *             result[idx] = item
   12475             :  */
   12476           0 :       __pyx_t_2 = (!(PyIndex_Check(__pyx_v_item) != 0));
   12477           0 :       if (unlikely(__pyx_t_2)) {
   12478             : 
   12479             :         /* "View.MemoryView":693
   12480             :  *                 have_slices = True
   12481             :  *             elif not PyIndex_Check(item):
   12482             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"             # <<<<<<<<<<<<<<
   12483             :  *             result[idx] = item
   12484             :  *         idx += 1
   12485             :  */
   12486           0 :         __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 693, __pyx_L1_error)
   12487           0 :         __Pyx_GOTREF(__pyx_t_3);
   12488           0 :         __pyx_t_5 = 0;
   12489           0 :         __pyx_t_6 = 127;
   12490           0 :         __Pyx_INCREF(__pyx_kp_u_Cannot_index_with_type);
   12491           0 :         __pyx_t_5 += 24;
   12492           0 :         __Pyx_GIVEREF(__pyx_kp_u_Cannot_index_with_type);
   12493           0 :         PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_kp_u_Cannot_index_with_type);
   12494           0 :         __pyx_t_7 = __Pyx_PyObject_FormatSimple(((PyObject *)Py_TYPE(__pyx_v_item)), __pyx_empty_unicode); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 693, __pyx_L1_error)
   12495           0 :         __Pyx_GOTREF(__pyx_t_7);
   12496           0 :         __pyx_t_6 = (__Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_7) > __pyx_t_6) ? __Pyx_PyUnicode_MAX_CHAR_VALUE(__pyx_t_7) : __pyx_t_6;
   12497           0 :         __pyx_t_5 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_7);
   12498           0 :         __Pyx_GIVEREF(__pyx_t_7);
   12499           0 :         PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_7);
   12500           0 :         __pyx_t_7 = 0;
   12501           0 :         __Pyx_INCREF(__pyx_kp_u__6);
   12502           0 :         __pyx_t_5 += 1;
   12503           0 :         __Pyx_GIVEREF(__pyx_kp_u__6);
   12504           0 :         PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_kp_u__6);
   12505           0 :         __pyx_t_7 = __Pyx_PyUnicode_Join(__pyx_t_3, 3, __pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 693, __pyx_L1_error)
   12506           0 :         __Pyx_GOTREF(__pyx_t_7);
   12507           0 :         __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   12508           0 :         __Pyx_Raise(__pyx_builtin_TypeError, __pyx_t_7, 0, 0);
   12509           0 :         __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   12510           0 :         __PYX_ERR(1, 693, __pyx_L1_error)
   12511             : 
   12512             :         /* "View.MemoryView":692
   12513             :  *             if isinstance(item, slice):
   12514             :  *                 have_slices = True
   12515             :  *             elif not PyIndex_Check(item):             # <<<<<<<<<<<<<<
   12516             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"
   12517             :  *             result[idx] = item
   12518             :  */
   12519             :       }
   12520           0 :       __pyx_L7:;
   12521             : 
   12522             :       /* "View.MemoryView":694
   12523             :  *             elif not PyIndex_Check(item):
   12524             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"
   12525             :  *             result[idx] = item             # <<<<<<<<<<<<<<
   12526             :  *         idx += 1
   12527             :  * 
   12528             :  */
   12529           0 :       if (unlikely((__Pyx_SetItemInt(__pyx_v_result, __pyx_v_idx, __pyx_v_item, Py_ssize_t, 1, PyInt_FromSsize_t, 1, 1, 1) < 0))) __PYX_ERR(1, 694, __pyx_L1_error)
   12530             :     }
   12531           0 :     __pyx_L5:;
   12532             : 
   12533             :     /* "View.MemoryView":695
   12534             :  *                 raise TypeError, f"Cannot index with type '{type(item)}'"
   12535             :  *             result[idx] = item
   12536             :  *         idx += 1             # <<<<<<<<<<<<<<
   12537             :  * 
   12538             :  *     nslices = ndim - idx
   12539             :  */
   12540           0 :     __pyx_v_idx = (__pyx_v_idx + 1);
   12541             : 
   12542             :     /* "View.MemoryView":683
   12543             :  *     seen_ellipsis = False
   12544             :  *     idx = 0
   12545             :  *     for item in tup:             # <<<<<<<<<<<<<<
   12546             :  *         if item is Ellipsis:
   12547             :  *             if not seen_ellipsis:
   12548             :  */
   12549             :   }
   12550           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   12551             : 
   12552             :   /* "View.MemoryView":697
   12553             :  *         idx += 1
   12554             :  * 
   12555             :  *     nslices = ndim - idx             # <<<<<<<<<<<<<<
   12556             :  *     return have_slices or nslices, tuple(result)
   12557             :  * 
   12558             :  */
   12559           0 :   __pyx_v_nslices = (__pyx_v_ndim - __pyx_v_idx);
   12560             : 
   12561             :   /* "View.MemoryView":698
   12562             :  * 
   12563             :  *     nslices = ndim - idx
   12564             :  *     return have_slices or nslices, tuple(result)             # <<<<<<<<<<<<<<
   12565             :  * 
   12566             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:
   12567             :  */
   12568           0 :   __Pyx_XDECREF(__pyx_r);
   12569           0 :   if (!__pyx_v_have_slices) {
   12570           0 :   } else {
   12571           0 :     __pyx_t_7 = __Pyx_PyBool_FromLong(__pyx_v_have_slices); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 698, __pyx_L1_error)
   12572           0 :     __Pyx_GOTREF(__pyx_t_7);
   12573           0 :     __pyx_t_1 = __pyx_t_7;
   12574           0 :     __pyx_t_7 = 0;
   12575           0 :     goto __pyx_L9_bool_binop_done;
   12576             :   }
   12577           0 :   __pyx_t_7 = PyInt_FromSsize_t(__pyx_v_nslices); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 698, __pyx_L1_error)
   12578             :   __Pyx_GOTREF(__pyx_t_7);
   12579             :   __pyx_t_1 = __pyx_t_7;
   12580           0 :   __pyx_t_7 = 0;
   12581           0 :   __pyx_L9_bool_binop_done:;
   12582           0 :   __pyx_t_7 = PyList_AsTuple(__pyx_v_result); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 698, __pyx_L1_error)
   12583           0 :   __Pyx_GOTREF(__pyx_t_7);
   12584           0 :   __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 698, __pyx_L1_error)
   12585           0 :   __Pyx_GOTREF(__pyx_t_3);
   12586           0 :   __Pyx_GIVEREF(__pyx_t_1);
   12587           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1)) __PYX_ERR(1, 698, __pyx_L1_error);
   12588           0 :   __Pyx_GIVEREF(__pyx_t_7);
   12589           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_7)) __PYX_ERR(1, 698, __pyx_L1_error);
   12590           0 :   __pyx_t_1 = 0;
   12591           0 :   __pyx_t_7 = 0;
   12592           0 :   __pyx_r = ((PyObject*)__pyx_t_3);
   12593           0 :   __pyx_t_3 = 0;
   12594           0 :   goto __pyx_L0;
   12595             : 
   12596             :   /* "View.MemoryView":671
   12597             :  *     return isinstance(o, memoryview)
   12598             :  * 
   12599             :  * cdef tuple _unellipsify(object index, int ndim):             # <<<<<<<<<<<<<<
   12600             :  *     """
   12601             :  *     Replace all ellipses with full slices and fill incomplete indices with
   12602             :  */
   12603             : 
   12604             :   /* function exit code */
   12605           0 :   __pyx_L1_error:;
   12606           0 :   __Pyx_XDECREF(__pyx_t_1);
   12607           0 :   __Pyx_XDECREF(__pyx_t_3);
   12608           0 :   __Pyx_XDECREF(__pyx_t_7);
   12609           0 :   __Pyx_AddTraceback("View.MemoryView._unellipsify", __pyx_clineno, __pyx_lineno, __pyx_filename);
   12610           0 :   __pyx_r = 0;
   12611           0 :   __pyx_L0:;
   12612           0 :   __Pyx_XDECREF(__pyx_v_tup);
   12613           0 :   __Pyx_XDECREF(__pyx_v_result);
   12614           0 :   __Pyx_XDECREF(__pyx_v_item);
   12615           0 :   __Pyx_XGIVEREF(__pyx_r);
   12616           0 :   __Pyx_RefNannyFinishContext();
   12617           0 :   return __pyx_r;
   12618             : }
   12619             : 
   12620             : /* "View.MemoryView":700
   12621             :  *     return have_slices or nslices, tuple(result)
   12622             :  * 
   12623             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:             # <<<<<<<<<<<<<<
   12624             :  *     for suboffset in suboffsets[:ndim]:
   12625             :  *         if suboffset >= 0:
   12626             :  */
   12627             : 
   12628           0 : static int assert_direct_dimensions(Py_ssize_t *__pyx_v_suboffsets, int __pyx_v_ndim) {
   12629           0 :   Py_ssize_t __pyx_v_suboffset;
   12630           0 :   int __pyx_r;
   12631           0 :   Py_ssize_t *__pyx_t_1;
   12632           0 :   Py_ssize_t *__pyx_t_2;
   12633           0 :   Py_ssize_t *__pyx_t_3;
   12634           0 :   int __pyx_t_4;
   12635           0 :   int __pyx_lineno = 0;
   12636           0 :   const char *__pyx_filename = NULL;
   12637           0 :   int __pyx_clineno = 0;
   12638             : 
   12639             :   /* "View.MemoryView":701
   12640             :  * 
   12641             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:
   12642             :  *     for suboffset in suboffsets[:ndim]:             # <<<<<<<<<<<<<<
   12643             :  *         if suboffset >= 0:
   12644             :  *             raise ValueError, "Indirect dimensions not supported"
   12645             :  */
   12646           0 :   __pyx_t_2 = (__pyx_v_suboffsets + __pyx_v_ndim);
   12647           0 :   for (__pyx_t_3 = __pyx_v_suboffsets; __pyx_t_3 < __pyx_t_2; __pyx_t_3++) {
   12648           0 :     __pyx_t_1 = __pyx_t_3;
   12649           0 :     __pyx_v_suboffset = (__pyx_t_1[0]);
   12650             : 
   12651             :     /* "View.MemoryView":702
   12652             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:
   12653             :  *     for suboffset in suboffsets[:ndim]:
   12654             :  *         if suboffset >= 0:             # <<<<<<<<<<<<<<
   12655             :  *             raise ValueError, "Indirect dimensions not supported"
   12656             :  *     return 0  # return type just used as an error flag
   12657             :  */
   12658           0 :     __pyx_t_4 = (__pyx_v_suboffset >= 0);
   12659           0 :     if (unlikely(__pyx_t_4)) {
   12660             : 
   12661             :       /* "View.MemoryView":703
   12662             :  *     for suboffset in suboffsets[:ndim]:
   12663             :  *         if suboffset >= 0:
   12664             :  *             raise ValueError, "Indirect dimensions not supported"             # <<<<<<<<<<<<<<
   12665             :  *     return 0  # return type just used as an error flag
   12666             :  * 
   12667             :  */
   12668           0 :       __Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_s_Indirect_dimensions_not_supporte, 0, 0);
   12669           0 :       __PYX_ERR(1, 703, __pyx_L1_error)
   12670             : 
   12671             :       /* "View.MemoryView":702
   12672             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:
   12673             :  *     for suboffset in suboffsets[:ndim]:
   12674             :  *         if suboffset >= 0:             # <<<<<<<<<<<<<<
   12675             :  *             raise ValueError, "Indirect dimensions not supported"
   12676             :  *     return 0  # return type just used as an error flag
   12677             :  */
   12678             :     }
   12679             :   }
   12680             : 
   12681             :   /* "View.MemoryView":704
   12682             :  *         if suboffset >= 0:
   12683             :  *             raise ValueError, "Indirect dimensions not supported"
   12684             :  *     return 0  # return type just used as an error flag             # <<<<<<<<<<<<<<
   12685             :  * 
   12686             :  * 
   12687             :  */
   12688           0 :   __pyx_r = 0;
   12689           0 :   goto __pyx_L0;
   12690             : 
   12691             :   /* "View.MemoryView":700
   12692             :  *     return have_slices or nslices, tuple(result)
   12693             :  * 
   12694             :  * cdef int assert_direct_dimensions(Py_ssize_t *suboffsets, int ndim) except -1:             # <<<<<<<<<<<<<<
   12695             :  *     for suboffset in suboffsets[:ndim]:
   12696             :  *         if suboffset >= 0:
   12697             :  */
   12698             : 
   12699             :   /* function exit code */
   12700           0 :   __pyx_L1_error:;
   12701           0 :   __Pyx_AddTraceback("View.MemoryView.assert_direct_dimensions", __pyx_clineno, __pyx_lineno, __pyx_filename);
   12702           0 :   __pyx_r = -1;
   12703           0 :   __pyx_L0:;
   12704           0 :   return __pyx_r;
   12705             : }
   12706             : 
   12707             : /* "View.MemoryView":711
   12708             :  * 
   12709             :  * @cname('__pyx_memview_slice')
   12710             :  * cdef memoryview memview_slice(memoryview memview, object indices):             # <<<<<<<<<<<<<<
   12711             :  *     cdef int new_ndim = 0, suboffset_dim = -1, dim
   12712             :  *     cdef bint negative_step
   12713             :  */
   12714             : 
   12715           0 : static struct __pyx_memoryview_obj *__pyx_memview_slice(struct __pyx_memoryview_obj *__pyx_v_memview, PyObject *__pyx_v_indices) {
   12716           0 :   int __pyx_v_new_ndim;
   12717           0 :   int __pyx_v_suboffset_dim;
   12718           0 :   int __pyx_v_dim;
   12719           0 :   __Pyx_memviewslice __pyx_v_src;
   12720           0 :   __Pyx_memviewslice __pyx_v_dst;
   12721           0 :   __Pyx_memviewslice *__pyx_v_p_src;
   12722           0 :   struct __pyx_memoryviewslice_obj *__pyx_v_memviewsliceobj = 0;
   12723           0 :   __Pyx_memviewslice *__pyx_v_p_dst;
   12724           0 :   int *__pyx_v_p_suboffset_dim;
   12725           0 :   Py_ssize_t __pyx_v_start;
   12726           0 :   Py_ssize_t __pyx_v_stop;
   12727           0 :   Py_ssize_t __pyx_v_step;
   12728           0 :   Py_ssize_t __pyx_v_cindex;
   12729           0 :   int __pyx_v_have_start;
   12730           0 :   int __pyx_v_have_stop;
   12731           0 :   int __pyx_v_have_step;
   12732           0 :   PyObject *__pyx_v_index = NULL;
   12733           0 :   struct __pyx_memoryview_obj *__pyx_r = NULL;
   12734             :   __Pyx_RefNannyDeclarations
   12735           0 :   int __pyx_t_1;
   12736           0 :   PyObject *__pyx_t_2 = NULL;
   12737           0 :   struct __pyx_memoryview_obj *__pyx_t_3;
   12738           0 :   char *__pyx_t_4;
   12739           0 :   int __pyx_t_5;
   12740           0 :   Py_ssize_t __pyx_t_6;
   12741           0 :   PyObject *(*__pyx_t_7)(PyObject *);
   12742           0 :   PyObject *__pyx_t_8 = NULL;
   12743           0 :   Py_ssize_t __pyx_t_9;
   12744           0 :   int __pyx_t_10;
   12745           0 :   Py_ssize_t __pyx_t_11;
   12746           0 :   int __pyx_lineno = 0;
   12747           0 :   const char *__pyx_filename = NULL;
   12748           0 :   int __pyx_clineno = 0;
   12749           0 :   __Pyx_RefNannySetupContext("memview_slice", 1);
   12750             : 
   12751             :   /* "View.MemoryView":712
   12752             :  * @cname('__pyx_memview_slice')
   12753             :  * cdef memoryview memview_slice(memoryview memview, object indices):
   12754             :  *     cdef int new_ndim = 0, suboffset_dim = -1, dim             # <<<<<<<<<<<<<<
   12755             :  *     cdef bint negative_step
   12756             :  *     cdef __Pyx_memviewslice src, dst
   12757             :  */
   12758           0 :   __pyx_v_new_ndim = 0;
   12759           0 :   __pyx_v_suboffset_dim = -1;
   12760             : 
   12761             :   /* "View.MemoryView":719
   12762             :  * 
   12763             :  * 
   12764             :  *     memset(&dst, 0, sizeof(dst))             # <<<<<<<<<<<<<<
   12765             :  * 
   12766             :  *     cdef _memoryviewslice memviewsliceobj
   12767             :  */
   12768           0 :   (void)(memset((&__pyx_v_dst), 0, (sizeof(__pyx_v_dst))));
   12769             : 
   12770             :   /* "View.MemoryView":723
   12771             :  *     cdef _memoryviewslice memviewsliceobj
   12772             :  * 
   12773             :  *     assert memview.view.ndim > 0             # <<<<<<<<<<<<<<
   12774             :  * 
   12775             :  *     if isinstance(memview, _memoryviewslice):
   12776             :  */
   12777             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   12778           0 :   if (unlikely(__pyx_assertions_enabled())) {
   12779           0 :     __pyx_t_1 = (__pyx_v_memview->view.ndim > 0);
   12780           0 :     if (unlikely(!__pyx_t_1)) {
   12781           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, 0, 0, 0);
   12782           0 :       __PYX_ERR(1, 723, __pyx_L1_error)
   12783             :     }
   12784             :   }
   12785             :   #else
   12786             :   if ((1)); else __PYX_ERR(1, 723, __pyx_L1_error)
   12787             :   #endif
   12788             : 
   12789             :   /* "View.MemoryView":725
   12790             :  *     assert memview.view.ndim > 0
   12791             :  * 
   12792             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   12793             :  *         memviewsliceobj = memview
   12794             :  *         p_src = &memviewsliceobj.from_slice
   12795             :  */
   12796           0 :   __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type); 
   12797           0 :   if (__pyx_t_1) {
   12798             : 
   12799             :     /* "View.MemoryView":726
   12800             :  * 
   12801             :  *     if isinstance(memview, _memoryviewslice):
   12802             :  *         memviewsliceobj = memview             # <<<<<<<<<<<<<<
   12803             :  *         p_src = &memviewsliceobj.from_slice
   12804             :  *     else:
   12805             :  */
   12806           0 :     if (!(likely(((((PyObject *)__pyx_v_memview)) == Py_None) || likely(__Pyx_TypeTest(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type))))) __PYX_ERR(1, 726, __pyx_L1_error)
   12807           0 :     __pyx_t_2 = ((PyObject *)__pyx_v_memview);
   12808           0 :     __Pyx_INCREF(__pyx_t_2);
   12809           0 :     __pyx_v_memviewsliceobj = ((struct __pyx_memoryviewslice_obj *)__pyx_t_2);
   12810           0 :     __pyx_t_2 = 0;
   12811             : 
   12812             :     /* "View.MemoryView":727
   12813             :  *     if isinstance(memview, _memoryviewslice):
   12814             :  *         memviewsliceobj = memview
   12815             :  *         p_src = &memviewsliceobj.from_slice             # <<<<<<<<<<<<<<
   12816             :  *     else:
   12817             :  *         slice_copy(memview, &src)
   12818             :  */
   12819           0 :     __pyx_v_p_src = (&__pyx_v_memviewsliceobj->from_slice);
   12820             : 
   12821             :     /* "View.MemoryView":725
   12822             :  *     assert memview.view.ndim > 0
   12823             :  * 
   12824             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   12825             :  *         memviewsliceobj = memview
   12826             :  *         p_src = &memviewsliceobj.from_slice
   12827             :  */
   12828           0 :     goto __pyx_L3;
   12829             :   }
   12830             : 
   12831             :   /* "View.MemoryView":729
   12832             :  *         p_src = &memviewsliceobj.from_slice
   12833             :  *     else:
   12834             :  *         slice_copy(memview, &src)             # <<<<<<<<<<<<<<
   12835             :  *         p_src = &src
   12836             :  * 
   12837             :  */
   12838             :   /*else*/ {
   12839           0 :     __pyx_memoryview_slice_copy(__pyx_v_memview, (&__pyx_v_src));
   12840             : 
   12841             :     /* "View.MemoryView":730
   12842             :  *     else:
   12843             :  *         slice_copy(memview, &src)
   12844             :  *         p_src = &src             # <<<<<<<<<<<<<<
   12845             :  * 
   12846             :  * 
   12847             :  */
   12848           0 :     __pyx_v_p_src = (&__pyx_v_src);
   12849             :   }
   12850           0 :   __pyx_L3:;
   12851             : 
   12852             :   /* "View.MemoryView":736
   12853             :  * 
   12854             :  * 
   12855             :  *     dst.memview = p_src.memview             # <<<<<<<<<<<<<<
   12856             :  *     dst.data = p_src.data
   12857             :  * 
   12858             :  */
   12859           0 :   __pyx_t_3 = __pyx_v_p_src->memview;
   12860           0 :   __pyx_v_dst.memview = __pyx_t_3;
   12861             : 
   12862             :   /* "View.MemoryView":737
   12863             :  * 
   12864             :  *     dst.memview = p_src.memview
   12865             :  *     dst.data = p_src.data             # <<<<<<<<<<<<<<
   12866             :  * 
   12867             :  * 
   12868             :  */
   12869           0 :   __pyx_t_4 = __pyx_v_p_src->data;
   12870           0 :   __pyx_v_dst.data = __pyx_t_4;
   12871             : 
   12872             :   /* "View.MemoryView":742
   12873             :  * 
   12874             :  * 
   12875             :  *     cdef __Pyx_memviewslice *p_dst = &dst             # <<<<<<<<<<<<<<
   12876             :  *     cdef int *p_suboffset_dim = &suboffset_dim
   12877             :  *     cdef Py_ssize_t start, stop, step, cindex
   12878             :  */
   12879           0 :   __pyx_v_p_dst = (&__pyx_v_dst);
   12880             : 
   12881             :   /* "View.MemoryView":743
   12882             :  * 
   12883             :  *     cdef __Pyx_memviewslice *p_dst = &dst
   12884             :  *     cdef int *p_suboffset_dim = &suboffset_dim             # <<<<<<<<<<<<<<
   12885             :  *     cdef Py_ssize_t start, stop, step, cindex
   12886             :  *     cdef bint have_start, have_stop, have_step
   12887             :  */
   12888           0 :   __pyx_v_p_suboffset_dim = (&__pyx_v_suboffset_dim);
   12889             : 
   12890             :   /* "View.MemoryView":747
   12891             :  *     cdef bint have_start, have_stop, have_step
   12892             :  * 
   12893             :  *     for dim, index in enumerate(indices):             # <<<<<<<<<<<<<<
   12894             :  *         if PyIndex_Check(index):
   12895             :  *             cindex = index
   12896             :  */
   12897           0 :   __pyx_t_5 = 0;
   12898           0 :   if (likely(PyList_CheckExact(__pyx_v_indices)) || PyTuple_CheckExact(__pyx_v_indices)) {
   12899           0 :     __pyx_t_2 = __pyx_v_indices; __Pyx_INCREF(__pyx_t_2);
   12900           0 :     __pyx_t_6 = 0;
   12901           0 :     __pyx_t_7 = NULL;
   12902             :   } else {
   12903           0 :     __pyx_t_6 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_indices); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 747, __pyx_L1_error)
   12904           0 :     __Pyx_GOTREF(__pyx_t_2);
   12905           0 :     __pyx_t_7 = __Pyx_PyObject_GetIterNextFunc(__pyx_t_2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 747, __pyx_L1_error)
   12906             :   }
   12907           0 :   for (;;) {
   12908           0 :     if (likely(!__pyx_t_7)) {
   12909           0 :       if (likely(PyList_CheckExact(__pyx_t_2))) {
   12910             :         {
   12911           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_2);
   12912             :           #if !CYTHON_ASSUME_SAFE_MACROS
   12913             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 747, __pyx_L1_error)
   12914             :           #endif
   12915           0 :           if (__pyx_t_6 >= __pyx_temp) break;
   12916             :         }
   12917             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   12918           0 :         __pyx_t_8 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_6); __Pyx_INCREF(__pyx_t_8); __pyx_t_6++; if (unlikely((0 < 0))) __PYX_ERR(1, 747, __pyx_L1_error)
   12919             :         #else
   12920             :         __pyx_t_8 = __Pyx_PySequence_ITEM(__pyx_t_2, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 747, __pyx_L1_error)
   12921             :         __Pyx_GOTREF(__pyx_t_8);
   12922             :         #endif
   12923             :       } else {
   12924             :         {
   12925           0 :           Py_ssize_t __pyx_temp = __Pyx_PyTuple_GET_SIZE(__pyx_t_2);
   12926             :           #if !CYTHON_ASSUME_SAFE_MACROS
   12927             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(1, 747, __pyx_L1_error)
   12928             :           #endif
   12929           0 :           if (__pyx_t_6 >= __pyx_temp) break;
   12930             :         }
   12931             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   12932           0 :         __pyx_t_8 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_6); __Pyx_INCREF(__pyx_t_8); __pyx_t_6++; if (unlikely((0 < 0))) __PYX_ERR(1, 747, __pyx_L1_error)
   12933             :         #else
   12934             :         __pyx_t_8 = __Pyx_PySequence_ITEM(__pyx_t_2, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 747, __pyx_L1_error)
   12935             :         __Pyx_GOTREF(__pyx_t_8);
   12936             :         #endif
   12937             :       }
   12938             :     } else {
   12939           0 :       __pyx_t_8 = __pyx_t_7(__pyx_t_2);
   12940           0 :       if (unlikely(!__pyx_t_8)) {
   12941           0 :         PyObject* exc_type = PyErr_Occurred();
   12942           0 :         if (exc_type) {
   12943           0 :           if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
   12944           0 :           else __PYX_ERR(1, 747, __pyx_L1_error)
   12945             :         }
   12946             :         break;
   12947             :       }
   12948           0 :       __Pyx_GOTREF(__pyx_t_8);
   12949             :     }
   12950           0 :     __Pyx_XDECREF_SET(__pyx_v_index, __pyx_t_8);
   12951           0 :     __pyx_t_8 = 0;
   12952           0 :     __pyx_v_dim = __pyx_t_5;
   12953           0 :     __pyx_t_5 = (__pyx_t_5 + 1);
   12954             : 
   12955             :     /* "View.MemoryView":748
   12956             :  * 
   12957             :  *     for dim, index in enumerate(indices):
   12958             :  *         if PyIndex_Check(index):             # <<<<<<<<<<<<<<
   12959             :  *             cindex = index
   12960             :  *             slice_memviewslice(
   12961             :  */
   12962           0 :     __pyx_t_1 = (PyIndex_Check(__pyx_v_index) != 0);
   12963           0 :     if (__pyx_t_1) {
   12964             : 
   12965             :       /* "View.MemoryView":749
   12966             :  *     for dim, index in enumerate(indices):
   12967             :  *         if PyIndex_Check(index):
   12968             :  *             cindex = index             # <<<<<<<<<<<<<<
   12969             :  *             slice_memviewslice(
   12970             :  *                 p_dst, p_src.shape[dim], p_src.strides[dim], p_src.suboffsets[dim],
   12971             :  */
   12972           0 :       __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_index); if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 749, __pyx_L1_error)
   12973           0 :       __pyx_v_cindex = __pyx_t_9;
   12974             : 
   12975             :       /* "View.MemoryView":750
   12976             :  *         if PyIndex_Check(index):
   12977             :  *             cindex = index
   12978             :  *             slice_memviewslice(             # <<<<<<<<<<<<<<
   12979             :  *                 p_dst, p_src.shape[dim], p_src.strides[dim], p_src.suboffsets[dim],
   12980             :  *                 dim, new_ndim, p_suboffset_dim,
   12981             :  */
   12982           0 :       __pyx_t_10 = __pyx_memoryview_slice_memviewslice(__pyx_v_p_dst, (__pyx_v_p_src->shape[__pyx_v_dim]), (__pyx_v_p_src->strides[__pyx_v_dim]), (__pyx_v_p_src->suboffsets[__pyx_v_dim]), __pyx_v_dim, __pyx_v_new_ndim, __pyx_v_p_suboffset_dim, __pyx_v_cindex, 0, 0, 0, 0, 0, 0); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(1, 750, __pyx_L1_error)
   12983             : 
   12984             :       /* "View.MemoryView":748
   12985             :  * 
   12986             :  *     for dim, index in enumerate(indices):
   12987             :  *         if PyIndex_Check(index):             # <<<<<<<<<<<<<<
   12988             :  *             cindex = index
   12989             :  *             slice_memviewslice(
   12990             :  */
   12991           0 :       goto __pyx_L6;
   12992             :     }
   12993             : 
   12994             :     /* "View.MemoryView":756
   12995             :  *                 0, 0, 0, # have_{start,stop,step}
   12996             :  *                 False)
   12997             :  *         elif index is None:             # <<<<<<<<<<<<<<
   12998             :  *             p_dst.shape[new_ndim] = 1
   12999             :  *             p_dst.strides[new_ndim] = 0
   13000             :  */
   13001           0 :     __pyx_t_1 = (__pyx_v_index == Py_None);
   13002           0 :     if (__pyx_t_1) {
   13003             : 
   13004             :       /* "View.MemoryView":757
   13005             :  *                 False)
   13006             :  *         elif index is None:
   13007             :  *             p_dst.shape[new_ndim] = 1             # <<<<<<<<<<<<<<
   13008             :  *             p_dst.strides[new_ndim] = 0
   13009             :  *             p_dst.suboffsets[new_ndim] = -1
   13010             :  */
   13011           0 :       (__pyx_v_p_dst->shape[__pyx_v_new_ndim]) = 1;
   13012             : 
   13013             :       /* "View.MemoryView":758
   13014             :  *         elif index is None:
   13015             :  *             p_dst.shape[new_ndim] = 1
   13016             :  *             p_dst.strides[new_ndim] = 0             # <<<<<<<<<<<<<<
   13017             :  *             p_dst.suboffsets[new_ndim] = -1
   13018             :  *             new_ndim += 1
   13019             :  */
   13020           0 :       (__pyx_v_p_dst->strides[__pyx_v_new_ndim]) = 0;
   13021             : 
   13022             :       /* "View.MemoryView":759
   13023             :  *             p_dst.shape[new_ndim] = 1
   13024             :  *             p_dst.strides[new_ndim] = 0
   13025             :  *             p_dst.suboffsets[new_ndim] = -1             # <<<<<<<<<<<<<<
   13026             :  *             new_ndim += 1
   13027             :  *         else:
   13028             :  */
   13029           0 :       (__pyx_v_p_dst->suboffsets[__pyx_v_new_ndim]) = -1L;
   13030             : 
   13031             :       /* "View.MemoryView":760
   13032             :  *             p_dst.strides[new_ndim] = 0
   13033             :  *             p_dst.suboffsets[new_ndim] = -1
   13034             :  *             new_ndim += 1             # <<<<<<<<<<<<<<
   13035             :  *         else:
   13036             :  *             start = index.start or 0
   13037             :  */
   13038           0 :       __pyx_v_new_ndim = (__pyx_v_new_ndim + 1);
   13039             : 
   13040             :       /* "View.MemoryView":756
   13041             :  *                 0, 0, 0, # have_{start,stop,step}
   13042             :  *                 False)
   13043             :  *         elif index is None:             # <<<<<<<<<<<<<<
   13044             :  *             p_dst.shape[new_ndim] = 1
   13045             :  *             p_dst.strides[new_ndim] = 0
   13046             :  */
   13047           0 :       goto __pyx_L6;
   13048             :     }
   13049             : 
   13050             :     /* "View.MemoryView":762
   13051             :  *             new_ndim += 1
   13052             :  *         else:
   13053             :  *             start = index.start or 0             # <<<<<<<<<<<<<<
   13054             :  *             stop = index.stop or 0
   13055             :  *             step = index.step or 0
   13056             :  */
   13057             :     /*else*/ {
   13058           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_start); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 762, __pyx_L1_error)
   13059           0 :       __Pyx_GOTREF(__pyx_t_8);
   13060           0 :       __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 762, __pyx_L1_error)
   13061           0 :       if (!__pyx_t_1) {
   13062           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13063             :       } else {
   13064           0 :         __pyx_t_11 = __Pyx_PyIndex_AsSsize_t(__pyx_t_8); if (unlikely((__pyx_t_11 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 762, __pyx_L1_error)
   13065           0 :         __pyx_t_9 = __pyx_t_11;
   13066           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13067           0 :         goto __pyx_L7_bool_binop_done;
   13068             :       }
   13069             :       __pyx_t_9 = 0;
   13070           0 :       __pyx_L7_bool_binop_done:;
   13071           0 :       __pyx_v_start = __pyx_t_9;
   13072             : 
   13073             :       /* "View.MemoryView":763
   13074             :  *         else:
   13075             :  *             start = index.start or 0
   13076             :  *             stop = index.stop or 0             # <<<<<<<<<<<<<<
   13077             :  *             step = index.step or 0
   13078             :  * 
   13079             :  */
   13080           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_stop); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 763, __pyx_L1_error)
   13081           0 :       __Pyx_GOTREF(__pyx_t_8);
   13082           0 :       __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 763, __pyx_L1_error)
   13083           0 :       if (!__pyx_t_1) {
   13084           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13085             :       } else {
   13086           0 :         __pyx_t_11 = __Pyx_PyIndex_AsSsize_t(__pyx_t_8); if (unlikely((__pyx_t_11 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 763, __pyx_L1_error)
   13087           0 :         __pyx_t_9 = __pyx_t_11;
   13088           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13089           0 :         goto __pyx_L9_bool_binop_done;
   13090             :       }
   13091             :       __pyx_t_9 = 0;
   13092           0 :       __pyx_L9_bool_binop_done:;
   13093           0 :       __pyx_v_stop = __pyx_t_9;
   13094             : 
   13095             :       /* "View.MemoryView":764
   13096             :  *             start = index.start or 0
   13097             :  *             stop = index.stop or 0
   13098             :  *             step = index.step or 0             # <<<<<<<<<<<<<<
   13099             :  * 
   13100             :  *             have_start = index.start is not None
   13101             :  */
   13102           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_step); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 764, __pyx_L1_error)
   13103           0 :       __Pyx_GOTREF(__pyx_t_8);
   13104           0 :       __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely((__pyx_t_1 < 0))) __PYX_ERR(1, 764, __pyx_L1_error)
   13105           0 :       if (!__pyx_t_1) {
   13106           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13107             :       } else {
   13108           0 :         __pyx_t_11 = __Pyx_PyIndex_AsSsize_t(__pyx_t_8); if (unlikely((__pyx_t_11 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 764, __pyx_L1_error)
   13109           0 :         __pyx_t_9 = __pyx_t_11;
   13110           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13111           0 :         goto __pyx_L11_bool_binop_done;
   13112             :       }
   13113             :       __pyx_t_9 = 0;
   13114           0 :       __pyx_L11_bool_binop_done:;
   13115           0 :       __pyx_v_step = __pyx_t_9;
   13116             : 
   13117             :       /* "View.MemoryView":766
   13118             :  *             step = index.step or 0
   13119             :  * 
   13120             :  *             have_start = index.start is not None             # <<<<<<<<<<<<<<
   13121             :  *             have_stop = index.stop is not None
   13122             :  *             have_step = index.step is not None
   13123             :  */
   13124           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_start); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 766, __pyx_L1_error)
   13125           0 :       __Pyx_GOTREF(__pyx_t_8);
   13126           0 :       __pyx_t_1 = (__pyx_t_8 != Py_None);
   13127           0 :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13128           0 :       __pyx_v_have_start = __pyx_t_1;
   13129             : 
   13130             :       /* "View.MemoryView":767
   13131             :  * 
   13132             :  *             have_start = index.start is not None
   13133             :  *             have_stop = index.stop is not None             # <<<<<<<<<<<<<<
   13134             :  *             have_step = index.step is not None
   13135             :  * 
   13136             :  */
   13137           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_stop); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 767, __pyx_L1_error)
   13138           0 :       __Pyx_GOTREF(__pyx_t_8);
   13139           0 :       __pyx_t_1 = (__pyx_t_8 != Py_None);
   13140           0 :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13141           0 :       __pyx_v_have_stop = __pyx_t_1;
   13142             : 
   13143             :       /* "View.MemoryView":768
   13144             :  *             have_start = index.start is not None
   13145             :  *             have_stop = index.stop is not None
   13146             :  *             have_step = index.step is not None             # <<<<<<<<<<<<<<
   13147             :  * 
   13148             :  *             slice_memviewslice(
   13149             :  */
   13150           0 :       __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_step); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 768, __pyx_L1_error)
   13151           0 :       __Pyx_GOTREF(__pyx_t_8);
   13152           0 :       __pyx_t_1 = (__pyx_t_8 != Py_None);
   13153           0 :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   13154           0 :       __pyx_v_have_step = __pyx_t_1;
   13155             : 
   13156             :       /* "View.MemoryView":770
   13157             :  *             have_step = index.step is not None
   13158             :  * 
   13159             :  *             slice_memviewslice(             # <<<<<<<<<<<<<<
   13160             :  *                 p_dst, p_src.shape[dim], p_src.strides[dim], p_src.suboffsets[dim],
   13161             :  *                 dim, new_ndim, p_suboffset_dim,
   13162             :  */
   13163           0 :       __pyx_t_10 = __pyx_memoryview_slice_memviewslice(__pyx_v_p_dst, (__pyx_v_p_src->shape[__pyx_v_dim]), (__pyx_v_p_src->strides[__pyx_v_dim]), (__pyx_v_p_src->suboffsets[__pyx_v_dim]), __pyx_v_dim, __pyx_v_new_ndim, __pyx_v_p_suboffset_dim, __pyx_v_start, __pyx_v_stop, __pyx_v_step, __pyx_v_have_start, __pyx_v_have_stop, __pyx_v_have_step, 1); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(1, 770, __pyx_L1_error)
   13164             : 
   13165             :       /* "View.MemoryView":776
   13166             :  *                 have_start, have_stop, have_step,
   13167             :  *                 True)
   13168             :  *             new_ndim += 1             # <<<<<<<<<<<<<<
   13169             :  * 
   13170             :  *     if isinstance(memview, _memoryviewslice):
   13171             :  */
   13172           0 :       __pyx_v_new_ndim = (__pyx_v_new_ndim + 1);
   13173             :     }
   13174           0 :     __pyx_L6:;
   13175             : 
   13176             :     /* "View.MemoryView":747
   13177             :  *     cdef bint have_start, have_stop, have_step
   13178             :  * 
   13179             :  *     for dim, index in enumerate(indices):             # <<<<<<<<<<<<<<
   13180             :  *         if PyIndex_Check(index):
   13181             :  *             cindex = index
   13182             :  */
   13183             :   }
   13184           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   13185             : 
   13186             :   /* "View.MemoryView":778
   13187             :  *             new_ndim += 1
   13188             :  * 
   13189             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   13190             :  *         return memoryview_fromslice(dst, new_ndim,
   13191             :  *                                     memviewsliceobj.to_object_func,
   13192             :  */
   13193           0 :   __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type); 
   13194           0 :   if (__pyx_t_1) {
   13195             : 
   13196             :     /* "View.MemoryView":779
   13197             :  * 
   13198             :  *     if isinstance(memview, _memoryviewslice):
   13199             :  *         return memoryview_fromslice(dst, new_ndim,             # <<<<<<<<<<<<<<
   13200             :  *                                     memviewsliceobj.to_object_func,
   13201             :  *                                     memviewsliceobj.to_dtype_func,
   13202             :  */
   13203           0 :     __Pyx_XDECREF((PyObject *)__pyx_r);
   13204             : 
   13205             :     /* "View.MemoryView":780
   13206             :  *     if isinstance(memview, _memoryviewslice):
   13207             :  *         return memoryview_fromslice(dst, new_ndim,
   13208             :  *                                     memviewsliceobj.to_object_func,             # <<<<<<<<<<<<<<
   13209             :  *                                     memviewsliceobj.to_dtype_func,
   13210             :  *                                     memview.dtype_is_object)
   13211             :  */
   13212           0 :     if (unlikely(!__pyx_v_memviewsliceobj)) { __Pyx_RaiseUnboundLocalError("memviewsliceobj"); __PYX_ERR(1, 780, __pyx_L1_error) }
   13213             : 
   13214             :     /* "View.MemoryView":781
   13215             :  *         return memoryview_fromslice(dst, new_ndim,
   13216             :  *                                     memviewsliceobj.to_object_func,
   13217             :  *                                     memviewsliceobj.to_dtype_func,             # <<<<<<<<<<<<<<
   13218             :  *                                     memview.dtype_is_object)
   13219             :  *     else:
   13220             :  */
   13221           0 :     if (unlikely(!__pyx_v_memviewsliceobj)) { __Pyx_RaiseUnboundLocalError("memviewsliceobj"); __PYX_ERR(1, 781, __pyx_L1_error) }
   13222             : 
   13223             :     /* "View.MemoryView":779
   13224             :  * 
   13225             :  *     if isinstance(memview, _memoryviewslice):
   13226             :  *         return memoryview_fromslice(dst, new_ndim,             # <<<<<<<<<<<<<<
   13227             :  *                                     memviewsliceobj.to_object_func,
   13228             :  *                                     memviewsliceobj.to_dtype_func,
   13229             :  */
   13230           0 :     __pyx_t_2 = __pyx_memoryview_fromslice(__pyx_v_dst, __pyx_v_new_ndim, __pyx_v_memviewsliceobj->to_object_func, __pyx_v_memviewsliceobj->to_dtype_func, __pyx_v_memview->dtype_is_object); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 779, __pyx_L1_error)
   13231           0 :     __Pyx_GOTREF(__pyx_t_2);
   13232           0 :     if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_memoryview_type))))) __PYX_ERR(1, 779, __pyx_L1_error)
   13233           0 :     __pyx_r = ((struct __pyx_memoryview_obj *)__pyx_t_2);
   13234           0 :     __pyx_t_2 = 0;
   13235           0 :     goto __pyx_L0;
   13236             : 
   13237             :     /* "View.MemoryView":778
   13238             :  *             new_ndim += 1
   13239             :  * 
   13240             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   13241             :  *         return memoryview_fromslice(dst, new_ndim,
   13242             :  *                                     memviewsliceobj.to_object_func,
   13243             :  */
   13244             :   }
   13245             : 
   13246             :   /* "View.MemoryView":784
   13247             :  *                                     memview.dtype_is_object)
   13248             :  *     else:
   13249             :  *         return memoryview_fromslice(dst, new_ndim, NULL, NULL,             # <<<<<<<<<<<<<<
   13250             :  *                                     memview.dtype_is_object)
   13251             :  * 
   13252             :  */
   13253             :   /*else*/ {
   13254           0 :     __Pyx_XDECREF((PyObject *)__pyx_r);
   13255             : 
   13256             :     /* "View.MemoryView":785
   13257             :  *     else:
   13258             :  *         return memoryview_fromslice(dst, new_ndim, NULL, NULL,
   13259             :  *                                     memview.dtype_is_object)             # <<<<<<<<<<<<<<
   13260             :  * 
   13261             :  * 
   13262             :  */
   13263           0 :     __pyx_t_2 = __pyx_memoryview_fromslice(__pyx_v_dst, __pyx_v_new_ndim, NULL, NULL, __pyx_v_memview->dtype_is_object); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 784, __pyx_L1_error)
   13264           0 :     __Pyx_GOTREF(__pyx_t_2);
   13265             : 
   13266             :     /* "View.MemoryView":784
   13267             :  *                                     memview.dtype_is_object)
   13268             :  *     else:
   13269             :  *         return memoryview_fromslice(dst, new_ndim, NULL, NULL,             # <<<<<<<<<<<<<<
   13270             :  *                                     memview.dtype_is_object)
   13271             :  * 
   13272             :  */
   13273           0 :     if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_memoryview_type))))) __PYX_ERR(1, 784, __pyx_L1_error)
   13274           0 :     __pyx_r = ((struct __pyx_memoryview_obj *)__pyx_t_2);
   13275           0 :     __pyx_t_2 = 0;
   13276           0 :     goto __pyx_L0;
   13277             :   }
   13278             : 
   13279             :   /* "View.MemoryView":711
   13280             :  * 
   13281             :  * @cname('__pyx_memview_slice')
   13282             :  * cdef memoryview memview_slice(memoryview memview, object indices):             # <<<<<<<<<<<<<<
   13283             :  *     cdef int new_ndim = 0, suboffset_dim = -1, dim
   13284             :  *     cdef bint negative_step
   13285             :  */
   13286             : 
   13287             :   /* function exit code */
   13288           0 :   __pyx_L1_error:;
   13289           0 :   __Pyx_XDECREF(__pyx_t_2);
   13290           0 :   __Pyx_XDECREF(__pyx_t_8);
   13291           0 :   __Pyx_AddTraceback("View.MemoryView.memview_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
   13292           0 :   __pyx_r = 0;
   13293           0 :   __pyx_L0:;
   13294           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_memviewsliceobj);
   13295           0 :   __Pyx_XDECREF(__pyx_v_index);
   13296           0 :   __Pyx_XGIVEREF((PyObject *)__pyx_r);
   13297           0 :   __Pyx_RefNannyFinishContext();
   13298           0 :   return __pyx_r;
   13299             : }
   13300             : 
   13301             : /* "View.MemoryView":793
   13302             :  * 
   13303             :  * @cname('__pyx_memoryview_slice_memviewslice')
   13304             :  * cdef int slice_memviewslice(             # <<<<<<<<<<<<<<
   13305             :  *         __Pyx_memviewslice *dst,
   13306             :  *         Py_ssize_t shape, Py_ssize_t stride, Py_ssize_t suboffset,
   13307             :  */
   13308             : 
   13309           0 : static int __pyx_memoryview_slice_memviewslice(__Pyx_memviewslice *__pyx_v_dst, Py_ssize_t __pyx_v_shape, Py_ssize_t __pyx_v_stride, Py_ssize_t __pyx_v_suboffset, int __pyx_v_dim, int __pyx_v_new_ndim, int *__pyx_v_suboffset_dim, Py_ssize_t __pyx_v_start, Py_ssize_t __pyx_v_stop, Py_ssize_t __pyx_v_step, int __pyx_v_have_start, int __pyx_v_have_stop, int __pyx_v_have_step, int __pyx_v_is_slice) {
   13310           0 :   Py_ssize_t __pyx_v_new_shape;
   13311           0 :   int __pyx_v_negative_step;
   13312           0 :   int __pyx_r;
   13313           0 :   int __pyx_t_1;
   13314           0 :   int __pyx_t_2;
   13315           0 :   int __pyx_t_3;
   13316           0 :   int __pyx_lineno = 0;
   13317           0 :   const char *__pyx_filename = NULL;
   13318           0 :   int __pyx_clineno = 0;
   13319             :   #ifdef WITH_THREAD
   13320           0 :   PyGILState_STATE __pyx_gilstate_save;
   13321             :   #endif
   13322             : 
   13323             :   /* "View.MemoryView":813
   13324             :  *     cdef bint negative_step
   13325             :  * 
   13326             :  *     if not is_slice:             # <<<<<<<<<<<<<<
   13327             :  * 
   13328             :  *         if start < 0:
   13329             :  */
   13330           0 :   __pyx_t_1 = (!__pyx_v_is_slice);
   13331           0 :   if (__pyx_t_1) {
   13332             : 
   13333             :     /* "View.MemoryView":815
   13334             :  *     if not is_slice:
   13335             :  * 
   13336             :  *         if start < 0:             # <<<<<<<<<<<<<<
   13337             :  *             start += shape
   13338             :  *         if not 0 <= start < shape:
   13339             :  */
   13340           0 :     __pyx_t_1 = (__pyx_v_start < 0);
   13341           0 :     if (__pyx_t_1) {
   13342             : 
   13343             :       /* "View.MemoryView":816
   13344             :  * 
   13345             :  *         if start < 0:
   13346             :  *             start += shape             # <<<<<<<<<<<<<<
   13347             :  *         if not 0 <= start < shape:
   13348             :  *             _err_dim(PyExc_IndexError, "Index out of bounds (axis %d)", dim)
   13349             :  */
   13350           0 :       __pyx_v_start = (__pyx_v_start + __pyx_v_shape);
   13351             : 
   13352             :       /* "View.MemoryView":815
   13353             :  *     if not is_slice:
   13354             :  * 
   13355             :  *         if start < 0:             # <<<<<<<<<<<<<<
   13356             :  *             start += shape
   13357             :  *         if not 0 <= start < shape:
   13358             :  */
   13359             :     }
   13360             : 
   13361             :     /* "View.MemoryView":817
   13362             :  *         if start < 0:
   13363             :  *             start += shape
   13364             :  *         if not 0 <= start < shape:             # <<<<<<<<<<<<<<
   13365             :  *             _err_dim(PyExc_IndexError, "Index out of bounds (axis %d)", dim)
   13366             :  *     else:
   13367             :  */
   13368           0 :     __pyx_t_1 = (0 <= __pyx_v_start);
   13369           0 :     if (__pyx_t_1) {
   13370           0 :       __pyx_t_1 = (__pyx_v_start < __pyx_v_shape);
   13371             :     }
   13372           0 :     __pyx_t_2 = (!__pyx_t_1);
   13373           0 :     if (__pyx_t_2) {
   13374             : 
   13375             :       /* "View.MemoryView":818
   13376             :  *             start += shape
   13377             :  *         if not 0 <= start < shape:
   13378             :  *             _err_dim(PyExc_IndexError, "Index out of bounds (axis %d)", dim)             # <<<<<<<<<<<<<<
   13379             :  *     else:
   13380             :  * 
   13381             :  */
   13382           0 :       __pyx_t_3 = __pyx_memoryview_err_dim(PyExc_IndexError, __pyx_kp_s_Index_out_of_bounds_axis_d, __pyx_v_dim); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 818, __pyx_L1_error)
   13383             : 
   13384             :       /* "View.MemoryView":817
   13385             :  *         if start < 0:
   13386             :  *             start += shape
   13387             :  *         if not 0 <= start < shape:             # <<<<<<<<<<<<<<
   13388             :  *             _err_dim(PyExc_IndexError, "Index out of bounds (axis %d)", dim)
   13389             :  *     else:
   13390             :  */
   13391             :     }
   13392             : 
   13393             :     /* "View.MemoryView":813
   13394             :  *     cdef bint negative_step
   13395             :  * 
   13396             :  *     if not is_slice:             # <<<<<<<<<<<<<<
   13397             :  * 
   13398             :  *         if start < 0:
   13399             :  */
   13400           0 :     goto __pyx_L3;
   13401             :   }
   13402             : 
   13403             :   /* "View.MemoryView":821
   13404             :  *     else:
   13405             :  * 
   13406             :  *         if have_step:             # <<<<<<<<<<<<<<
   13407             :  *             negative_step = step < 0
   13408             :  *             if step == 0:
   13409             :  */
   13410             :   /*else*/ {
   13411           0 :     __pyx_t_2 = (__pyx_v_have_step != 0);
   13412           0 :     if (__pyx_t_2) {
   13413             : 
   13414             :       /* "View.MemoryView":822
   13415             :  * 
   13416             :  *         if have_step:
   13417             :  *             negative_step = step < 0             # <<<<<<<<<<<<<<
   13418             :  *             if step == 0:
   13419             :  *                 _err_dim(PyExc_ValueError, "Step may not be zero (axis %d)", dim)
   13420             :  */
   13421           0 :       __pyx_v_negative_step = (__pyx_v_step < 0);
   13422             : 
   13423             :       /* "View.MemoryView":823
   13424             :  *         if have_step:
   13425             :  *             negative_step = step < 0
   13426             :  *             if step == 0:             # <<<<<<<<<<<<<<
   13427             :  *                 _err_dim(PyExc_ValueError, "Step may not be zero (axis %d)", dim)
   13428             :  *         else:
   13429             :  */
   13430           0 :       __pyx_t_2 = (__pyx_v_step == 0);
   13431           0 :       if (__pyx_t_2) {
   13432             : 
   13433             :         /* "View.MemoryView":824
   13434             :  *             negative_step = step < 0
   13435             :  *             if step == 0:
   13436             :  *                 _err_dim(PyExc_ValueError, "Step may not be zero (axis %d)", dim)             # <<<<<<<<<<<<<<
   13437             :  *         else:
   13438             :  *             negative_step = False
   13439             :  */
   13440           0 :         __pyx_t_3 = __pyx_memoryview_err_dim(PyExc_ValueError, __pyx_kp_s_Step_may_not_be_zero_axis_d, __pyx_v_dim); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 824, __pyx_L1_error)
   13441             : 
   13442             :         /* "View.MemoryView":823
   13443             :  *         if have_step:
   13444             :  *             negative_step = step < 0
   13445             :  *             if step == 0:             # <<<<<<<<<<<<<<
   13446             :  *                 _err_dim(PyExc_ValueError, "Step may not be zero (axis %d)", dim)
   13447             :  *         else:
   13448             :  */
   13449             :       }
   13450             : 
   13451             :       /* "View.MemoryView":821
   13452             :  *     else:
   13453             :  * 
   13454             :  *         if have_step:             # <<<<<<<<<<<<<<
   13455             :  *             negative_step = step < 0
   13456             :  *             if step == 0:
   13457             :  */
   13458           0 :       goto __pyx_L6;
   13459             :     }
   13460             : 
   13461             :     /* "View.MemoryView":826
   13462             :  *                 _err_dim(PyExc_ValueError, "Step may not be zero (axis %d)", dim)
   13463             :  *         else:
   13464             :  *             negative_step = False             # <<<<<<<<<<<<<<
   13465             :  *             step = 1
   13466             :  * 
   13467             :  */
   13468             :     /*else*/ {
   13469             :       __pyx_v_negative_step = 0;
   13470             : 
   13471             :       /* "View.MemoryView":827
   13472             :  *         else:
   13473             :  *             negative_step = False
   13474             :  *             step = 1             # <<<<<<<<<<<<<<
   13475             :  * 
   13476             :  * 
   13477             :  */
   13478             :       __pyx_v_step = 1;
   13479             :     }
   13480           0 :     __pyx_L6:;
   13481             : 
   13482             :     /* "View.MemoryView":830
   13483             :  * 
   13484             :  * 
   13485             :  *         if have_start:             # <<<<<<<<<<<<<<
   13486             :  *             if start < 0:
   13487             :  *                 start += shape
   13488             :  */
   13489           0 :     __pyx_t_2 = (__pyx_v_have_start != 0);
   13490           0 :     if (__pyx_t_2) {
   13491             : 
   13492             :       /* "View.MemoryView":831
   13493             :  * 
   13494             :  *         if have_start:
   13495             :  *             if start < 0:             # <<<<<<<<<<<<<<
   13496             :  *                 start += shape
   13497             :  *                 if start < 0:
   13498             :  */
   13499           0 :       __pyx_t_2 = (__pyx_v_start < 0);
   13500           0 :       if (__pyx_t_2) {
   13501             : 
   13502             :         /* "View.MemoryView":832
   13503             :  *         if have_start:
   13504             :  *             if start < 0:
   13505             :  *                 start += shape             # <<<<<<<<<<<<<<
   13506             :  *                 if start < 0:
   13507             :  *                     start = 0
   13508             :  */
   13509           0 :         __pyx_v_start = (__pyx_v_start + __pyx_v_shape);
   13510             : 
   13511             :         /* "View.MemoryView":833
   13512             :  *             if start < 0:
   13513             :  *                 start += shape
   13514             :  *                 if start < 0:             # <<<<<<<<<<<<<<
   13515             :  *                     start = 0
   13516             :  *             elif start >= shape:
   13517             :  */
   13518           0 :         __pyx_t_2 = (__pyx_v_start < 0);
   13519           0 :         if (__pyx_t_2) {
   13520             : 
   13521             :           /* "View.MemoryView":834
   13522             :  *                 start += shape
   13523             :  *                 if start < 0:
   13524             :  *                     start = 0             # <<<<<<<<<<<<<<
   13525             :  *             elif start >= shape:
   13526             :  *                 if negative_step:
   13527             :  */
   13528             :           __pyx_v_start = 0;
   13529             : 
   13530             :           /* "View.MemoryView":833
   13531             :  *             if start < 0:
   13532             :  *                 start += shape
   13533             :  *                 if start < 0:             # <<<<<<<<<<<<<<
   13534             :  *                     start = 0
   13535             :  *             elif start >= shape:
   13536             :  */
   13537             :         }
   13538             : 
   13539             :         /* "View.MemoryView":831
   13540             :  * 
   13541             :  *         if have_start:
   13542             :  *             if start < 0:             # <<<<<<<<<<<<<<
   13543             :  *                 start += shape
   13544             :  *                 if start < 0:
   13545             :  */
   13546           0 :         goto __pyx_L9;
   13547             :       }
   13548             : 
   13549             :       /* "View.MemoryView":835
   13550             :  *                 if start < 0:
   13551             :  *                     start = 0
   13552             :  *             elif start >= shape:             # <<<<<<<<<<<<<<
   13553             :  *                 if negative_step:
   13554             :  *                     start = shape - 1
   13555             :  */
   13556           0 :       __pyx_t_2 = (__pyx_v_start >= __pyx_v_shape);
   13557           0 :       if (__pyx_t_2) {
   13558             : 
   13559             :         /* "View.MemoryView":836
   13560             :  *                     start = 0
   13561             :  *             elif start >= shape:
   13562             :  *                 if negative_step:             # <<<<<<<<<<<<<<
   13563             :  *                     start = shape - 1
   13564             :  *                 else:
   13565             :  */
   13566           0 :         if (__pyx_v_negative_step) {
   13567             : 
   13568             :           /* "View.MemoryView":837
   13569             :  *             elif start >= shape:
   13570             :  *                 if negative_step:
   13571             :  *                     start = shape - 1             # <<<<<<<<<<<<<<
   13572             :  *                 else:
   13573             :  *                     start = shape
   13574             :  */
   13575           0 :           __pyx_v_start = (__pyx_v_shape - 1);
   13576             : 
   13577             :           /* "View.MemoryView":836
   13578             :  *                     start = 0
   13579             :  *             elif start >= shape:
   13580             :  *                 if negative_step:             # <<<<<<<<<<<<<<
   13581             :  *                     start = shape - 1
   13582             :  *                 else:
   13583             :  */
   13584           0 :           goto __pyx_L11;
   13585             :         }
   13586             : 
   13587             :         /* "View.MemoryView":839
   13588             :  *                     start = shape - 1
   13589             :  *                 else:
   13590             :  *                     start = shape             # <<<<<<<<<<<<<<
   13591             :  *         else:
   13592             :  *             if negative_step:
   13593             :  */
   13594             :         /*else*/ {
   13595             :           __pyx_v_start = __pyx_v_shape;
   13596             :         }
   13597           0 :         __pyx_L11:;
   13598             : 
   13599             :         /* "View.MemoryView":835
   13600             :  *                 if start < 0:
   13601             :  *                     start = 0
   13602             :  *             elif start >= shape:             # <<<<<<<<<<<<<<
   13603             :  *                 if negative_step:
   13604             :  *                     start = shape - 1
   13605             :  */
   13606             :       }
   13607           0 :       __pyx_L9:;
   13608             : 
   13609             :       /* "View.MemoryView":830
   13610             :  * 
   13611             :  * 
   13612             :  *         if have_start:             # <<<<<<<<<<<<<<
   13613             :  *             if start < 0:
   13614             :  *                 start += shape
   13615             :  */
   13616           0 :       goto __pyx_L8;
   13617             :     }
   13618             : 
   13619             :     /* "View.MemoryView":841
   13620             :  *                     start = shape
   13621             :  *         else:
   13622             :  *             if negative_step:             # <<<<<<<<<<<<<<
   13623             :  *                 start = shape - 1
   13624             :  *             else:
   13625             :  */
   13626             :     /*else*/ {
   13627           0 :       if (__pyx_v_negative_step) {
   13628             : 
   13629             :         /* "View.MemoryView":842
   13630             :  *         else:
   13631             :  *             if negative_step:
   13632             :  *                 start = shape - 1             # <<<<<<<<<<<<<<
   13633             :  *             else:
   13634             :  *                 start = 0
   13635             :  */
   13636           0 :         __pyx_v_start = (__pyx_v_shape - 1);
   13637             : 
   13638             :         /* "View.MemoryView":841
   13639             :  *                     start = shape
   13640             :  *         else:
   13641             :  *             if negative_step:             # <<<<<<<<<<<<<<
   13642             :  *                 start = shape - 1
   13643             :  *             else:
   13644             :  */
   13645           0 :         goto __pyx_L12;
   13646             :       }
   13647             : 
   13648             :       /* "View.MemoryView":844
   13649             :  *                 start = shape - 1
   13650             :  *             else:
   13651             :  *                 start = 0             # <<<<<<<<<<<<<<
   13652             :  * 
   13653             :  *         if have_stop:
   13654             :  */
   13655             :       /*else*/ {
   13656             :         __pyx_v_start = 0;
   13657             :       }
   13658           0 :       __pyx_L12:;
   13659             :     }
   13660           0 :     __pyx_L8:;
   13661             : 
   13662             :     /* "View.MemoryView":846
   13663             :  *                 start = 0
   13664             :  * 
   13665             :  *         if have_stop:             # <<<<<<<<<<<<<<
   13666             :  *             if stop < 0:
   13667             :  *                 stop += shape
   13668             :  */
   13669           0 :     __pyx_t_2 = (__pyx_v_have_stop != 0);
   13670           0 :     if (__pyx_t_2) {
   13671             : 
   13672             :       /* "View.MemoryView":847
   13673             :  * 
   13674             :  *         if have_stop:
   13675             :  *             if stop < 0:             # <<<<<<<<<<<<<<
   13676             :  *                 stop += shape
   13677             :  *                 if stop < 0:
   13678             :  */
   13679           0 :       __pyx_t_2 = (__pyx_v_stop < 0);
   13680           0 :       if (__pyx_t_2) {
   13681             : 
   13682             :         /* "View.MemoryView":848
   13683             :  *         if have_stop:
   13684             :  *             if stop < 0:
   13685             :  *                 stop += shape             # <<<<<<<<<<<<<<
   13686             :  *                 if stop < 0:
   13687             :  *                     stop = 0
   13688             :  */
   13689           0 :         __pyx_v_stop = (__pyx_v_stop + __pyx_v_shape);
   13690             : 
   13691             :         /* "View.MemoryView":849
   13692             :  *             if stop < 0:
   13693             :  *                 stop += shape
   13694             :  *                 if stop < 0:             # <<<<<<<<<<<<<<
   13695             :  *                     stop = 0
   13696             :  *             elif stop > shape:
   13697             :  */
   13698           0 :         __pyx_t_2 = (__pyx_v_stop < 0);
   13699           0 :         if (__pyx_t_2) {
   13700             : 
   13701             :           /* "View.MemoryView":850
   13702             :  *                 stop += shape
   13703             :  *                 if stop < 0:
   13704             :  *                     stop = 0             # <<<<<<<<<<<<<<
   13705             :  *             elif stop > shape:
   13706             :  *                 stop = shape
   13707             :  */
   13708             :           __pyx_v_stop = 0;
   13709             : 
   13710             :           /* "View.MemoryView":849
   13711             :  *             if stop < 0:
   13712             :  *                 stop += shape
   13713             :  *                 if stop < 0:             # <<<<<<<<<<<<<<
   13714             :  *                     stop = 0
   13715             :  *             elif stop > shape:
   13716             :  */
   13717             :         }
   13718             : 
   13719             :         /* "View.MemoryView":847
   13720             :  * 
   13721             :  *         if have_stop:
   13722             :  *             if stop < 0:             # <<<<<<<<<<<<<<
   13723             :  *                 stop += shape
   13724             :  *                 if stop < 0:
   13725             :  */
   13726           0 :         goto __pyx_L14;
   13727             :       }
   13728             : 
   13729             :       /* "View.MemoryView":851
   13730             :  *                 if stop < 0:
   13731             :  *                     stop = 0
   13732             :  *             elif stop > shape:             # <<<<<<<<<<<<<<
   13733             :  *                 stop = shape
   13734             :  *         else:
   13735             :  */
   13736           0 :       __pyx_t_2 = (__pyx_v_stop > __pyx_v_shape);
   13737           0 :       if (__pyx_t_2) {
   13738             : 
   13739             :         /* "View.MemoryView":852
   13740             :  *                     stop = 0
   13741             :  *             elif stop > shape:
   13742             :  *                 stop = shape             # <<<<<<<<<<<<<<
   13743             :  *         else:
   13744             :  *             if negative_step:
   13745             :  */
   13746             :         __pyx_v_stop = __pyx_v_shape;
   13747             : 
   13748             :         /* "View.MemoryView":851
   13749             :  *                 if stop < 0:
   13750             :  *                     stop = 0
   13751             :  *             elif stop > shape:             # <<<<<<<<<<<<<<
   13752             :  *                 stop = shape
   13753             :  *         else:
   13754             :  */
   13755             :       }
   13756           0 :       __pyx_L14:;
   13757             : 
   13758             :       /* "View.MemoryView":846
   13759             :  *                 start = 0
   13760             :  * 
   13761             :  *         if have_stop:             # <<<<<<<<<<<<<<
   13762             :  *             if stop < 0:
   13763             :  *                 stop += shape
   13764             :  */
   13765           0 :       goto __pyx_L13;
   13766             :     }
   13767             : 
   13768             :     /* "View.MemoryView":854
   13769             :  *                 stop = shape
   13770             :  *         else:
   13771             :  *             if negative_step:             # <<<<<<<<<<<<<<
   13772             :  *                 stop = -1
   13773             :  *             else:
   13774             :  */
   13775             :     /*else*/ {
   13776           0 :       if (__pyx_v_negative_step) {
   13777             : 
   13778             :         /* "View.MemoryView":855
   13779             :  *         else:
   13780             :  *             if negative_step:
   13781             :  *                 stop = -1             # <<<<<<<<<<<<<<
   13782             :  *             else:
   13783             :  *                 stop = shape
   13784             :  */
   13785           0 :         __pyx_v_stop = -1L;
   13786             : 
   13787             :         /* "View.MemoryView":854
   13788             :  *                 stop = shape
   13789             :  *         else:
   13790             :  *             if negative_step:             # <<<<<<<<<<<<<<
   13791             :  *                 stop = -1
   13792             :  *             else:
   13793             :  */
   13794           0 :         goto __pyx_L16;
   13795             :       }
   13796             : 
   13797             :       /* "View.MemoryView":857
   13798             :  *                 stop = -1
   13799             :  *             else:
   13800             :  *                 stop = shape             # <<<<<<<<<<<<<<
   13801             :  * 
   13802             :  * 
   13803             :  */
   13804             :       /*else*/ {
   13805             :         __pyx_v_stop = __pyx_v_shape;
   13806             :       }
   13807           0 :       __pyx_L16:;
   13808             :     }
   13809           0 :     __pyx_L13:;
   13810             : 
   13811             :     /* "View.MemoryView":861
   13812             :  * 
   13813             :  *         with cython.cdivision(True):
   13814             :  *             new_shape = (stop - start) // step             # <<<<<<<<<<<<<<
   13815             :  * 
   13816             :  *             if (stop - start) - step * new_shape:
   13817             :  */
   13818           0 :     __pyx_v_new_shape = ((__pyx_v_stop - __pyx_v_start) / __pyx_v_step);
   13819             : 
   13820             :     /* "View.MemoryView":863
   13821             :  *             new_shape = (stop - start) // step
   13822             :  * 
   13823             :  *             if (stop - start) - step * new_shape:             # <<<<<<<<<<<<<<
   13824             :  *                 new_shape += 1
   13825             :  * 
   13826             :  */
   13827           0 :     __pyx_t_2 = (((__pyx_v_stop - __pyx_v_start) - (__pyx_v_step * __pyx_v_new_shape)) != 0);
   13828           0 :     if (__pyx_t_2) {
   13829             : 
   13830             :       /* "View.MemoryView":864
   13831             :  * 
   13832             :  *             if (stop - start) - step * new_shape:
   13833             :  *                 new_shape += 1             # <<<<<<<<<<<<<<
   13834             :  * 
   13835             :  *         if new_shape < 0:
   13836             :  */
   13837           0 :       __pyx_v_new_shape = (__pyx_v_new_shape + 1);
   13838             : 
   13839             :       /* "View.MemoryView":863
   13840             :  *             new_shape = (stop - start) // step
   13841             :  * 
   13842             :  *             if (stop - start) - step * new_shape:             # <<<<<<<<<<<<<<
   13843             :  *                 new_shape += 1
   13844             :  * 
   13845             :  */
   13846             :     }
   13847             : 
   13848             :     /* "View.MemoryView":866
   13849             :  *                 new_shape += 1
   13850             :  * 
   13851             :  *         if new_shape < 0:             # <<<<<<<<<<<<<<
   13852             :  *             new_shape = 0
   13853             :  * 
   13854             :  */
   13855           0 :     __pyx_t_2 = (__pyx_v_new_shape < 0);
   13856           0 :     if (__pyx_t_2) {
   13857             : 
   13858             :       /* "View.MemoryView":867
   13859             :  * 
   13860             :  *         if new_shape < 0:
   13861             :  *             new_shape = 0             # <<<<<<<<<<<<<<
   13862             :  * 
   13863             :  * 
   13864             :  */
   13865             :       __pyx_v_new_shape = 0;
   13866             : 
   13867             :       /* "View.MemoryView":866
   13868             :  *                 new_shape += 1
   13869             :  * 
   13870             :  *         if new_shape < 0:             # <<<<<<<<<<<<<<
   13871             :  *             new_shape = 0
   13872             :  * 
   13873             :  */
   13874             :     }
   13875             : 
   13876             :     /* "View.MemoryView":870
   13877             :  * 
   13878             :  * 
   13879             :  *         dst.strides[new_ndim] = stride * step             # <<<<<<<<<<<<<<
   13880             :  *         dst.shape[new_ndim] = new_shape
   13881             :  *         dst.suboffsets[new_ndim] = suboffset
   13882             :  */
   13883           0 :     (__pyx_v_dst->strides[__pyx_v_new_ndim]) = (__pyx_v_stride * __pyx_v_step);
   13884             : 
   13885             :     /* "View.MemoryView":871
   13886             :  * 
   13887             :  *         dst.strides[new_ndim] = stride * step
   13888             :  *         dst.shape[new_ndim] = new_shape             # <<<<<<<<<<<<<<
   13889             :  *         dst.suboffsets[new_ndim] = suboffset
   13890             :  * 
   13891             :  */
   13892           0 :     (__pyx_v_dst->shape[__pyx_v_new_ndim]) = __pyx_v_new_shape;
   13893             : 
   13894             :     /* "View.MemoryView":872
   13895             :  *         dst.strides[new_ndim] = stride * step
   13896             :  *         dst.shape[new_ndim] = new_shape
   13897             :  *         dst.suboffsets[new_ndim] = suboffset             # <<<<<<<<<<<<<<
   13898             :  * 
   13899             :  * 
   13900             :  */
   13901           0 :     (__pyx_v_dst->suboffsets[__pyx_v_new_ndim]) = __pyx_v_suboffset;
   13902             :   }
   13903           0 :   __pyx_L3:;
   13904             : 
   13905             :   /* "View.MemoryView":875
   13906             :  * 
   13907             :  * 
   13908             :  *     if suboffset_dim[0] < 0:             # <<<<<<<<<<<<<<
   13909             :  *         dst.data += start * stride
   13910             :  *     else:
   13911             :  */
   13912           0 :   __pyx_t_2 = ((__pyx_v_suboffset_dim[0]) < 0);
   13913           0 :   if (__pyx_t_2) {
   13914             : 
   13915             :     /* "View.MemoryView":876
   13916             :  * 
   13917             :  *     if suboffset_dim[0] < 0:
   13918             :  *         dst.data += start * stride             # <<<<<<<<<<<<<<
   13919             :  *     else:
   13920             :  *         dst.suboffsets[suboffset_dim[0]] += start * stride
   13921             :  */
   13922           0 :     __pyx_v_dst->data = (__pyx_v_dst->data + (__pyx_v_start * __pyx_v_stride));
   13923             : 
   13924             :     /* "View.MemoryView":875
   13925             :  * 
   13926             :  * 
   13927             :  *     if suboffset_dim[0] < 0:             # <<<<<<<<<<<<<<
   13928             :  *         dst.data += start * stride
   13929             :  *     else:
   13930             :  */
   13931           0 :     goto __pyx_L19;
   13932             :   }
   13933             : 
   13934             :   /* "View.MemoryView":878
   13935             :  *         dst.data += start * stride
   13936             :  *     else:
   13937             :  *         dst.suboffsets[suboffset_dim[0]] += start * stride             # <<<<<<<<<<<<<<
   13938             :  * 
   13939             :  *     if suboffset >= 0:
   13940             :  */
   13941             :   /*else*/ {
   13942           0 :     __pyx_t_3 = (__pyx_v_suboffset_dim[0]);
   13943           0 :     (__pyx_v_dst->suboffsets[__pyx_t_3]) = ((__pyx_v_dst->suboffsets[__pyx_t_3]) + (__pyx_v_start * __pyx_v_stride));
   13944             :   }
   13945           0 :   __pyx_L19:;
   13946             : 
   13947             :   /* "View.MemoryView":880
   13948             :  *         dst.suboffsets[suboffset_dim[0]] += start * stride
   13949             :  * 
   13950             :  *     if suboffset >= 0:             # <<<<<<<<<<<<<<
   13951             :  *         if not is_slice:
   13952             :  *             if new_ndim == 0:
   13953             :  */
   13954           0 :   __pyx_t_2 = (__pyx_v_suboffset >= 0);
   13955           0 :   if (__pyx_t_2) {
   13956             : 
   13957             :     /* "View.MemoryView":881
   13958             :  * 
   13959             :  *     if suboffset >= 0:
   13960             :  *         if not is_slice:             # <<<<<<<<<<<<<<
   13961             :  *             if new_ndim == 0:
   13962             :  *                 dst.data = (<char **> dst.data)[0] + suboffset
   13963             :  */
   13964           0 :     __pyx_t_2 = (!__pyx_v_is_slice);
   13965           0 :     if (__pyx_t_2) {
   13966             : 
   13967             :       /* "View.MemoryView":882
   13968             :  *     if suboffset >= 0:
   13969             :  *         if not is_slice:
   13970             :  *             if new_ndim == 0:             # <<<<<<<<<<<<<<
   13971             :  *                 dst.data = (<char **> dst.data)[0] + suboffset
   13972             :  *             else:
   13973             :  */
   13974           0 :       __pyx_t_2 = (__pyx_v_new_ndim == 0);
   13975           0 :       if (__pyx_t_2) {
   13976             : 
   13977             :         /* "View.MemoryView":883
   13978             :  *         if not is_slice:
   13979             :  *             if new_ndim == 0:
   13980             :  *                 dst.data = (<char **> dst.data)[0] + suboffset             # <<<<<<<<<<<<<<
   13981             :  *             else:
   13982             :  *                 _err_dim(PyExc_IndexError, "All dimensions preceding dimension %d "
   13983             :  */
   13984           0 :         __pyx_v_dst->data = ((((char **)__pyx_v_dst->data)[0]) + __pyx_v_suboffset);
   13985             : 
   13986             :         /* "View.MemoryView":882
   13987             :  *     if suboffset >= 0:
   13988             :  *         if not is_slice:
   13989             :  *             if new_ndim == 0:             # <<<<<<<<<<<<<<
   13990             :  *                 dst.data = (<char **> dst.data)[0] + suboffset
   13991             :  *             else:
   13992             :  */
   13993           0 :         goto __pyx_L22;
   13994             :       }
   13995             : 
   13996             :       /* "View.MemoryView":885
   13997             :  *                 dst.data = (<char **> dst.data)[0] + suboffset
   13998             :  *             else:
   13999             :  *                 _err_dim(PyExc_IndexError, "All dimensions preceding dimension %d "             # <<<<<<<<<<<<<<
   14000             :  *                                      "must be indexed and not sliced", dim)
   14001             :  *         else:
   14002             :  */
   14003             :       /*else*/ {
   14004             : 
   14005             :         /* "View.MemoryView":886
   14006             :  *             else:
   14007             :  *                 _err_dim(PyExc_IndexError, "All dimensions preceding dimension %d "
   14008             :  *                                      "must be indexed and not sliced", dim)             # <<<<<<<<<<<<<<
   14009             :  *         else:
   14010             :  *             suboffset_dim[0] = new_ndim
   14011             :  */
   14012           0 :         __pyx_t_3 = __pyx_memoryview_err_dim(PyExc_IndexError, __pyx_kp_s_All_dimensions_preceding_dimensi, __pyx_v_dim); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 885, __pyx_L1_error)
   14013             :       }
   14014           0 :       __pyx_L22:;
   14015             : 
   14016             :       /* "View.MemoryView":881
   14017             :  * 
   14018             :  *     if suboffset >= 0:
   14019             :  *         if not is_slice:             # <<<<<<<<<<<<<<
   14020             :  *             if new_ndim == 0:
   14021             :  *                 dst.data = (<char **> dst.data)[0] + suboffset
   14022             :  */
   14023           0 :       goto __pyx_L21;
   14024             :     }
   14025             : 
   14026             :     /* "View.MemoryView":888
   14027             :  *                                      "must be indexed and not sliced", dim)
   14028             :  *         else:
   14029             :  *             suboffset_dim[0] = new_ndim             # <<<<<<<<<<<<<<
   14030             :  * 
   14031             :  *     return 0
   14032             :  */
   14033             :     /*else*/ {
   14034           0 :       (__pyx_v_suboffset_dim[0]) = __pyx_v_new_ndim;
   14035             :     }
   14036           0 :     __pyx_L21:;
   14037             : 
   14038             :     /* "View.MemoryView":880
   14039             :  *         dst.suboffsets[suboffset_dim[0]] += start * stride
   14040             :  * 
   14041             :  *     if suboffset >= 0:             # <<<<<<<<<<<<<<
   14042             :  *         if not is_slice:
   14043             :  *             if new_ndim == 0:
   14044             :  */
   14045             :   }
   14046             : 
   14047             :   /* "View.MemoryView":890
   14048             :  *             suboffset_dim[0] = new_ndim
   14049             :  * 
   14050             :  *     return 0             # <<<<<<<<<<<<<<
   14051             :  * 
   14052             :  * 
   14053             :  */
   14054           0 :   __pyx_r = 0;
   14055           0 :   goto __pyx_L0;
   14056             : 
   14057             :   /* "View.MemoryView":793
   14058             :  * 
   14059             :  * @cname('__pyx_memoryview_slice_memviewslice')
   14060             :  * cdef int slice_memviewslice(             # <<<<<<<<<<<<<<
   14061             :  *         __Pyx_memviewslice *dst,
   14062             :  *         Py_ssize_t shape, Py_ssize_t stride, Py_ssize_t suboffset,
   14063             :  */
   14064             : 
   14065             :   /* function exit code */
   14066           0 :   __pyx_L1_error:;
   14067             :   #ifdef WITH_THREAD
   14068           0 :   __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   14069             :   #endif
   14070           0 :   __Pyx_AddTraceback("View.MemoryView.slice_memviewslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14071           0 :   __pyx_r = -1;
   14072             :   #ifdef WITH_THREAD
   14073           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   14074             :   #endif
   14075           0 :   __pyx_L0:;
   14076           0 :   return __pyx_r;
   14077             : }
   14078             : 
   14079             : /* "View.MemoryView":896
   14080             :  * 
   14081             :  * @cname('__pyx_pybuffer_index')
   14082             :  * cdef char *pybuffer_index(Py_buffer *view, char *bufp, Py_ssize_t index,             # <<<<<<<<<<<<<<
   14083             :  *                           Py_ssize_t dim) except NULL:
   14084             :  *     cdef Py_ssize_t shape, stride, suboffset = -1
   14085             :  */
   14086             : 
   14087           0 : static char *__pyx_pybuffer_index(Py_buffer *__pyx_v_view, char *__pyx_v_bufp, Py_ssize_t __pyx_v_index, Py_ssize_t __pyx_v_dim) {
   14088           0 :   Py_ssize_t __pyx_v_shape;
   14089           0 :   Py_ssize_t __pyx_v_stride;
   14090           0 :   Py_ssize_t __pyx_v_suboffset;
   14091           0 :   Py_ssize_t __pyx_v_itemsize;
   14092           0 :   char *__pyx_v_resultp;
   14093           0 :   char *__pyx_r;
   14094             :   __Pyx_RefNannyDeclarations
   14095           0 :   Py_ssize_t __pyx_t_1;
   14096           0 :   int __pyx_t_2;
   14097           0 :   PyObject *__pyx_t_3 = NULL;
   14098           0 :   Py_UCS4 __pyx_t_4;
   14099           0 :   PyObject *__pyx_t_5 = NULL;
   14100           0 :   int __pyx_lineno = 0;
   14101           0 :   const char *__pyx_filename = NULL;
   14102           0 :   int __pyx_clineno = 0;
   14103           0 :   __Pyx_RefNannySetupContext("pybuffer_index", 1);
   14104             : 
   14105             :   /* "View.MemoryView":898
   14106             :  * cdef char *pybuffer_index(Py_buffer *view, char *bufp, Py_ssize_t index,
   14107             :  *                           Py_ssize_t dim) except NULL:
   14108             :  *     cdef Py_ssize_t shape, stride, suboffset = -1             # <<<<<<<<<<<<<<
   14109             :  *     cdef Py_ssize_t itemsize = view.itemsize
   14110             :  *     cdef char *resultp
   14111             :  */
   14112           0 :   __pyx_v_suboffset = -1L;
   14113             : 
   14114             :   /* "View.MemoryView":899
   14115             :  *                           Py_ssize_t dim) except NULL:
   14116             :  *     cdef Py_ssize_t shape, stride, suboffset = -1
   14117             :  *     cdef Py_ssize_t itemsize = view.itemsize             # <<<<<<<<<<<<<<
   14118             :  *     cdef char *resultp
   14119             :  * 
   14120             :  */
   14121           0 :   __pyx_t_1 = __pyx_v_view->itemsize;
   14122           0 :   __pyx_v_itemsize = __pyx_t_1;
   14123             : 
   14124             :   /* "View.MemoryView":902
   14125             :  *     cdef char *resultp
   14126             :  * 
   14127             :  *     if view.ndim == 0:             # <<<<<<<<<<<<<<
   14128             :  *         shape = view.len // itemsize
   14129             :  *         stride = itemsize
   14130             :  */
   14131           0 :   __pyx_t_2 = (__pyx_v_view->ndim == 0);
   14132           0 :   if (__pyx_t_2) {
   14133             : 
   14134             :     /* "View.MemoryView":903
   14135             :  * 
   14136             :  *     if view.ndim == 0:
   14137             :  *         shape = view.len // itemsize             # <<<<<<<<<<<<<<
   14138             :  *         stride = itemsize
   14139             :  *     else:
   14140             :  */
   14141           0 :     if (unlikely(__pyx_v_itemsize == 0)) {
   14142           0 :       PyErr_SetString(PyExc_ZeroDivisionError, "integer division or modulo by zero");
   14143           0 :       __PYX_ERR(1, 903, __pyx_L1_error)
   14144             :     }
   14145           0 :     else if (sizeof(Py_ssize_t) == sizeof(long) && (!(((Py_ssize_t)-1) > 0)) && unlikely(__pyx_v_itemsize == (Py_ssize_t)-1)  && unlikely(__Pyx_UNARY_NEG_WOULD_OVERFLOW(__pyx_v_view->len))) {
   14146           0 :       PyErr_SetString(PyExc_OverflowError, "value too large to perform division");
   14147           0 :       __PYX_ERR(1, 903, __pyx_L1_error)
   14148             :     }
   14149           0 :     __pyx_v_shape = __Pyx_div_Py_ssize_t(__pyx_v_view->len, __pyx_v_itemsize);
   14150             : 
   14151             :     /* "View.MemoryView":904
   14152             :  *     if view.ndim == 0:
   14153             :  *         shape = view.len // itemsize
   14154             :  *         stride = itemsize             # <<<<<<<<<<<<<<
   14155             :  *     else:
   14156             :  *         shape = view.shape[dim]
   14157             :  */
   14158           0 :     __pyx_v_stride = __pyx_v_itemsize;
   14159             : 
   14160             :     /* "View.MemoryView":902
   14161             :  *     cdef char *resultp
   14162             :  * 
   14163             :  *     if view.ndim == 0:             # <<<<<<<<<<<<<<
   14164             :  *         shape = view.len // itemsize
   14165             :  *         stride = itemsize
   14166             :  */
   14167           0 :     goto __pyx_L3;
   14168             :   }
   14169             : 
   14170             :   /* "View.MemoryView":906
   14171             :  *         stride = itemsize
   14172             :  *     else:
   14173             :  *         shape = view.shape[dim]             # <<<<<<<<<<<<<<
   14174             :  *         stride = view.strides[dim]
   14175             :  *         if view.suboffsets != NULL:
   14176             :  */
   14177             :   /*else*/ {
   14178           0 :     __pyx_v_shape = (__pyx_v_view->shape[__pyx_v_dim]);
   14179             : 
   14180             :     /* "View.MemoryView":907
   14181             :  *     else:
   14182             :  *         shape = view.shape[dim]
   14183             :  *         stride = view.strides[dim]             # <<<<<<<<<<<<<<
   14184             :  *         if view.suboffsets != NULL:
   14185             :  *             suboffset = view.suboffsets[dim]
   14186             :  */
   14187           0 :     __pyx_v_stride = (__pyx_v_view->strides[__pyx_v_dim]);
   14188             : 
   14189             :     /* "View.MemoryView":908
   14190             :  *         shape = view.shape[dim]
   14191             :  *         stride = view.strides[dim]
   14192             :  *         if view.suboffsets != NULL:             # <<<<<<<<<<<<<<
   14193             :  *             suboffset = view.suboffsets[dim]
   14194             :  * 
   14195             :  */
   14196           0 :     __pyx_t_2 = (__pyx_v_view->suboffsets != NULL);
   14197           0 :     if (__pyx_t_2) {
   14198             : 
   14199             :       /* "View.MemoryView":909
   14200             :  *         stride = view.strides[dim]
   14201             :  *         if view.suboffsets != NULL:
   14202             :  *             suboffset = view.suboffsets[dim]             # <<<<<<<<<<<<<<
   14203             :  * 
   14204             :  *     if index < 0:
   14205             :  */
   14206           0 :       __pyx_v_suboffset = (__pyx_v_view->suboffsets[__pyx_v_dim]);
   14207             : 
   14208             :       /* "View.MemoryView":908
   14209             :  *         shape = view.shape[dim]
   14210             :  *         stride = view.strides[dim]
   14211             :  *         if view.suboffsets != NULL:             # <<<<<<<<<<<<<<
   14212             :  *             suboffset = view.suboffsets[dim]
   14213             :  * 
   14214             :  */
   14215             :     }
   14216             :   }
   14217           0 :   __pyx_L3:;
   14218             : 
   14219             :   /* "View.MemoryView":911
   14220             :  *             suboffset = view.suboffsets[dim]
   14221             :  * 
   14222             :  *     if index < 0:             # <<<<<<<<<<<<<<
   14223             :  *         index += view.shape[dim]
   14224             :  *         if index < 0:
   14225             :  */
   14226           0 :   __pyx_t_2 = (__pyx_v_index < 0);
   14227           0 :   if (__pyx_t_2) {
   14228             : 
   14229             :     /* "View.MemoryView":912
   14230             :  * 
   14231             :  *     if index < 0:
   14232             :  *         index += view.shape[dim]             # <<<<<<<<<<<<<<
   14233             :  *         if index < 0:
   14234             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14235             :  */
   14236           0 :     __pyx_v_index = (__pyx_v_index + (__pyx_v_view->shape[__pyx_v_dim]));
   14237             : 
   14238             :     /* "View.MemoryView":913
   14239             :  *     if index < 0:
   14240             :  *         index += view.shape[dim]
   14241             :  *         if index < 0:             # <<<<<<<<<<<<<<
   14242             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14243             :  * 
   14244             :  */
   14245           0 :     __pyx_t_2 = (__pyx_v_index < 0);
   14246           0 :     if (unlikely(__pyx_t_2)) {
   14247             : 
   14248             :       /* "View.MemoryView":914
   14249             :  *         index += view.shape[dim]
   14250             :  *         if index < 0:
   14251             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"             # <<<<<<<<<<<<<<
   14252             :  * 
   14253             :  *     if index >= shape:
   14254             :  */
   14255           0 :       __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 914, __pyx_L1_error)
   14256           0 :       __Pyx_GOTREF(__pyx_t_3);
   14257           0 :       __pyx_t_1 = 0;
   14258           0 :       __pyx_t_4 = 127;
   14259           0 :       __Pyx_INCREF(__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14260           0 :       __pyx_t_1 += 37;
   14261           0 :       __Pyx_GIVEREF(__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14262           0 :       PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14263           0 :       __pyx_t_5 = __Pyx_PyUnicode_From_Py_ssize_t(__pyx_v_dim, 0, ' ', 'd'); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 914, __pyx_L1_error)
   14264           0 :       __Pyx_GOTREF(__pyx_t_5);
   14265           0 :       __pyx_t_1 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_5);
   14266           0 :       __Pyx_GIVEREF(__pyx_t_5);
   14267           0 :       PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_5);
   14268           0 :       __pyx_t_5 = 0;
   14269           0 :       __Pyx_INCREF(__pyx_kp_u__7);
   14270           0 :       __pyx_t_1 += 1;
   14271           0 :       __Pyx_GIVEREF(__pyx_kp_u__7);
   14272           0 :       PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_kp_u__7);
   14273           0 :       __pyx_t_5 = __Pyx_PyUnicode_Join(__pyx_t_3, 3, __pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 914, __pyx_L1_error)
   14274           0 :       __Pyx_GOTREF(__pyx_t_5);
   14275           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   14276           0 :       __Pyx_Raise(__pyx_builtin_IndexError, __pyx_t_5, 0, 0);
   14277           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   14278           0 :       __PYX_ERR(1, 914, __pyx_L1_error)
   14279             : 
   14280             :       /* "View.MemoryView":913
   14281             :  *     if index < 0:
   14282             :  *         index += view.shape[dim]
   14283             :  *         if index < 0:             # <<<<<<<<<<<<<<
   14284             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14285             :  * 
   14286             :  */
   14287             :     }
   14288             : 
   14289             :     /* "View.MemoryView":911
   14290             :  *             suboffset = view.suboffsets[dim]
   14291             :  * 
   14292             :  *     if index < 0:             # <<<<<<<<<<<<<<
   14293             :  *         index += view.shape[dim]
   14294             :  *         if index < 0:
   14295             :  */
   14296             :   }
   14297             : 
   14298             :   /* "View.MemoryView":916
   14299             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14300             :  * 
   14301             :  *     if index >= shape:             # <<<<<<<<<<<<<<
   14302             :  *         raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14303             :  * 
   14304             :  */
   14305           0 :   __pyx_t_2 = (__pyx_v_index >= __pyx_v_shape);
   14306           0 :   if (unlikely(__pyx_t_2)) {
   14307             : 
   14308             :     /* "View.MemoryView":917
   14309             :  * 
   14310             :  *     if index >= shape:
   14311             :  *         raise IndexError, f"Out of bounds on buffer access (axis {dim})"             # <<<<<<<<<<<<<<
   14312             :  * 
   14313             :  *     resultp = bufp + index * stride
   14314             :  */
   14315           0 :     __pyx_t_5 = PyTuple_New(3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 917, __pyx_L1_error)
   14316           0 :     __Pyx_GOTREF(__pyx_t_5);
   14317           0 :     __pyx_t_1 = 0;
   14318           0 :     __pyx_t_4 = 127;
   14319           0 :     __Pyx_INCREF(__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14320           0 :     __pyx_t_1 += 37;
   14321           0 :     __Pyx_GIVEREF(__pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14322           0 :     PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_kp_u_Out_of_bounds_on_buffer_access_a);
   14323           0 :     __pyx_t_3 = __Pyx_PyUnicode_From_Py_ssize_t(__pyx_v_dim, 0, ' ', 'd'); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 917, __pyx_L1_error)
   14324           0 :     __Pyx_GOTREF(__pyx_t_3);
   14325           0 :     __pyx_t_1 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_3);
   14326           0 :     __Pyx_GIVEREF(__pyx_t_3);
   14327           0 :     PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_3);
   14328           0 :     __pyx_t_3 = 0;
   14329           0 :     __Pyx_INCREF(__pyx_kp_u__7);
   14330           0 :     __pyx_t_1 += 1;
   14331           0 :     __Pyx_GIVEREF(__pyx_kp_u__7);
   14332           0 :     PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_kp_u__7);
   14333           0 :     __pyx_t_3 = __Pyx_PyUnicode_Join(__pyx_t_5, 3, __pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 917, __pyx_L1_error)
   14334           0 :     __Pyx_GOTREF(__pyx_t_3);
   14335           0 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   14336           0 :     __Pyx_Raise(__pyx_builtin_IndexError, __pyx_t_3, 0, 0);
   14337           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   14338           0 :     __PYX_ERR(1, 917, __pyx_L1_error)
   14339             : 
   14340             :     /* "View.MemoryView":916
   14341             :  *             raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14342             :  * 
   14343             :  *     if index >= shape:             # <<<<<<<<<<<<<<
   14344             :  *         raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14345             :  * 
   14346             :  */
   14347             :   }
   14348             : 
   14349             :   /* "View.MemoryView":919
   14350             :  *         raise IndexError, f"Out of bounds on buffer access (axis {dim})"
   14351             :  * 
   14352             :  *     resultp = bufp + index * stride             # <<<<<<<<<<<<<<
   14353             :  *     if suboffset >= 0:
   14354             :  *         resultp = (<char **> resultp)[0] + suboffset
   14355             :  */
   14356           0 :   __pyx_v_resultp = (__pyx_v_bufp + (__pyx_v_index * __pyx_v_stride));
   14357             : 
   14358             :   /* "View.MemoryView":920
   14359             :  * 
   14360             :  *     resultp = bufp + index * stride
   14361             :  *     if suboffset >= 0:             # <<<<<<<<<<<<<<
   14362             :  *         resultp = (<char **> resultp)[0] + suboffset
   14363             :  * 
   14364             :  */
   14365           0 :   __pyx_t_2 = (__pyx_v_suboffset >= 0);
   14366           0 :   if (__pyx_t_2) {
   14367             : 
   14368             :     /* "View.MemoryView":921
   14369             :  *     resultp = bufp + index * stride
   14370             :  *     if suboffset >= 0:
   14371             :  *         resultp = (<char **> resultp)[0] + suboffset             # <<<<<<<<<<<<<<
   14372             :  * 
   14373             :  *     return resultp
   14374             :  */
   14375           0 :     __pyx_v_resultp = ((((char **)__pyx_v_resultp)[0]) + __pyx_v_suboffset);
   14376             : 
   14377             :     /* "View.MemoryView":920
   14378             :  * 
   14379             :  *     resultp = bufp + index * stride
   14380             :  *     if suboffset >= 0:             # <<<<<<<<<<<<<<
   14381             :  *         resultp = (<char **> resultp)[0] + suboffset
   14382             :  * 
   14383             :  */
   14384             :   }
   14385             : 
   14386             :   /* "View.MemoryView":923
   14387             :  *         resultp = (<char **> resultp)[0] + suboffset
   14388             :  * 
   14389             :  *     return resultp             # <<<<<<<<<<<<<<
   14390             :  * 
   14391             :  * 
   14392             :  */
   14393           0 :   __pyx_r = __pyx_v_resultp;
   14394           0 :   goto __pyx_L0;
   14395             : 
   14396             :   /* "View.MemoryView":896
   14397             :  * 
   14398             :  * @cname('__pyx_pybuffer_index')
   14399             :  * cdef char *pybuffer_index(Py_buffer *view, char *bufp, Py_ssize_t index,             # <<<<<<<<<<<<<<
   14400             :  *                           Py_ssize_t dim) except NULL:
   14401             :  *     cdef Py_ssize_t shape, stride, suboffset = -1
   14402             :  */
   14403             : 
   14404             :   /* function exit code */
   14405           0 :   __pyx_L1_error:;
   14406           0 :   __Pyx_XDECREF(__pyx_t_3);
   14407           0 :   __Pyx_XDECREF(__pyx_t_5);
   14408           0 :   __Pyx_AddTraceback("View.MemoryView.pybuffer_index", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14409           0 :   __pyx_r = NULL;
   14410           0 :   __pyx_L0:;
   14411           0 :   __Pyx_RefNannyFinishContext();
   14412           0 :   return __pyx_r;
   14413             : }
   14414             : 
   14415             : /* "View.MemoryView":929
   14416             :  * 
   14417             :  * @cname('__pyx_memslice_transpose')
   14418             :  * cdef int transpose_memslice(__Pyx_memviewslice *memslice) except -1 nogil:             # <<<<<<<<<<<<<<
   14419             :  *     cdef int ndim = memslice.memview.view.ndim
   14420             :  * 
   14421             :  */
   14422             : 
   14423           0 : static int __pyx_memslice_transpose(__Pyx_memviewslice *__pyx_v_memslice) {
   14424           0 :   int __pyx_v_ndim;
   14425           0 :   Py_ssize_t *__pyx_v_shape;
   14426           0 :   Py_ssize_t *__pyx_v_strides;
   14427           0 :   int __pyx_v_i;
   14428           0 :   int __pyx_v_j;
   14429           0 :   int __pyx_r;
   14430           0 :   int __pyx_t_1;
   14431           0 :   Py_ssize_t *__pyx_t_2;
   14432           0 :   long __pyx_t_3;
   14433           0 :   long __pyx_t_4;
   14434           0 :   Py_ssize_t __pyx_t_5;
   14435           0 :   Py_ssize_t __pyx_t_6;
   14436           0 :   int __pyx_t_7;
   14437           0 :   int __pyx_t_8;
   14438           0 :   int __pyx_t_9;
   14439           0 :   int __pyx_lineno = 0;
   14440           0 :   const char *__pyx_filename = NULL;
   14441           0 :   int __pyx_clineno = 0;
   14442             :   #ifdef WITH_THREAD
   14443           0 :   PyGILState_STATE __pyx_gilstate_save;
   14444             :   #endif
   14445             : 
   14446             :   /* "View.MemoryView":930
   14447             :  * @cname('__pyx_memslice_transpose')
   14448             :  * cdef int transpose_memslice(__Pyx_memviewslice *memslice) except -1 nogil:
   14449             :  *     cdef int ndim = memslice.memview.view.ndim             # <<<<<<<<<<<<<<
   14450             :  * 
   14451             :  *     cdef Py_ssize_t *shape = memslice.shape
   14452             :  */
   14453           0 :   __pyx_t_1 = __pyx_v_memslice->memview->view.ndim;
   14454           0 :   __pyx_v_ndim = __pyx_t_1;
   14455             : 
   14456             :   /* "View.MemoryView":932
   14457             :  *     cdef int ndim = memslice.memview.view.ndim
   14458             :  * 
   14459             :  *     cdef Py_ssize_t *shape = memslice.shape             # <<<<<<<<<<<<<<
   14460             :  *     cdef Py_ssize_t *strides = memslice.strides
   14461             :  * 
   14462             :  */
   14463           0 :   __pyx_t_2 = __pyx_v_memslice->shape;
   14464           0 :   __pyx_v_shape = __pyx_t_2;
   14465             : 
   14466             :   /* "View.MemoryView":933
   14467             :  * 
   14468             :  *     cdef Py_ssize_t *shape = memslice.shape
   14469             :  *     cdef Py_ssize_t *strides = memslice.strides             # <<<<<<<<<<<<<<
   14470             :  * 
   14471             :  * 
   14472             :  */
   14473           0 :   __pyx_t_2 = __pyx_v_memslice->strides;
   14474           0 :   __pyx_v_strides = __pyx_t_2;
   14475             : 
   14476             :   /* "View.MemoryView":937
   14477             :  * 
   14478             :  *     cdef int i, j
   14479             :  *     for i in range(ndim // 2):             # <<<<<<<<<<<<<<
   14480             :  *         j = ndim - 1 - i
   14481             :  *         strides[i], strides[j] = strides[j], strides[i]
   14482             :  */
   14483           0 :   __pyx_t_3 = __Pyx_div_long(__pyx_v_ndim, 2);
   14484           0 :   __pyx_t_4 = __pyx_t_3;
   14485           0 :   for (__pyx_t_1 = 0; __pyx_t_1 < __pyx_t_4; __pyx_t_1+=1) {
   14486           0 :     __pyx_v_i = __pyx_t_1;
   14487             : 
   14488             :     /* "View.MemoryView":938
   14489             :  *     cdef int i, j
   14490             :  *     for i in range(ndim // 2):
   14491             :  *         j = ndim - 1 - i             # <<<<<<<<<<<<<<
   14492             :  *         strides[i], strides[j] = strides[j], strides[i]
   14493             :  *         shape[i], shape[j] = shape[j], shape[i]
   14494             :  */
   14495           0 :     __pyx_v_j = ((__pyx_v_ndim - 1) - __pyx_v_i);
   14496             : 
   14497             :     /* "View.MemoryView":939
   14498             :  *     for i in range(ndim // 2):
   14499             :  *         j = ndim - 1 - i
   14500             :  *         strides[i], strides[j] = strides[j], strides[i]             # <<<<<<<<<<<<<<
   14501             :  *         shape[i], shape[j] = shape[j], shape[i]
   14502             :  * 
   14503             :  */
   14504           0 :     __pyx_t_5 = (__pyx_v_strides[__pyx_v_j]);
   14505           0 :     __pyx_t_6 = (__pyx_v_strides[__pyx_v_i]);
   14506           0 :     (__pyx_v_strides[__pyx_v_i]) = __pyx_t_5;
   14507           0 :     (__pyx_v_strides[__pyx_v_j]) = __pyx_t_6;
   14508             : 
   14509             :     /* "View.MemoryView":940
   14510             :  *         j = ndim - 1 - i
   14511             :  *         strides[i], strides[j] = strides[j], strides[i]
   14512             :  *         shape[i], shape[j] = shape[j], shape[i]             # <<<<<<<<<<<<<<
   14513             :  * 
   14514             :  *         if memslice.suboffsets[i] >= 0 or memslice.suboffsets[j] >= 0:
   14515             :  */
   14516           0 :     __pyx_t_6 = (__pyx_v_shape[__pyx_v_j]);
   14517           0 :     __pyx_t_5 = (__pyx_v_shape[__pyx_v_i]);
   14518           0 :     (__pyx_v_shape[__pyx_v_i]) = __pyx_t_6;
   14519           0 :     (__pyx_v_shape[__pyx_v_j]) = __pyx_t_5;
   14520             : 
   14521             :     /* "View.MemoryView":942
   14522             :  *         shape[i], shape[j] = shape[j], shape[i]
   14523             :  * 
   14524             :  *         if memslice.suboffsets[i] >= 0 or memslice.suboffsets[j] >= 0:             # <<<<<<<<<<<<<<
   14525             :  *             _err(PyExc_ValueError, "Cannot transpose memoryview with indirect dimensions")
   14526             :  * 
   14527             :  */
   14528           0 :     __pyx_t_8 = ((__pyx_v_memslice->suboffsets[__pyx_v_i]) >= 0);
   14529           0 :     if (!__pyx_t_8) {
   14530           0 :     } else {
   14531           0 :       __pyx_t_7 = __pyx_t_8;
   14532           0 :       goto __pyx_L6_bool_binop_done;
   14533             :     }
   14534           0 :     __pyx_t_8 = ((__pyx_v_memslice->suboffsets[__pyx_v_j]) >= 0);
   14535           0 :     __pyx_t_7 = __pyx_t_8;
   14536           0 :     __pyx_L6_bool_binop_done:;
   14537           0 :     if (__pyx_t_7) {
   14538             : 
   14539             :       /* "View.MemoryView":943
   14540             :  * 
   14541             :  *         if memslice.suboffsets[i] >= 0 or memslice.suboffsets[j] >= 0:
   14542             :  *             _err(PyExc_ValueError, "Cannot transpose memoryview with indirect dimensions")             # <<<<<<<<<<<<<<
   14543             :  * 
   14544             :  *     return 0
   14545             :  */
   14546           0 :       __pyx_t_9 = __pyx_memoryview_err(PyExc_ValueError, __pyx_kp_s_Cannot_transpose_memoryview_with); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(1, 943, __pyx_L1_error)
   14547             : 
   14548             :       /* "View.MemoryView":942
   14549             :  *         shape[i], shape[j] = shape[j], shape[i]
   14550             :  * 
   14551             :  *         if memslice.suboffsets[i] >= 0 or memslice.suboffsets[j] >= 0:             # <<<<<<<<<<<<<<
   14552             :  *             _err(PyExc_ValueError, "Cannot transpose memoryview with indirect dimensions")
   14553             :  * 
   14554             :  */
   14555             :     }
   14556             :   }
   14557             : 
   14558             :   /* "View.MemoryView":945
   14559             :  *             _err(PyExc_ValueError, "Cannot transpose memoryview with indirect dimensions")
   14560             :  * 
   14561             :  *     return 0             # <<<<<<<<<<<<<<
   14562             :  * 
   14563             :  * 
   14564             :  */
   14565           0 :   __pyx_r = 0;
   14566           0 :   goto __pyx_L0;
   14567             : 
   14568             :   /* "View.MemoryView":929
   14569             :  * 
   14570             :  * @cname('__pyx_memslice_transpose')
   14571             :  * cdef int transpose_memslice(__Pyx_memviewslice *memslice) except -1 nogil:             # <<<<<<<<<<<<<<
   14572             :  *     cdef int ndim = memslice.memview.view.ndim
   14573             :  * 
   14574             :  */
   14575             : 
   14576             :   /* function exit code */
   14577           0 :   __pyx_L1_error:;
   14578             :   #ifdef WITH_THREAD
   14579           0 :   __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   14580             :   #endif
   14581           0 :   __Pyx_AddTraceback("View.MemoryView.transpose_memslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14582           0 :   __pyx_r = -1;
   14583             :   #ifdef WITH_THREAD
   14584           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   14585             :   #endif
   14586           0 :   __pyx_L0:;
   14587           0 :   return __pyx_r;
   14588             : }
   14589             : 
   14590             : /* "View.MemoryView":963
   14591             :  *     cdef int (*to_dtype_func)(char *, object) except 0
   14592             :  * 
   14593             :  *     def __dealloc__(self):             # <<<<<<<<<<<<<<
   14594             :  *         __PYX_XCLEAR_MEMVIEW(&self.from_slice, 1)
   14595             :  * 
   14596             :  */
   14597             : 
   14598             : /* Python wrapper */
   14599             : static void __pyx_memoryviewslice___dealloc__(PyObject *__pyx_v_self); /*proto*/
   14600           0 : static void __pyx_memoryviewslice___dealloc__(PyObject *__pyx_v_self) {
   14601           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   14602             :   __Pyx_RefNannyDeclarations
   14603           0 :   __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
   14604           0 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   14605           0 :   __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(((struct __pyx_memoryviewslice_obj *)__pyx_v_self));
   14606             : 
   14607             :   /* function exit code */
   14608           0 :   __Pyx_RefNannyFinishContext();
   14609             : }
   14610             : 
   14611           0 : static void __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(struct __pyx_memoryviewslice_obj *__pyx_v_self) {
   14612             : 
   14613             :   /* "View.MemoryView":964
   14614             :  * 
   14615             :  *     def __dealloc__(self):
   14616             :  *         __PYX_XCLEAR_MEMVIEW(&self.from_slice, 1)             # <<<<<<<<<<<<<<
   14617             :  * 
   14618             :  *     cdef convert_item_to_object(self, char *itemp):
   14619             :  */
   14620           0 :   __PYX_XCLEAR_MEMVIEW((&__pyx_v_self->from_slice), 1);
   14621             : 
   14622             :   /* "View.MemoryView":963
   14623             :  *     cdef int (*to_dtype_func)(char *, object) except 0
   14624             :  * 
   14625             :  *     def __dealloc__(self):             # <<<<<<<<<<<<<<
   14626             :  *         __PYX_XCLEAR_MEMVIEW(&self.from_slice, 1)
   14627             :  * 
   14628             :  */
   14629             : 
   14630             :   /* function exit code */
   14631             : }
   14632             : 
   14633             : /* "View.MemoryView":966
   14634             :  *         __PYX_XCLEAR_MEMVIEW(&self.from_slice, 1)
   14635             :  * 
   14636             :  *     cdef convert_item_to_object(self, char *itemp):             # <<<<<<<<<<<<<<
   14637             :  *         if self.to_object_func != NULL:
   14638             :  *             return self.to_object_func(itemp)
   14639             :  */
   14640             : 
   14641           0 : static PyObject *__pyx_memoryviewslice_convert_item_to_object(struct __pyx_memoryviewslice_obj *__pyx_v_self, char *__pyx_v_itemp) {
   14642           0 :   PyObject *__pyx_r = NULL;
   14643             :   __Pyx_RefNannyDeclarations
   14644           0 :   int __pyx_t_1;
   14645           0 :   PyObject *__pyx_t_2 = NULL;
   14646           0 :   int __pyx_lineno = 0;
   14647           0 :   const char *__pyx_filename = NULL;
   14648           0 :   int __pyx_clineno = 0;
   14649           0 :   __Pyx_RefNannySetupContext("convert_item_to_object", 1);
   14650             : 
   14651             :   /* "View.MemoryView":967
   14652             :  * 
   14653             :  *     cdef convert_item_to_object(self, char *itemp):
   14654             :  *         if self.to_object_func != NULL:             # <<<<<<<<<<<<<<
   14655             :  *             return self.to_object_func(itemp)
   14656             :  *         else:
   14657             :  */
   14658           0 :   __pyx_t_1 = (__pyx_v_self->to_object_func != NULL);
   14659           0 :   if (__pyx_t_1) {
   14660             : 
   14661             :     /* "View.MemoryView":968
   14662             :  *     cdef convert_item_to_object(self, char *itemp):
   14663             :  *         if self.to_object_func != NULL:
   14664             :  *             return self.to_object_func(itemp)             # <<<<<<<<<<<<<<
   14665             :  *         else:
   14666             :  *             return memoryview.convert_item_to_object(self, itemp)
   14667             :  */
   14668           0 :     __Pyx_XDECREF(__pyx_r);
   14669           0 :     __pyx_t_2 = __pyx_v_self->to_object_func(__pyx_v_itemp); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 968, __pyx_L1_error)
   14670           0 :     __Pyx_GOTREF(__pyx_t_2);
   14671           0 :     __pyx_r = __pyx_t_2;
   14672           0 :     __pyx_t_2 = 0;
   14673           0 :     goto __pyx_L0;
   14674             : 
   14675             :     /* "View.MemoryView":967
   14676             :  * 
   14677             :  *     cdef convert_item_to_object(self, char *itemp):
   14678             :  *         if self.to_object_func != NULL:             # <<<<<<<<<<<<<<
   14679             :  *             return self.to_object_func(itemp)
   14680             :  *         else:
   14681             :  */
   14682             :   }
   14683             : 
   14684             :   /* "View.MemoryView":970
   14685             :  *             return self.to_object_func(itemp)
   14686             :  *         else:
   14687             :  *             return memoryview.convert_item_to_object(self, itemp)             # <<<<<<<<<<<<<<
   14688             :  * 
   14689             :  *     cdef assign_item_from_object(self, char *itemp, object value):
   14690             :  */
   14691             :   /*else*/ {
   14692           0 :     __Pyx_XDECREF(__pyx_r);
   14693           0 :     __pyx_t_2 = __pyx_memoryview_convert_item_to_object(((struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_itemp); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 970, __pyx_L1_error)
   14694           0 :     __Pyx_GOTREF(__pyx_t_2);
   14695           0 :     __pyx_r = __pyx_t_2;
   14696           0 :     __pyx_t_2 = 0;
   14697           0 :     goto __pyx_L0;
   14698             :   }
   14699             : 
   14700             :   /* "View.MemoryView":966
   14701             :  *         __PYX_XCLEAR_MEMVIEW(&self.from_slice, 1)
   14702             :  * 
   14703             :  *     cdef convert_item_to_object(self, char *itemp):             # <<<<<<<<<<<<<<
   14704             :  *         if self.to_object_func != NULL:
   14705             :  *             return self.to_object_func(itemp)
   14706             :  */
   14707             : 
   14708             :   /* function exit code */
   14709           0 :   __pyx_L1_error:;
   14710           0 :   __Pyx_XDECREF(__pyx_t_2);
   14711           0 :   __Pyx_AddTraceback("View.MemoryView._memoryviewslice.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14712           0 :   __pyx_r = 0;
   14713           0 :   __pyx_L0:;
   14714           0 :   __Pyx_XGIVEREF(__pyx_r);
   14715           0 :   __Pyx_RefNannyFinishContext();
   14716           0 :   return __pyx_r;
   14717             : }
   14718             : 
   14719             : /* "View.MemoryView":972
   14720             :  *             return memoryview.convert_item_to_object(self, itemp)
   14721             :  * 
   14722             :  *     cdef assign_item_from_object(self, char *itemp, object value):             # <<<<<<<<<<<<<<
   14723             :  *         if self.to_dtype_func != NULL:
   14724             :  *             self.to_dtype_func(itemp, value)
   14725             :  */
   14726             : 
   14727           0 : static PyObject *__pyx_memoryviewslice_assign_item_from_object(struct __pyx_memoryviewslice_obj *__pyx_v_self, char *__pyx_v_itemp, PyObject *__pyx_v_value) {
   14728           0 :   PyObject *__pyx_r = NULL;
   14729             :   __Pyx_RefNannyDeclarations
   14730           0 :   int __pyx_t_1;
   14731           0 :   int __pyx_t_2;
   14732           0 :   PyObject *__pyx_t_3 = NULL;
   14733           0 :   int __pyx_lineno = 0;
   14734           0 :   const char *__pyx_filename = NULL;
   14735           0 :   int __pyx_clineno = 0;
   14736           0 :   __Pyx_RefNannySetupContext("assign_item_from_object", 1);
   14737             : 
   14738             :   /* "View.MemoryView":973
   14739             :  * 
   14740             :  *     cdef assign_item_from_object(self, char *itemp, object value):
   14741             :  *         if self.to_dtype_func != NULL:             # <<<<<<<<<<<<<<
   14742             :  *             self.to_dtype_func(itemp, value)
   14743             :  *         else:
   14744             :  */
   14745           0 :   __pyx_t_1 = (__pyx_v_self->to_dtype_func != NULL);
   14746           0 :   if (__pyx_t_1) {
   14747             : 
   14748             :     /* "View.MemoryView":974
   14749             :  *     cdef assign_item_from_object(self, char *itemp, object value):
   14750             :  *         if self.to_dtype_func != NULL:
   14751             :  *             self.to_dtype_func(itemp, value)             # <<<<<<<<<<<<<<
   14752             :  *         else:
   14753             :  *             memoryview.assign_item_from_object(self, itemp, value)
   14754             :  */
   14755           0 :     __pyx_t_2 = __pyx_v_self->to_dtype_func(__pyx_v_itemp, __pyx_v_value); if (unlikely(__pyx_t_2 == ((int)0))) __PYX_ERR(1, 974, __pyx_L1_error)
   14756             : 
   14757             :     /* "View.MemoryView":973
   14758             :  * 
   14759             :  *     cdef assign_item_from_object(self, char *itemp, object value):
   14760             :  *         if self.to_dtype_func != NULL:             # <<<<<<<<<<<<<<
   14761             :  *             self.to_dtype_func(itemp, value)
   14762             :  *         else:
   14763             :  */
   14764           0 :     goto __pyx_L3;
   14765             :   }
   14766             : 
   14767             :   /* "View.MemoryView":976
   14768             :  *             self.to_dtype_func(itemp, value)
   14769             :  *         else:
   14770             :  *             memoryview.assign_item_from_object(self, itemp, value)             # <<<<<<<<<<<<<<
   14771             :  * 
   14772             :  *     cdef _get_base(self):
   14773             :  */
   14774             :   /*else*/ {
   14775           0 :     __pyx_t_3 = __pyx_memoryview_assign_item_from_object(((struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_itemp, __pyx_v_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 976, __pyx_L1_error)
   14776           0 :     __Pyx_GOTREF(__pyx_t_3);
   14777           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   14778             :   }
   14779           0 :   __pyx_L3:;
   14780             : 
   14781             :   /* "View.MemoryView":972
   14782             :  *             return memoryview.convert_item_to_object(self, itemp)
   14783             :  * 
   14784             :  *     cdef assign_item_from_object(self, char *itemp, object value):             # <<<<<<<<<<<<<<
   14785             :  *         if self.to_dtype_func != NULL:
   14786             :  *             self.to_dtype_func(itemp, value)
   14787             :  */
   14788             : 
   14789             :   /* function exit code */
   14790           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
   14791           0 :   goto __pyx_L0;
   14792           0 :   __pyx_L1_error:;
   14793           0 :   __Pyx_XDECREF(__pyx_t_3);
   14794           0 :   __Pyx_AddTraceback("View.MemoryView._memoryviewslice.assign_item_from_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14795           0 :   __pyx_r = 0;
   14796           0 :   __pyx_L0:;
   14797           0 :   __Pyx_XGIVEREF(__pyx_r);
   14798           0 :   __Pyx_RefNannyFinishContext();
   14799           0 :   return __pyx_r;
   14800             : }
   14801             : 
   14802             : /* "View.MemoryView":978
   14803             :  *             memoryview.assign_item_from_object(self, itemp, value)
   14804             :  * 
   14805             :  *     cdef _get_base(self):             # <<<<<<<<<<<<<<
   14806             :  *         return self.from_object
   14807             :  * 
   14808             :  */
   14809             : 
   14810           0 : static PyObject *__pyx_memoryviewslice__get_base(struct __pyx_memoryviewslice_obj *__pyx_v_self) {
   14811           0 :   PyObject *__pyx_r = NULL;
   14812             :   __Pyx_RefNannyDeclarations
   14813           0 :   __Pyx_RefNannySetupContext("_get_base", 1);
   14814             : 
   14815             :   /* "View.MemoryView":979
   14816             :  * 
   14817             :  *     cdef _get_base(self):
   14818             :  *         return self.from_object             # <<<<<<<<<<<<<<
   14819             :  * 
   14820             :  * 
   14821             :  */
   14822           0 :   __Pyx_XDECREF(__pyx_r);
   14823           0 :   __Pyx_INCREF(__pyx_v_self->from_object);
   14824           0 :   __pyx_r = __pyx_v_self->from_object;
   14825           0 :   goto __pyx_L0;
   14826             : 
   14827             :   /* "View.MemoryView":978
   14828             :  *             memoryview.assign_item_from_object(self, itemp, value)
   14829             :  * 
   14830             :  *     cdef _get_base(self):             # <<<<<<<<<<<<<<
   14831             :  *         return self.from_object
   14832             :  * 
   14833             :  */
   14834             : 
   14835             :   /* function exit code */
   14836           0 :   __pyx_L0:;
   14837           0 :   __Pyx_XGIVEREF(__pyx_r);
   14838           0 :   __Pyx_RefNannyFinishContext();
   14839           0 :   return __pyx_r;
   14840             : }
   14841             : 
   14842             : /* "(tree fragment)":1
   14843             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
   14844             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   14845             :  * def __setstate_cython__(self, __pyx_state):
   14846             :  */
   14847             : 
   14848             : /* Python wrapper */
   14849             : static PyObject *__pyx_pw___pyx_memoryviewslice_1__reduce_cython__(PyObject *__pyx_v_self, 
   14850             : #if CYTHON_METH_FASTCALL
   14851             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   14852             : #else
   14853             : PyObject *__pyx_args, PyObject *__pyx_kwds
   14854             : #endif
   14855             : ); /*proto*/
   14856           0 : static PyObject *__pyx_pw___pyx_memoryviewslice_1__reduce_cython__(PyObject *__pyx_v_self, 
   14857             : #if CYTHON_METH_FASTCALL
   14858             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   14859             : #else
   14860             : PyObject *__pyx_args, PyObject *__pyx_kwds
   14861             : #endif
   14862             : ) {
   14863             :   #if !CYTHON_METH_FASTCALL
   14864             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   14865             :   #endif
   14866           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   14867           0 :   PyObject *__pyx_r = 0;
   14868             :   __Pyx_RefNannyDeclarations
   14869           0 :   __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
   14870             :   #if !CYTHON_METH_FASTCALL
   14871             :   #if CYTHON_ASSUME_SAFE_MACROS
   14872             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   14873             :   #else
   14874             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   14875             :   #endif
   14876             :   #endif
   14877           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   14878           0 :   if (unlikely(__pyx_nargs > 0)) {
   14879           0 :     __Pyx_RaiseArgtupleInvalid("__reduce_cython__", 1, 0, 0, __pyx_nargs); return NULL;}
   14880           0 :   if (unlikely(__pyx_kwds) && __Pyx_NumKwargs_FASTCALL(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__reduce_cython__", 0))) return NULL;
   14881           0 :   __pyx_r = __pyx_pf___pyx_memoryviewslice___reduce_cython__(((struct __pyx_memoryviewslice_obj *)__pyx_v_self));
   14882             : 
   14883             :   /* function exit code */
   14884           0 :   __Pyx_RefNannyFinishContext();
   14885           0 :   return __pyx_r;
   14886             : }
   14887             : 
   14888           0 : static PyObject *__pyx_pf___pyx_memoryviewslice___reduce_cython__(CYTHON_UNUSED struct __pyx_memoryviewslice_obj *__pyx_v_self) {
   14889           0 :   PyObject *__pyx_r = NULL;
   14890             :   __Pyx_RefNannyDeclarations
   14891           0 :   int __pyx_lineno = 0;
   14892           0 :   const char *__pyx_filename = NULL;
   14893           0 :   int __pyx_clineno = 0;
   14894           0 :   __Pyx_RefNannySetupContext("__reduce_cython__", 1);
   14895             : 
   14896             :   /* "(tree fragment)":2
   14897             :  * def __reduce_cython__(self):
   14898             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
   14899             :  * def __setstate_cython__(self, __pyx_state):
   14900             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   14901             :  */
   14902           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
   14903           0 :   __PYX_ERR(1, 2, __pyx_L1_error)
   14904             : 
   14905             :   /* "(tree fragment)":1
   14906             :  * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
   14907             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   14908             :  * def __setstate_cython__(self, __pyx_state):
   14909             :  */
   14910             : 
   14911             :   /* function exit code */
   14912           0 :   __pyx_L1_error:;
   14913           0 :   __Pyx_AddTraceback("View.MemoryView._memoryviewslice.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   14914           0 :   __pyx_r = NULL;
   14915           0 :   __Pyx_XGIVEREF(__pyx_r);
   14916           0 :   __Pyx_RefNannyFinishContext();
   14917           0 :   return __pyx_r;
   14918             : }
   14919             : 
   14920             : /* "(tree fragment)":3
   14921             :  * def __reduce_cython__(self):
   14922             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   14923             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
   14924             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   14925             :  */
   14926             : 
   14927             : /* Python wrapper */
   14928             : static PyObject *__pyx_pw___pyx_memoryviewslice_3__setstate_cython__(PyObject *__pyx_v_self, 
   14929             : #if CYTHON_METH_FASTCALL
   14930             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   14931             : #else
   14932             : PyObject *__pyx_args, PyObject *__pyx_kwds
   14933             : #endif
   14934             : ); /*proto*/
   14935           0 : static PyObject *__pyx_pw___pyx_memoryviewslice_3__setstate_cython__(PyObject *__pyx_v_self, 
   14936             : #if CYTHON_METH_FASTCALL
   14937             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   14938             : #else
   14939             : PyObject *__pyx_args, PyObject *__pyx_kwds
   14940             : #endif
   14941             : ) {
   14942           0 :   CYTHON_UNUSED PyObject *__pyx_v___pyx_state = 0;
   14943             :   #if !CYTHON_METH_FASTCALL
   14944             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   14945             :   #endif
   14946           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   14947           0 :   PyObject* values[1] = {0};
   14948           0 :   int __pyx_lineno = 0;
   14949           0 :   const char *__pyx_filename = NULL;
   14950           0 :   int __pyx_clineno = 0;
   14951           0 :   PyObject *__pyx_r = 0;
   14952             :   __Pyx_RefNannyDeclarations
   14953           0 :   __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
   14954             :   #if !CYTHON_METH_FASTCALL
   14955             :   #if CYTHON_ASSUME_SAFE_MACROS
   14956             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   14957             :   #else
   14958             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   14959             :   #endif
   14960             :   #endif
   14961           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   14962             :   {
   14963           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_state,0};
   14964           0 :     if (__pyx_kwds) {
   14965           0 :       Py_ssize_t kw_args;
   14966           0 :       switch (__pyx_nargs) {
   14967           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   14968           0 :         CYTHON_FALLTHROUGH;
   14969           0 :         case  0: break;
   14970           0 :         default: goto __pyx_L5_argtuple_error;
   14971             :       }
   14972           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
   14973           0 :       switch (__pyx_nargs) {
   14974             :         case  0:
   14975           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_state)) != 0)) {
   14976           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
   14977           0 :           kw_args--;
   14978             :         }
   14979           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 3, __pyx_L3_error)
   14980           0 :         else goto __pyx_L5_argtuple_error;
   14981             :       }
   14982           0 :       if (unlikely(kw_args > 0)) {
   14983           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   14984           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__setstate_cython__") < 0)) __PYX_ERR(1, 3, __pyx_L3_error)
   14985             :       }
   14986           0 :     } else if (unlikely(__pyx_nargs != 1)) {
   14987           0 :       goto __pyx_L5_argtuple_error;
   14988             :     } else {
   14989           0 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   14990             :     }
   14991           0 :     __pyx_v___pyx_state = values[0];
   14992             :   }
   14993           0 :   goto __pyx_L6_skip;
   14994           0 :   __pyx_L5_argtuple_error:;
   14995           0 :   __Pyx_RaiseArgtupleInvalid("__setstate_cython__", 1, 1, 1, __pyx_nargs); __PYX_ERR(1, 3, __pyx_L3_error)
   14996           0 :   __pyx_L6_skip:;
   14997           0 :   goto __pyx_L4_argument_unpacking_done;
   14998           0 :   __pyx_L3_error:;
   14999             :   {
   15000           0 :     Py_ssize_t __pyx_temp;
   15001           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   15002             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   15003             :     }
   15004             :   }
   15005           0 :   __Pyx_AddTraceback("View.MemoryView._memoryviewslice.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15006           0 :   __Pyx_RefNannyFinishContext();
   15007           0 :   return NULL;
   15008           0 :   __pyx_L4_argument_unpacking_done:;
   15009           0 :   __pyx_r = __pyx_pf___pyx_memoryviewslice_2__setstate_cython__(((struct __pyx_memoryviewslice_obj *)__pyx_v_self), __pyx_v___pyx_state);
   15010             : 
   15011             :   /* function exit code */
   15012             :   {
   15013           0 :     Py_ssize_t __pyx_temp;
   15014           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   15015             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   15016             :     }
   15017             :   }
   15018             :   __Pyx_RefNannyFinishContext();
   15019             :   return __pyx_r;
   15020             : }
   15021             : 
   15022           0 : static PyObject *__pyx_pf___pyx_memoryviewslice_2__setstate_cython__(CYTHON_UNUSED struct __pyx_memoryviewslice_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
   15023           0 :   PyObject *__pyx_r = NULL;
   15024             :   __Pyx_RefNannyDeclarations
   15025           0 :   int __pyx_lineno = 0;
   15026           0 :   const char *__pyx_filename = NULL;
   15027           0 :   int __pyx_clineno = 0;
   15028           0 :   __Pyx_RefNannySetupContext("__setstate_cython__", 1);
   15029             : 
   15030             :   /* "(tree fragment)":4
   15031             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   15032             :  * def __setstate_cython__(self, __pyx_state):
   15033             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"             # <<<<<<<<<<<<<<
   15034             :  */
   15035           0 :   __Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_s_no_default___reduce___due_to_non, 0, 0);
   15036           0 :   __PYX_ERR(1, 4, __pyx_L1_error)
   15037             : 
   15038             :   /* "(tree fragment)":3
   15039             :  * def __reduce_cython__(self):
   15040             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   15041             :  * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
   15042             :  *     raise TypeError, "no default __reduce__ due to non-trivial __cinit__"
   15043             :  */
   15044             : 
   15045             :   /* function exit code */
   15046           0 :   __pyx_L1_error:;
   15047           0 :   __Pyx_AddTraceback("View.MemoryView._memoryviewslice.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15048           0 :   __pyx_r = NULL;
   15049           0 :   __Pyx_XGIVEREF(__pyx_r);
   15050           0 :   __Pyx_RefNannyFinishContext();
   15051           0 :   return __pyx_r;
   15052             : }
   15053             : 
   15054             : /* "View.MemoryView":999
   15055             :  * 
   15056             :  * @cname('__pyx_memoryview_fromslice')
   15057             :  * cdef memoryview_fromslice(__Pyx_memviewslice memviewslice,             # <<<<<<<<<<<<<<
   15058             :  *                           int ndim,
   15059             :  *                           object (*to_object_func)(char *),
   15060             :  */
   15061             : 
   15062           0 : static PyObject *__pyx_memoryview_fromslice(__Pyx_memviewslice __pyx_v_memviewslice, int __pyx_v_ndim, PyObject *(*__pyx_v_to_object_func)(char *), int (*__pyx_v_to_dtype_func)(char *, PyObject *), int __pyx_v_dtype_is_object) {
   15063           0 :   struct __pyx_memoryviewslice_obj *__pyx_v_result = 0;
   15064           0 :   Py_ssize_t __pyx_v_suboffset;
   15065           0 :   PyObject *__pyx_v_length = NULL;
   15066           0 :   PyObject *__pyx_r = NULL;
   15067             :   __Pyx_RefNannyDeclarations
   15068           0 :   int __pyx_t_1;
   15069           0 :   PyObject *__pyx_t_2 = NULL;
   15070           0 :   PyObject *__pyx_t_3 = NULL;
   15071           0 :   __Pyx_TypeInfo *__pyx_t_4;
   15072           0 :   Py_buffer __pyx_t_5;
   15073           0 :   Py_ssize_t *__pyx_t_6;
   15074           0 :   Py_ssize_t *__pyx_t_7;
   15075           0 :   Py_ssize_t *__pyx_t_8;
   15076           0 :   Py_ssize_t __pyx_t_9;
   15077           0 :   int __pyx_lineno = 0;
   15078           0 :   const char *__pyx_filename = NULL;
   15079           0 :   int __pyx_clineno = 0;
   15080           0 :   __Pyx_RefNannySetupContext("memoryview_fromslice", 1);
   15081             : 
   15082             :   /* "View.MemoryView":1007
   15083             :  *     cdef _memoryviewslice result
   15084             :  * 
   15085             :  *     if <PyObject *> memviewslice.memview == Py_None:             # <<<<<<<<<<<<<<
   15086             :  *         return None
   15087             :  * 
   15088             :  */
   15089           0 :   __pyx_t_1 = (((PyObject *)__pyx_v_memviewslice.memview) == Py_None);
   15090           0 :   if (__pyx_t_1) {
   15091             : 
   15092             :     /* "View.MemoryView":1008
   15093             :  * 
   15094             :  *     if <PyObject *> memviewslice.memview == Py_None:
   15095             :  *         return None             # <<<<<<<<<<<<<<
   15096             :  * 
   15097             :  * 
   15098             :  */
   15099           0 :     __Pyx_XDECREF(__pyx_r);
   15100           0 :     __pyx_r = Py_None; __Pyx_INCREF(Py_None);
   15101           0 :     goto __pyx_L0;
   15102             : 
   15103             :     /* "View.MemoryView":1007
   15104             :  *     cdef _memoryviewslice result
   15105             :  * 
   15106             :  *     if <PyObject *> memviewslice.memview == Py_None:             # <<<<<<<<<<<<<<
   15107             :  *         return None
   15108             :  * 
   15109             :  */
   15110             :   }
   15111             : 
   15112             :   /* "View.MemoryView":1013
   15113             :  * 
   15114             :  * 
   15115             :  *     result = _memoryviewslice.__new__(_memoryviewslice, None, 0, dtype_is_object)             # <<<<<<<<<<<<<<
   15116             :  * 
   15117             :  *     result.from_slice = memviewslice
   15118             :  */
   15119           0 :   __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_dtype_is_object); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1013, __pyx_L1_error)
   15120           0 :   __Pyx_GOTREF(__pyx_t_2);
   15121           0 :   __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1013, __pyx_L1_error)
   15122           0 :   __Pyx_GOTREF(__pyx_t_3);
   15123           0 :   __Pyx_INCREF(Py_None);
   15124           0 :   __Pyx_GIVEREF(Py_None);
   15125           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, Py_None)) __PYX_ERR(1, 1013, __pyx_L1_error);
   15126           0 :   __Pyx_INCREF(__pyx_int_0);
   15127           0 :   __Pyx_GIVEREF(__pyx_int_0);
   15128           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_0)) __PYX_ERR(1, 1013, __pyx_L1_error);
   15129           0 :   __Pyx_GIVEREF(__pyx_t_2);
   15130           0 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2)) __PYX_ERR(1, 1013, __pyx_L1_error);
   15131           0 :   __pyx_t_2 = 0;
   15132           0 :   __pyx_t_2 = ((PyObject *)__pyx_tp_new__memoryviewslice(((PyTypeObject *)__pyx_memoryviewslice_type), __pyx_t_3, NULL)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1013, __pyx_L1_error)
   15133           0 :   __Pyx_GOTREF((PyObject *)__pyx_t_2);
   15134           0 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   15135           0 :   __pyx_v_result = ((struct __pyx_memoryviewslice_obj *)__pyx_t_2);
   15136           0 :   __pyx_t_2 = 0;
   15137             : 
   15138             :   /* "View.MemoryView":1015
   15139             :  *     result = _memoryviewslice.__new__(_memoryviewslice, None, 0, dtype_is_object)
   15140             :  * 
   15141             :  *     result.from_slice = memviewslice             # <<<<<<<<<<<<<<
   15142             :  *     __PYX_INC_MEMVIEW(&memviewslice, 1)
   15143             :  * 
   15144             :  */
   15145           0 :   __pyx_v_result->from_slice = __pyx_v_memviewslice;
   15146             : 
   15147             :   /* "View.MemoryView":1016
   15148             :  * 
   15149             :  *     result.from_slice = memviewslice
   15150             :  *     __PYX_INC_MEMVIEW(&memviewslice, 1)             # <<<<<<<<<<<<<<
   15151             :  * 
   15152             :  *     result.from_object = (<memoryview> memviewslice.memview)._get_base()
   15153             :  */
   15154           0 :   __PYX_INC_MEMVIEW((&__pyx_v_memviewslice), 1);
   15155             : 
   15156             :   /* "View.MemoryView":1018
   15157             :  *     __PYX_INC_MEMVIEW(&memviewslice, 1)
   15158             :  * 
   15159             :  *     result.from_object = (<memoryview> memviewslice.memview)._get_base()             # <<<<<<<<<<<<<<
   15160             :  *     result.typeinfo = memviewslice.memview.typeinfo
   15161             :  * 
   15162             :  */
   15163           0 :   __pyx_t_2 = ((struct __pyx_vtabstruct_memoryview *)((struct __pyx_memoryview_obj *)__pyx_v_memviewslice.memview)->__pyx_vtab)->_get_base(((struct __pyx_memoryview_obj *)__pyx_v_memviewslice.memview)); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1018, __pyx_L1_error)
   15164           0 :   __Pyx_GOTREF(__pyx_t_2);
   15165           0 :   __Pyx_GIVEREF(__pyx_t_2);
   15166           0 :   __Pyx_GOTREF(__pyx_v_result->from_object);
   15167           0 :   __Pyx_DECREF(__pyx_v_result->from_object);
   15168           0 :   __pyx_v_result->from_object = __pyx_t_2;
   15169           0 :   __pyx_t_2 = 0;
   15170             : 
   15171             :   /* "View.MemoryView":1019
   15172             :  * 
   15173             :  *     result.from_object = (<memoryview> memviewslice.memview)._get_base()
   15174             :  *     result.typeinfo = memviewslice.memview.typeinfo             # <<<<<<<<<<<<<<
   15175             :  * 
   15176             :  *     result.view = memviewslice.memview.view
   15177             :  */
   15178           0 :   __pyx_t_4 = __pyx_v_memviewslice.memview->typeinfo;
   15179           0 :   __pyx_v_result->__pyx_base.typeinfo = __pyx_t_4;
   15180             : 
   15181             :   /* "View.MemoryView":1021
   15182             :  *     result.typeinfo = memviewslice.memview.typeinfo
   15183             :  * 
   15184             :  *     result.view = memviewslice.memview.view             # <<<<<<<<<<<<<<
   15185             :  *     result.view.buf = <void *> memviewslice.data
   15186             :  *     result.view.ndim = ndim
   15187             :  */
   15188           0 :   __pyx_t_5 = __pyx_v_memviewslice.memview->view;
   15189           0 :   __pyx_v_result->__pyx_base.view = __pyx_t_5;
   15190             : 
   15191             :   /* "View.MemoryView":1022
   15192             :  * 
   15193             :  *     result.view = memviewslice.memview.view
   15194             :  *     result.view.buf = <void *> memviewslice.data             # <<<<<<<<<<<<<<
   15195             :  *     result.view.ndim = ndim
   15196             :  *     (<__pyx_buffer *> &result.view).obj = Py_None
   15197             :  */
   15198           0 :   __pyx_v_result->__pyx_base.view.buf = ((void *)__pyx_v_memviewslice.data);
   15199             : 
   15200             :   /* "View.MemoryView":1023
   15201             :  *     result.view = memviewslice.memview.view
   15202             :  *     result.view.buf = <void *> memviewslice.data
   15203             :  *     result.view.ndim = ndim             # <<<<<<<<<<<<<<
   15204             :  *     (<__pyx_buffer *> &result.view).obj = Py_None
   15205             :  *     Py_INCREF(Py_None)
   15206             :  */
   15207           0 :   __pyx_v_result->__pyx_base.view.ndim = __pyx_v_ndim;
   15208             : 
   15209             :   /* "View.MemoryView":1024
   15210             :  *     result.view.buf = <void *> memviewslice.data
   15211             :  *     result.view.ndim = ndim
   15212             :  *     (<__pyx_buffer *> &result.view).obj = Py_None             # <<<<<<<<<<<<<<
   15213             :  *     Py_INCREF(Py_None)
   15214             :  * 
   15215             :  */
   15216           0 :   ((Py_buffer *)(&__pyx_v_result->__pyx_base.view))->obj = Py_None;
   15217             : 
   15218             :   /* "View.MemoryView":1025
   15219             :  *     result.view.ndim = ndim
   15220             :  *     (<__pyx_buffer *> &result.view).obj = Py_None
   15221             :  *     Py_INCREF(Py_None)             # <<<<<<<<<<<<<<
   15222             :  * 
   15223             :  *     if (<memoryview>memviewslice.memview).flags & PyBUF_WRITABLE:
   15224             :  */
   15225           0 :   Py_INCREF(Py_None);
   15226             : 
   15227             :   /* "View.MemoryView":1027
   15228             :  *     Py_INCREF(Py_None)
   15229             :  * 
   15230             :  *     if (<memoryview>memviewslice.memview).flags & PyBUF_WRITABLE:             # <<<<<<<<<<<<<<
   15231             :  *         result.flags = PyBUF_RECORDS
   15232             :  *     else:
   15233             :  */
   15234           0 :   __pyx_t_1 = ((((struct __pyx_memoryview_obj *)__pyx_v_memviewslice.memview)->flags & PyBUF_WRITABLE) != 0);
   15235           0 :   if (__pyx_t_1) {
   15236             : 
   15237             :     /* "View.MemoryView":1028
   15238             :  * 
   15239             :  *     if (<memoryview>memviewslice.memview).flags & PyBUF_WRITABLE:
   15240             :  *         result.flags = PyBUF_RECORDS             # <<<<<<<<<<<<<<
   15241             :  *     else:
   15242             :  *         result.flags = PyBUF_RECORDS_RO
   15243             :  */
   15244           0 :     __pyx_v_result->__pyx_base.flags = PyBUF_RECORDS;
   15245             : 
   15246             :     /* "View.MemoryView":1027
   15247             :  *     Py_INCREF(Py_None)
   15248             :  * 
   15249             :  *     if (<memoryview>memviewslice.memview).flags & PyBUF_WRITABLE:             # <<<<<<<<<<<<<<
   15250             :  *         result.flags = PyBUF_RECORDS
   15251             :  *     else:
   15252             :  */
   15253           0 :     goto __pyx_L4;
   15254             :   }
   15255             : 
   15256             :   /* "View.MemoryView":1030
   15257             :  *         result.flags = PyBUF_RECORDS
   15258             :  *     else:
   15259             :  *         result.flags = PyBUF_RECORDS_RO             # <<<<<<<<<<<<<<
   15260             :  * 
   15261             :  *     result.view.shape = <Py_ssize_t *> result.from_slice.shape
   15262             :  */
   15263             :   /*else*/ {
   15264           0 :     __pyx_v_result->__pyx_base.flags = PyBUF_RECORDS_RO;
   15265             :   }
   15266           0 :   __pyx_L4:;
   15267             : 
   15268             :   /* "View.MemoryView":1032
   15269             :  *         result.flags = PyBUF_RECORDS_RO
   15270             :  * 
   15271             :  *     result.view.shape = <Py_ssize_t *> result.from_slice.shape             # <<<<<<<<<<<<<<
   15272             :  *     result.view.strides = <Py_ssize_t *> result.from_slice.strides
   15273             :  * 
   15274             :  */
   15275           0 :   __pyx_v_result->__pyx_base.view.shape = ((Py_ssize_t *)__pyx_v_result->from_slice.shape);
   15276             : 
   15277             :   /* "View.MemoryView":1033
   15278             :  * 
   15279             :  *     result.view.shape = <Py_ssize_t *> result.from_slice.shape
   15280             :  *     result.view.strides = <Py_ssize_t *> result.from_slice.strides             # <<<<<<<<<<<<<<
   15281             :  * 
   15282             :  * 
   15283             :  */
   15284           0 :   __pyx_v_result->__pyx_base.view.strides = ((Py_ssize_t *)__pyx_v_result->from_slice.strides);
   15285             : 
   15286             :   /* "View.MemoryView":1036
   15287             :  * 
   15288             :  * 
   15289             :  *     result.view.suboffsets = NULL             # <<<<<<<<<<<<<<
   15290             :  *     for suboffset in result.from_slice.suboffsets[:ndim]:
   15291             :  *         if suboffset >= 0:
   15292             :  */
   15293           0 :   __pyx_v_result->__pyx_base.view.suboffsets = NULL;
   15294             : 
   15295             :   /* "View.MemoryView":1037
   15296             :  * 
   15297             :  *     result.view.suboffsets = NULL
   15298             :  *     for suboffset in result.from_slice.suboffsets[:ndim]:             # <<<<<<<<<<<<<<
   15299             :  *         if suboffset >= 0:
   15300             :  *             result.view.suboffsets = <Py_ssize_t *> result.from_slice.suboffsets
   15301             :  */
   15302           0 :   __pyx_t_7 = (__pyx_v_result->from_slice.suboffsets + __pyx_v_ndim);
   15303           0 :   for (__pyx_t_8 = __pyx_v_result->from_slice.suboffsets; __pyx_t_8 < __pyx_t_7; __pyx_t_8++) {
   15304           0 :     __pyx_t_6 = __pyx_t_8;
   15305           0 :     __pyx_v_suboffset = (__pyx_t_6[0]);
   15306             : 
   15307             :     /* "View.MemoryView":1038
   15308             :  *     result.view.suboffsets = NULL
   15309             :  *     for suboffset in result.from_slice.suboffsets[:ndim]:
   15310             :  *         if suboffset >= 0:             # <<<<<<<<<<<<<<
   15311             :  *             result.view.suboffsets = <Py_ssize_t *> result.from_slice.suboffsets
   15312             :  *             break
   15313             :  */
   15314           0 :     __pyx_t_1 = (__pyx_v_suboffset >= 0);
   15315           0 :     if (__pyx_t_1) {
   15316             : 
   15317             :       /* "View.MemoryView":1039
   15318             :  *     for suboffset in result.from_slice.suboffsets[:ndim]:
   15319             :  *         if suboffset >= 0:
   15320             :  *             result.view.suboffsets = <Py_ssize_t *> result.from_slice.suboffsets             # <<<<<<<<<<<<<<
   15321             :  *             break
   15322             :  * 
   15323             :  */
   15324           0 :       __pyx_v_result->__pyx_base.view.suboffsets = ((Py_ssize_t *)__pyx_v_result->from_slice.suboffsets);
   15325             : 
   15326             :       /* "View.MemoryView":1040
   15327             :  *         if suboffset >= 0:
   15328             :  *             result.view.suboffsets = <Py_ssize_t *> result.from_slice.suboffsets
   15329             :  *             break             # <<<<<<<<<<<<<<
   15330             :  * 
   15331             :  *     result.view.len = result.view.itemsize
   15332             :  */
   15333           0 :       goto __pyx_L6_break;
   15334             : 
   15335             :       /* "View.MemoryView":1038
   15336             :  *     result.view.suboffsets = NULL
   15337             :  *     for suboffset in result.from_slice.suboffsets[:ndim]:
   15338             :  *         if suboffset >= 0:             # <<<<<<<<<<<<<<
   15339             :  *             result.view.suboffsets = <Py_ssize_t *> result.from_slice.suboffsets
   15340             :  *             break
   15341             :  */
   15342             :     }
   15343             :   }
   15344           0 :   __pyx_L6_break:;
   15345             : 
   15346             :   /* "View.MemoryView":1042
   15347             :  *             break
   15348             :  * 
   15349             :  *     result.view.len = result.view.itemsize             # <<<<<<<<<<<<<<
   15350             :  *     for length in result.view.shape[:ndim]:
   15351             :  *         result.view.len *= length
   15352             :  */
   15353           0 :   __pyx_t_9 = __pyx_v_result->__pyx_base.view.itemsize;
   15354           0 :   __pyx_v_result->__pyx_base.view.len = __pyx_t_9;
   15355             : 
   15356             :   /* "View.MemoryView":1043
   15357             :  * 
   15358             :  *     result.view.len = result.view.itemsize
   15359             :  *     for length in result.view.shape[:ndim]:             # <<<<<<<<<<<<<<
   15360             :  *         result.view.len *= length
   15361             :  * 
   15362             :  */
   15363           0 :   __pyx_t_7 = (__pyx_v_result->__pyx_base.view.shape + __pyx_v_ndim);
   15364           0 :   for (__pyx_t_8 = __pyx_v_result->__pyx_base.view.shape; __pyx_t_8 < __pyx_t_7; __pyx_t_8++) {
   15365           0 :     __pyx_t_6 = __pyx_t_8;
   15366           0 :     __pyx_t_2 = PyInt_FromSsize_t((__pyx_t_6[0])); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1043, __pyx_L1_error)
   15367           0 :     __Pyx_GOTREF(__pyx_t_2);
   15368           0 :     __Pyx_XDECREF_SET(__pyx_v_length, __pyx_t_2);
   15369           0 :     __pyx_t_2 = 0;
   15370             : 
   15371             :     /* "View.MemoryView":1044
   15372             :  *     result.view.len = result.view.itemsize
   15373             :  *     for length in result.view.shape[:ndim]:
   15374             :  *         result.view.len *= length             # <<<<<<<<<<<<<<
   15375             :  * 
   15376             :  *     result.to_object_func = to_object_func
   15377             :  */
   15378           0 :     __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_result->__pyx_base.view.len); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1044, __pyx_L1_error)
   15379           0 :     __Pyx_GOTREF(__pyx_t_2);
   15380           0 :     __pyx_t_3 = PyNumber_InPlaceMultiply(__pyx_t_2, __pyx_v_length); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 1044, __pyx_L1_error)
   15381           0 :     __Pyx_GOTREF(__pyx_t_3);
   15382           0 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   15383           0 :     __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_t_3); if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 1044, __pyx_L1_error)
   15384           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   15385           0 :     __pyx_v_result->__pyx_base.view.len = __pyx_t_9;
   15386             :   }
   15387             : 
   15388             :   /* "View.MemoryView":1046
   15389             :  *         result.view.len *= length
   15390             :  * 
   15391             :  *     result.to_object_func = to_object_func             # <<<<<<<<<<<<<<
   15392             :  *     result.to_dtype_func = to_dtype_func
   15393             :  * 
   15394             :  */
   15395           0 :   __pyx_v_result->to_object_func = __pyx_v_to_object_func;
   15396             : 
   15397             :   /* "View.MemoryView":1047
   15398             :  * 
   15399             :  *     result.to_object_func = to_object_func
   15400             :  *     result.to_dtype_func = to_dtype_func             # <<<<<<<<<<<<<<
   15401             :  * 
   15402             :  *     return result
   15403             :  */
   15404           0 :   __pyx_v_result->to_dtype_func = __pyx_v_to_dtype_func;
   15405             : 
   15406             :   /* "View.MemoryView":1049
   15407             :  *     result.to_dtype_func = to_dtype_func
   15408             :  * 
   15409             :  *     return result             # <<<<<<<<<<<<<<
   15410             :  * 
   15411             :  * @cname('__pyx_memoryview_get_slice_from_memoryview')
   15412             :  */
   15413           0 :   __Pyx_XDECREF(__pyx_r);
   15414           0 :   __Pyx_INCREF((PyObject *)__pyx_v_result);
   15415           0 :   __pyx_r = ((PyObject *)__pyx_v_result);
   15416           0 :   goto __pyx_L0;
   15417             : 
   15418             :   /* "View.MemoryView":999
   15419             :  * 
   15420             :  * @cname('__pyx_memoryview_fromslice')
   15421             :  * cdef memoryview_fromslice(__Pyx_memviewslice memviewslice,             # <<<<<<<<<<<<<<
   15422             :  *                           int ndim,
   15423             :  *                           object (*to_object_func)(char *),
   15424             :  */
   15425             : 
   15426             :   /* function exit code */
   15427           0 :   __pyx_L1_error:;
   15428           0 :   __Pyx_XDECREF(__pyx_t_2);
   15429           0 :   __Pyx_XDECREF(__pyx_t_3);
   15430           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview_fromslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15431           0 :   __pyx_r = 0;
   15432           0 :   __pyx_L0:;
   15433           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_result);
   15434           0 :   __Pyx_XDECREF(__pyx_v_length);
   15435           0 :   __Pyx_XGIVEREF(__pyx_r);
   15436           0 :   __Pyx_RefNannyFinishContext();
   15437           0 :   return __pyx_r;
   15438             : }
   15439             : 
   15440             : /* "View.MemoryView":1052
   15441             :  * 
   15442             :  * @cname('__pyx_memoryview_get_slice_from_memoryview')
   15443             :  * cdef __Pyx_memviewslice *get_slice_from_memview(memoryview memview,             # <<<<<<<<<<<<<<
   15444             :  *                                                    __Pyx_memviewslice *mslice) except NULL:
   15445             :  *     cdef _memoryviewslice obj
   15446             :  */
   15447             : 
   15448           0 : static __Pyx_memviewslice *__pyx_memoryview_get_slice_from_memoryview(struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_mslice) {
   15449           0 :   struct __pyx_memoryviewslice_obj *__pyx_v_obj = 0;
   15450           0 :   __Pyx_memviewslice *__pyx_r;
   15451             :   __Pyx_RefNannyDeclarations
   15452           0 :   int __pyx_t_1;
   15453           0 :   PyObject *__pyx_t_2 = NULL;
   15454           0 :   int __pyx_lineno = 0;
   15455           0 :   const char *__pyx_filename = NULL;
   15456           0 :   int __pyx_clineno = 0;
   15457           0 :   __Pyx_RefNannySetupContext("get_slice_from_memview", 1);
   15458             : 
   15459             :   /* "View.MemoryView":1055
   15460             :  *                                                    __Pyx_memviewslice *mslice) except NULL:
   15461             :  *     cdef _memoryviewslice obj
   15462             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   15463             :  *         obj = memview
   15464             :  *         return &obj.from_slice
   15465             :  */
   15466           0 :   __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type); 
   15467           0 :   if (__pyx_t_1) {
   15468             : 
   15469             :     /* "View.MemoryView":1056
   15470             :  *     cdef _memoryviewslice obj
   15471             :  *     if isinstance(memview, _memoryviewslice):
   15472             :  *         obj = memview             # <<<<<<<<<<<<<<
   15473             :  *         return &obj.from_slice
   15474             :  *     else:
   15475             :  */
   15476           0 :     if (!(likely(((((PyObject *)__pyx_v_memview)) == Py_None) || likely(__Pyx_TypeTest(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type))))) __PYX_ERR(1, 1056, __pyx_L1_error)
   15477           0 :     __pyx_t_2 = ((PyObject *)__pyx_v_memview);
   15478           0 :     __Pyx_INCREF(__pyx_t_2);
   15479           0 :     __pyx_v_obj = ((struct __pyx_memoryviewslice_obj *)__pyx_t_2);
   15480           0 :     __pyx_t_2 = 0;
   15481             : 
   15482             :     /* "View.MemoryView":1057
   15483             :  *     if isinstance(memview, _memoryviewslice):
   15484             :  *         obj = memview
   15485             :  *         return &obj.from_slice             # <<<<<<<<<<<<<<
   15486             :  *     else:
   15487             :  *         slice_copy(memview, mslice)
   15488             :  */
   15489           0 :     __pyx_r = (&__pyx_v_obj->from_slice);
   15490           0 :     goto __pyx_L0;
   15491             : 
   15492             :     /* "View.MemoryView":1055
   15493             :  *                                                    __Pyx_memviewslice *mslice) except NULL:
   15494             :  *     cdef _memoryviewslice obj
   15495             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   15496             :  *         obj = memview
   15497             :  *         return &obj.from_slice
   15498             :  */
   15499             :   }
   15500             : 
   15501             :   /* "View.MemoryView":1059
   15502             :  *         return &obj.from_slice
   15503             :  *     else:
   15504             :  *         slice_copy(memview, mslice)             # <<<<<<<<<<<<<<
   15505             :  *         return mslice
   15506             :  * 
   15507             :  */
   15508             :   /*else*/ {
   15509           0 :     __pyx_memoryview_slice_copy(__pyx_v_memview, __pyx_v_mslice);
   15510             : 
   15511             :     /* "View.MemoryView":1060
   15512             :  *     else:
   15513             :  *         slice_copy(memview, mslice)
   15514             :  *         return mslice             # <<<<<<<<<<<<<<
   15515             :  * 
   15516             :  * @cname('__pyx_memoryview_slice_copy')
   15517             :  */
   15518           0 :     __pyx_r = __pyx_v_mslice;
   15519           0 :     goto __pyx_L0;
   15520             :   }
   15521             : 
   15522             :   /* "View.MemoryView":1052
   15523             :  * 
   15524             :  * @cname('__pyx_memoryview_get_slice_from_memoryview')
   15525             :  * cdef __Pyx_memviewslice *get_slice_from_memview(memoryview memview,             # <<<<<<<<<<<<<<
   15526             :  *                                                    __Pyx_memviewslice *mslice) except NULL:
   15527             :  *     cdef _memoryviewslice obj
   15528             :  */
   15529             : 
   15530             :   /* function exit code */
   15531           0 :   __pyx_L1_error:;
   15532           0 :   __Pyx_XDECREF(__pyx_t_2);
   15533           0 :   __Pyx_AddTraceback("View.MemoryView.get_slice_from_memview", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15534           0 :   __pyx_r = NULL;
   15535           0 :   __pyx_L0:;
   15536           0 :   __Pyx_XDECREF((PyObject *)__pyx_v_obj);
   15537           0 :   __Pyx_RefNannyFinishContext();
   15538           0 :   return __pyx_r;
   15539             : }
   15540             : 
   15541             : /* "View.MemoryView":1063
   15542             :  * 
   15543             :  * @cname('__pyx_memoryview_slice_copy')
   15544             :  * cdef void slice_copy(memoryview memview, __Pyx_memviewslice *dst) noexcept:             # <<<<<<<<<<<<<<
   15545             :  *     cdef int dim
   15546             :  *     cdef (Py_ssize_t*) shape, strides, suboffsets
   15547             :  */
   15548             : 
   15549           0 : static void __pyx_memoryview_slice_copy(struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_dst) {
   15550           0 :   int __pyx_v_dim;
   15551           0 :   Py_ssize_t *__pyx_v_shape;
   15552           0 :   Py_ssize_t *__pyx_v_strides;
   15553           0 :   Py_ssize_t *__pyx_v_suboffsets;
   15554           0 :   Py_ssize_t *__pyx_t_1;
   15555           0 :   int __pyx_t_2;
   15556           0 :   int __pyx_t_3;
   15557           0 :   int __pyx_t_4;
   15558           0 :   Py_ssize_t __pyx_t_5;
   15559           0 :   int __pyx_t_6;
   15560             : 
   15561             :   /* "View.MemoryView":1067
   15562             :  *     cdef (Py_ssize_t*) shape, strides, suboffsets
   15563             :  * 
   15564             :  *     shape = memview.view.shape             # <<<<<<<<<<<<<<
   15565             :  *     strides = memview.view.strides
   15566             :  *     suboffsets = memview.view.suboffsets
   15567             :  */
   15568           0 :   __pyx_t_1 = __pyx_v_memview->view.shape;
   15569           0 :   __pyx_v_shape = __pyx_t_1;
   15570             : 
   15571             :   /* "View.MemoryView":1068
   15572             :  * 
   15573             :  *     shape = memview.view.shape
   15574             :  *     strides = memview.view.strides             # <<<<<<<<<<<<<<
   15575             :  *     suboffsets = memview.view.suboffsets
   15576             :  * 
   15577             :  */
   15578           0 :   __pyx_t_1 = __pyx_v_memview->view.strides;
   15579           0 :   __pyx_v_strides = __pyx_t_1;
   15580             : 
   15581             :   /* "View.MemoryView":1069
   15582             :  *     shape = memview.view.shape
   15583             :  *     strides = memview.view.strides
   15584             :  *     suboffsets = memview.view.suboffsets             # <<<<<<<<<<<<<<
   15585             :  * 
   15586             :  *     dst.memview = <__pyx_memoryview *> memview
   15587             :  */
   15588           0 :   __pyx_t_1 = __pyx_v_memview->view.suboffsets;
   15589           0 :   __pyx_v_suboffsets = __pyx_t_1;
   15590             : 
   15591             :   /* "View.MemoryView":1071
   15592             :  *     suboffsets = memview.view.suboffsets
   15593             :  * 
   15594             :  *     dst.memview = <__pyx_memoryview *> memview             # <<<<<<<<<<<<<<
   15595             :  *     dst.data = <char *> memview.view.buf
   15596             :  * 
   15597             :  */
   15598           0 :   __pyx_v_dst->memview = ((struct __pyx_memoryview_obj *)__pyx_v_memview);
   15599             : 
   15600             :   /* "View.MemoryView":1072
   15601             :  * 
   15602             :  *     dst.memview = <__pyx_memoryview *> memview
   15603             :  *     dst.data = <char *> memview.view.buf             # <<<<<<<<<<<<<<
   15604             :  * 
   15605             :  *     for dim in range(memview.view.ndim):
   15606             :  */
   15607           0 :   __pyx_v_dst->data = ((char *)__pyx_v_memview->view.buf);
   15608             : 
   15609             :   /* "View.MemoryView":1074
   15610             :  *     dst.data = <char *> memview.view.buf
   15611             :  * 
   15612             :  *     for dim in range(memview.view.ndim):             # <<<<<<<<<<<<<<
   15613             :  *         dst.shape[dim] = shape[dim]
   15614             :  *         dst.strides[dim] = strides[dim]
   15615             :  */
   15616           0 :   __pyx_t_2 = __pyx_v_memview->view.ndim;
   15617           0 :   __pyx_t_3 = __pyx_t_2;
   15618           0 :   for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   15619           0 :     __pyx_v_dim = __pyx_t_4;
   15620             : 
   15621             :     /* "View.MemoryView":1075
   15622             :  * 
   15623             :  *     for dim in range(memview.view.ndim):
   15624             :  *         dst.shape[dim] = shape[dim]             # <<<<<<<<<<<<<<
   15625             :  *         dst.strides[dim] = strides[dim]
   15626             :  *         dst.suboffsets[dim] = suboffsets[dim] if suboffsets else -1
   15627             :  */
   15628           0 :     (__pyx_v_dst->shape[__pyx_v_dim]) = (__pyx_v_shape[__pyx_v_dim]);
   15629             : 
   15630             :     /* "View.MemoryView":1076
   15631             :  *     for dim in range(memview.view.ndim):
   15632             :  *         dst.shape[dim] = shape[dim]
   15633             :  *         dst.strides[dim] = strides[dim]             # <<<<<<<<<<<<<<
   15634             :  *         dst.suboffsets[dim] = suboffsets[dim] if suboffsets else -1
   15635             :  * 
   15636             :  */
   15637           0 :     (__pyx_v_dst->strides[__pyx_v_dim]) = (__pyx_v_strides[__pyx_v_dim]);
   15638             : 
   15639             :     /* "View.MemoryView":1077
   15640             :  *         dst.shape[dim] = shape[dim]
   15641             :  *         dst.strides[dim] = strides[dim]
   15642             :  *         dst.suboffsets[dim] = suboffsets[dim] if suboffsets else -1             # <<<<<<<<<<<<<<
   15643             :  * 
   15644             :  * @cname('__pyx_memoryview_copy_object')
   15645             :  */
   15646           0 :     __pyx_t_6 = (__pyx_v_suboffsets != 0);
   15647           0 :     if (__pyx_t_6) {
   15648           0 :       __pyx_t_5 = (__pyx_v_suboffsets[__pyx_v_dim]);
   15649             :     } else {
   15650             :       __pyx_t_5 = -1L;
   15651             :     }
   15652           0 :     (__pyx_v_dst->suboffsets[__pyx_v_dim]) = __pyx_t_5;
   15653             :   }
   15654             : 
   15655             :   /* "View.MemoryView":1063
   15656             :  * 
   15657             :  * @cname('__pyx_memoryview_slice_copy')
   15658             :  * cdef void slice_copy(memoryview memview, __Pyx_memviewslice *dst) noexcept:             # <<<<<<<<<<<<<<
   15659             :  *     cdef int dim
   15660             :  *     cdef (Py_ssize_t*) shape, strides, suboffsets
   15661             :  */
   15662             : 
   15663             :   /* function exit code */
   15664           0 : }
   15665             : 
   15666             : /* "View.MemoryView":1080
   15667             :  * 
   15668             :  * @cname('__pyx_memoryview_copy_object')
   15669             :  * cdef memoryview_copy(memoryview memview):             # <<<<<<<<<<<<<<
   15670             :  *     "Create a new memoryview object"
   15671             :  *     cdef __Pyx_memviewslice memviewslice
   15672             :  */
   15673             : 
   15674           0 : static PyObject *__pyx_memoryview_copy_object(struct __pyx_memoryview_obj *__pyx_v_memview) {
   15675           0 :   __Pyx_memviewslice __pyx_v_memviewslice;
   15676           0 :   PyObject *__pyx_r = NULL;
   15677             :   __Pyx_RefNannyDeclarations
   15678           0 :   PyObject *__pyx_t_1 = NULL;
   15679           0 :   int __pyx_lineno = 0;
   15680           0 :   const char *__pyx_filename = NULL;
   15681           0 :   int __pyx_clineno = 0;
   15682           0 :   __Pyx_RefNannySetupContext("memoryview_copy", 1);
   15683             : 
   15684             :   /* "View.MemoryView":1083
   15685             :  *     "Create a new memoryview object"
   15686             :  *     cdef __Pyx_memviewslice memviewslice
   15687             :  *     slice_copy(memview, &memviewslice)             # <<<<<<<<<<<<<<
   15688             :  *     return memoryview_copy_from_slice(memview, &memviewslice)
   15689             :  * 
   15690             :  */
   15691           0 :   __pyx_memoryview_slice_copy(__pyx_v_memview, (&__pyx_v_memviewslice));
   15692             : 
   15693             :   /* "View.MemoryView":1084
   15694             :  *     cdef __Pyx_memviewslice memviewslice
   15695             :  *     slice_copy(memview, &memviewslice)
   15696             :  *     return memoryview_copy_from_slice(memview, &memviewslice)             # <<<<<<<<<<<<<<
   15697             :  * 
   15698             :  * @cname('__pyx_memoryview_copy_object_from_slice')
   15699             :  */
   15700           0 :   __Pyx_XDECREF(__pyx_r);
   15701           0 :   __pyx_t_1 = __pyx_memoryview_copy_object_from_slice(__pyx_v_memview, (&__pyx_v_memviewslice)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1084, __pyx_L1_error)
   15702           0 :   __Pyx_GOTREF(__pyx_t_1);
   15703           0 :   __pyx_r = __pyx_t_1;
   15704           0 :   __pyx_t_1 = 0;
   15705           0 :   goto __pyx_L0;
   15706             : 
   15707             :   /* "View.MemoryView":1080
   15708             :  * 
   15709             :  * @cname('__pyx_memoryview_copy_object')
   15710             :  * cdef memoryview_copy(memoryview memview):             # <<<<<<<<<<<<<<
   15711             :  *     "Create a new memoryview object"
   15712             :  *     cdef __Pyx_memviewslice memviewslice
   15713             :  */
   15714             : 
   15715             :   /* function exit code */
   15716           0 :   __pyx_L1_error:;
   15717           0 :   __Pyx_XDECREF(__pyx_t_1);
   15718           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview_copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15719           0 :   __pyx_r = 0;
   15720           0 :   __pyx_L0:;
   15721           0 :   __Pyx_XGIVEREF(__pyx_r);
   15722           0 :   __Pyx_RefNannyFinishContext();
   15723           0 :   return __pyx_r;
   15724             : }
   15725             : 
   15726             : /* "View.MemoryView":1087
   15727             :  * 
   15728             :  * @cname('__pyx_memoryview_copy_object_from_slice')
   15729             :  * cdef memoryview_copy_from_slice(memoryview memview, __Pyx_memviewslice *memviewslice):             # <<<<<<<<<<<<<<
   15730             :  *     """
   15731             :  *     Create a new memoryview object from a given memoryview object and slice.
   15732             :  */
   15733             : 
   15734           0 : static PyObject *__pyx_memoryview_copy_object_from_slice(struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_memviewslice) {
   15735           0 :   PyObject *(*__pyx_v_to_object_func)(char *);
   15736           0 :   int (*__pyx_v_to_dtype_func)(char *, PyObject *);
   15737           0 :   PyObject *__pyx_r = NULL;
   15738             :   __Pyx_RefNannyDeclarations
   15739           0 :   int __pyx_t_1;
   15740           0 :   PyObject *(*__pyx_t_2)(char *);
   15741           0 :   int (*__pyx_t_3)(char *, PyObject *);
   15742           0 :   PyObject *__pyx_t_4 = NULL;
   15743           0 :   int __pyx_lineno = 0;
   15744           0 :   const char *__pyx_filename = NULL;
   15745           0 :   int __pyx_clineno = 0;
   15746           0 :   __Pyx_RefNannySetupContext("memoryview_copy_from_slice", 1);
   15747             : 
   15748             :   /* "View.MemoryView":1094
   15749             :  *     cdef int (*to_dtype_func)(char *, object) except 0
   15750             :  * 
   15751             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   15752             :  *         to_object_func = (<_memoryviewslice> memview).to_object_func
   15753             :  *         to_dtype_func = (<_memoryviewslice> memview).to_dtype_func
   15754             :  */
   15755           0 :   __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type); 
   15756           0 :   if (__pyx_t_1) {
   15757             : 
   15758             :     /* "View.MemoryView":1095
   15759             :  * 
   15760             :  *     if isinstance(memview, _memoryviewslice):
   15761             :  *         to_object_func = (<_memoryviewslice> memview).to_object_func             # <<<<<<<<<<<<<<
   15762             :  *         to_dtype_func = (<_memoryviewslice> memview).to_dtype_func
   15763             :  *     else:
   15764             :  */
   15765           0 :     __pyx_t_2 = ((struct __pyx_memoryviewslice_obj *)__pyx_v_memview)->to_object_func;
   15766           0 :     __pyx_v_to_object_func = __pyx_t_2;
   15767             : 
   15768             :     /* "View.MemoryView":1096
   15769             :  *     if isinstance(memview, _memoryviewslice):
   15770             :  *         to_object_func = (<_memoryviewslice> memview).to_object_func
   15771             :  *         to_dtype_func = (<_memoryviewslice> memview).to_dtype_func             # <<<<<<<<<<<<<<
   15772             :  *     else:
   15773             :  *         to_object_func = NULL
   15774             :  */
   15775           0 :     __pyx_t_3 = ((struct __pyx_memoryviewslice_obj *)__pyx_v_memview)->to_dtype_func;
   15776           0 :     __pyx_v_to_dtype_func = __pyx_t_3;
   15777             : 
   15778             :     /* "View.MemoryView":1094
   15779             :  *     cdef int (*to_dtype_func)(char *, object) except 0
   15780             :  * 
   15781             :  *     if isinstance(memview, _memoryviewslice):             # <<<<<<<<<<<<<<
   15782             :  *         to_object_func = (<_memoryviewslice> memview).to_object_func
   15783             :  *         to_dtype_func = (<_memoryviewslice> memview).to_dtype_func
   15784             :  */
   15785           0 :     goto __pyx_L3;
   15786             :   }
   15787             : 
   15788             :   /* "View.MemoryView":1098
   15789             :  *         to_dtype_func = (<_memoryviewslice> memview).to_dtype_func
   15790             :  *     else:
   15791             :  *         to_object_func = NULL             # <<<<<<<<<<<<<<
   15792             :  *         to_dtype_func = NULL
   15793             :  * 
   15794             :  */
   15795             :   /*else*/ {
   15796             :     __pyx_v_to_object_func = NULL;
   15797             : 
   15798             :     /* "View.MemoryView":1099
   15799             :  *     else:
   15800             :  *         to_object_func = NULL
   15801             :  *         to_dtype_func = NULL             # <<<<<<<<<<<<<<
   15802             :  * 
   15803             :  *     return memoryview_fromslice(memviewslice[0], memview.view.ndim,
   15804             :  */
   15805             :     __pyx_v_to_dtype_func = NULL;
   15806             :   }
   15807           0 :   __pyx_L3:;
   15808             : 
   15809             :   /* "View.MemoryView":1101
   15810             :  *         to_dtype_func = NULL
   15811             :  * 
   15812             :  *     return memoryview_fromslice(memviewslice[0], memview.view.ndim,             # <<<<<<<<<<<<<<
   15813             :  *                                 to_object_func, to_dtype_func,
   15814             :  *                                 memview.dtype_is_object)
   15815             :  */
   15816           0 :   __Pyx_XDECREF(__pyx_r);
   15817             : 
   15818             :   /* "View.MemoryView":1103
   15819             :  *     return memoryview_fromslice(memviewslice[0], memview.view.ndim,
   15820             :  *                                 to_object_func, to_dtype_func,
   15821             :  *                                 memview.dtype_is_object)             # <<<<<<<<<<<<<<
   15822             :  * 
   15823             :  * 
   15824             :  */
   15825           0 :   __pyx_t_4 = __pyx_memoryview_fromslice((__pyx_v_memviewslice[0]), __pyx_v_memview->view.ndim, __pyx_v_to_object_func, __pyx_v_to_dtype_func, __pyx_v_memview->dtype_is_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1101, __pyx_L1_error)
   15826           0 :   __Pyx_GOTREF(__pyx_t_4);
   15827           0 :   __pyx_r = __pyx_t_4;
   15828           0 :   __pyx_t_4 = 0;
   15829           0 :   goto __pyx_L0;
   15830             : 
   15831             :   /* "View.MemoryView":1087
   15832             :  * 
   15833             :  * @cname('__pyx_memoryview_copy_object_from_slice')
   15834             :  * cdef memoryview_copy_from_slice(memoryview memview, __Pyx_memviewslice *memviewslice):             # <<<<<<<<<<<<<<
   15835             :  *     """
   15836             :  *     Create a new memoryview object from a given memoryview object and slice.
   15837             :  */
   15838             : 
   15839             :   /* function exit code */
   15840           0 :   __pyx_L1_error:;
   15841           0 :   __Pyx_XDECREF(__pyx_t_4);
   15842           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview_copy_from_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
   15843           0 :   __pyx_r = 0;
   15844           0 :   __pyx_L0:;
   15845           0 :   __Pyx_XGIVEREF(__pyx_r);
   15846           0 :   __Pyx_RefNannyFinishContext();
   15847           0 :   return __pyx_r;
   15848             : }
   15849             : 
   15850             : /* "View.MemoryView":1109
   15851             :  * 
   15852             :  * 
   15853             :  * cdef Py_ssize_t abs_py_ssize_t(Py_ssize_t arg) noexcept nogil:             # <<<<<<<<<<<<<<
   15854             :  *     return -arg if arg < 0 else arg
   15855             :  * 
   15856             :  */
   15857             : 
   15858           0 : static Py_ssize_t abs_py_ssize_t(Py_ssize_t __pyx_v_arg) {
   15859           0 :   Py_ssize_t __pyx_r;
   15860           0 :   Py_ssize_t __pyx_t_1;
   15861           0 :   int __pyx_t_2;
   15862             : 
   15863             :   /* "View.MemoryView":1110
   15864             :  * 
   15865             :  * cdef Py_ssize_t abs_py_ssize_t(Py_ssize_t arg) noexcept nogil:
   15866             :  *     return -arg if arg < 0 else arg             # <<<<<<<<<<<<<<
   15867             :  * 
   15868             :  * @cname('__pyx_get_best_slice_order')
   15869             :  */
   15870           0 :   __pyx_t_2 = (__pyx_v_arg < 0);
   15871           0 :   if (__pyx_t_2) {
   15872             :     __pyx_t_1 = (-__pyx_v_arg);
   15873             :   } else {
   15874             :     __pyx_t_1 = __pyx_v_arg;
   15875             :   }
   15876           0 :   __pyx_r = __pyx_t_1;
   15877           0 :   goto __pyx_L0;
   15878             : 
   15879             :   /* "View.MemoryView":1109
   15880             :  * 
   15881             :  * 
   15882             :  * cdef Py_ssize_t abs_py_ssize_t(Py_ssize_t arg) noexcept nogil:             # <<<<<<<<<<<<<<
   15883             :  *     return -arg if arg < 0 else arg
   15884             :  * 
   15885             :  */
   15886             : 
   15887             :   /* function exit code */
   15888           0 :   __pyx_L0:;
   15889           0 :   return __pyx_r;
   15890             : }
   15891             : 
   15892             : /* "View.MemoryView":1113
   15893             :  * 
   15894             :  * @cname('__pyx_get_best_slice_order')
   15895             :  * cdef char get_best_order(__Pyx_memviewslice *mslice, int ndim) noexcept nogil:             # <<<<<<<<<<<<<<
   15896             :  *     """
   15897             :  *     Figure out the best memory access order for a given slice.
   15898             :  */
   15899             : 
   15900           0 : static char __pyx_get_best_slice_order(__Pyx_memviewslice *__pyx_v_mslice, int __pyx_v_ndim) {
   15901           0 :   int __pyx_v_i;
   15902           0 :   Py_ssize_t __pyx_v_c_stride;
   15903           0 :   Py_ssize_t __pyx_v_f_stride;
   15904           0 :   char __pyx_r;
   15905           0 :   int __pyx_t_1;
   15906           0 :   int __pyx_t_2;
   15907           0 :   int __pyx_t_3;
   15908           0 :   int __pyx_t_4;
   15909             : 
   15910             :   /* "View.MemoryView":1118
   15911             :  *     """
   15912             :  *     cdef int i
   15913             :  *     cdef Py_ssize_t c_stride = 0             # <<<<<<<<<<<<<<
   15914             :  *     cdef Py_ssize_t f_stride = 0
   15915             :  * 
   15916             :  */
   15917           0 :   __pyx_v_c_stride = 0;
   15918             : 
   15919             :   /* "View.MemoryView":1119
   15920             :  *     cdef int i
   15921             :  *     cdef Py_ssize_t c_stride = 0
   15922             :  *     cdef Py_ssize_t f_stride = 0             # <<<<<<<<<<<<<<
   15923             :  * 
   15924             :  *     for i in range(ndim - 1, -1, -1):
   15925             :  */
   15926           0 :   __pyx_v_f_stride = 0;
   15927             : 
   15928             :   /* "View.MemoryView":1121
   15929             :  *     cdef Py_ssize_t f_stride = 0
   15930             :  * 
   15931             :  *     for i in range(ndim - 1, -1, -1):             # <<<<<<<<<<<<<<
   15932             :  *         if mslice.shape[i] > 1:
   15933             :  *             c_stride = mslice.strides[i]
   15934             :  */
   15935           0 :   for (__pyx_t_1 = (__pyx_v_ndim - 1); __pyx_t_1 > -1; __pyx_t_1-=1) {
   15936           0 :     __pyx_v_i = __pyx_t_1;
   15937             : 
   15938             :     /* "View.MemoryView":1122
   15939             :  * 
   15940             :  *     for i in range(ndim - 1, -1, -1):
   15941             :  *         if mslice.shape[i] > 1:             # <<<<<<<<<<<<<<
   15942             :  *             c_stride = mslice.strides[i]
   15943             :  *             break
   15944             :  */
   15945           0 :     __pyx_t_2 = ((__pyx_v_mslice->shape[__pyx_v_i]) > 1);
   15946           0 :     if (__pyx_t_2) {
   15947             : 
   15948             :       /* "View.MemoryView":1123
   15949             :  *     for i in range(ndim - 1, -1, -1):
   15950             :  *         if mslice.shape[i] > 1:
   15951             :  *             c_stride = mslice.strides[i]             # <<<<<<<<<<<<<<
   15952             :  *             break
   15953             :  * 
   15954             :  */
   15955           0 :       __pyx_v_c_stride = (__pyx_v_mslice->strides[__pyx_v_i]);
   15956             : 
   15957             :       /* "View.MemoryView":1124
   15958             :  *         if mslice.shape[i] > 1:
   15959             :  *             c_stride = mslice.strides[i]
   15960             :  *             break             # <<<<<<<<<<<<<<
   15961             :  * 
   15962             :  *     for i in range(ndim):
   15963             :  */
   15964           0 :       goto __pyx_L4_break;
   15965             : 
   15966             :       /* "View.MemoryView":1122
   15967             :  * 
   15968             :  *     for i in range(ndim - 1, -1, -1):
   15969             :  *         if mslice.shape[i] > 1:             # <<<<<<<<<<<<<<
   15970             :  *             c_stride = mslice.strides[i]
   15971             :  *             break
   15972             :  */
   15973             :     }
   15974             :   }
   15975           0 :   __pyx_L4_break:;
   15976             : 
   15977             :   /* "View.MemoryView":1126
   15978             :  *             break
   15979             :  * 
   15980             :  *     for i in range(ndim):             # <<<<<<<<<<<<<<
   15981             :  *         if mslice.shape[i] > 1:
   15982             :  *             f_stride = mslice.strides[i]
   15983             :  */
   15984           0 :   __pyx_t_1 = __pyx_v_ndim;
   15985           0 :   __pyx_t_3 = __pyx_t_1;
   15986           0 :   for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   15987           0 :     __pyx_v_i = __pyx_t_4;
   15988             : 
   15989             :     /* "View.MemoryView":1127
   15990             :  * 
   15991             :  *     for i in range(ndim):
   15992             :  *         if mslice.shape[i] > 1:             # <<<<<<<<<<<<<<
   15993             :  *             f_stride = mslice.strides[i]
   15994             :  *             break
   15995             :  */
   15996           0 :     __pyx_t_2 = ((__pyx_v_mslice->shape[__pyx_v_i]) > 1);
   15997           0 :     if (__pyx_t_2) {
   15998             : 
   15999             :       /* "View.MemoryView":1128
   16000             :  *     for i in range(ndim):
   16001             :  *         if mslice.shape[i] > 1:
   16002             :  *             f_stride = mslice.strides[i]             # <<<<<<<<<<<<<<
   16003             :  *             break
   16004             :  * 
   16005             :  */
   16006           0 :       __pyx_v_f_stride = (__pyx_v_mslice->strides[__pyx_v_i]);
   16007             : 
   16008             :       /* "View.MemoryView":1129
   16009             :  *         if mslice.shape[i] > 1:
   16010             :  *             f_stride = mslice.strides[i]
   16011             :  *             break             # <<<<<<<<<<<<<<
   16012             :  * 
   16013             :  *     if abs_py_ssize_t(c_stride) <= abs_py_ssize_t(f_stride):
   16014             :  */
   16015           0 :       goto __pyx_L7_break;
   16016             : 
   16017             :       /* "View.MemoryView":1127
   16018             :  * 
   16019             :  *     for i in range(ndim):
   16020             :  *         if mslice.shape[i] > 1:             # <<<<<<<<<<<<<<
   16021             :  *             f_stride = mslice.strides[i]
   16022             :  *             break
   16023             :  */
   16024             :     }
   16025             :   }
   16026           0 :   __pyx_L7_break:;
   16027             : 
   16028             :   /* "View.MemoryView":1131
   16029             :  *             break
   16030             :  * 
   16031             :  *     if abs_py_ssize_t(c_stride) <= abs_py_ssize_t(f_stride):             # <<<<<<<<<<<<<<
   16032             :  *         return 'C'
   16033             :  *     else:
   16034             :  */
   16035           0 :   __pyx_t_2 = (abs_py_ssize_t(__pyx_v_c_stride) <= abs_py_ssize_t(__pyx_v_f_stride));
   16036           0 :   if (__pyx_t_2) {
   16037             : 
   16038             :     /* "View.MemoryView":1132
   16039             :  * 
   16040             :  *     if abs_py_ssize_t(c_stride) <= abs_py_ssize_t(f_stride):
   16041             :  *         return 'C'             # <<<<<<<<<<<<<<
   16042             :  *     else:
   16043             :  *         return 'F'
   16044             :  */
   16045           0 :     __pyx_r = 'C';
   16046           0 :     goto __pyx_L0;
   16047             : 
   16048             :     /* "View.MemoryView":1131
   16049             :  *             break
   16050             :  * 
   16051             :  *     if abs_py_ssize_t(c_stride) <= abs_py_ssize_t(f_stride):             # <<<<<<<<<<<<<<
   16052             :  *         return 'C'
   16053             :  *     else:
   16054             :  */
   16055             :   }
   16056             : 
   16057             :   /* "View.MemoryView":1134
   16058             :  *         return 'C'
   16059             :  *     else:
   16060             :  *         return 'F'             # <<<<<<<<<<<<<<
   16061             :  * 
   16062             :  * @cython.cdivision(True)
   16063             :  */
   16064             :   /*else*/ {
   16065           0 :     __pyx_r = 'F';
   16066           0 :     goto __pyx_L0;
   16067             :   }
   16068             : 
   16069             :   /* "View.MemoryView":1113
   16070             :  * 
   16071             :  * @cname('__pyx_get_best_slice_order')
   16072             :  * cdef char get_best_order(__Pyx_memviewslice *mslice, int ndim) noexcept nogil:             # <<<<<<<<<<<<<<
   16073             :  *     """
   16074             :  *     Figure out the best memory access order for a given slice.
   16075             :  */
   16076             : 
   16077             :   /* function exit code */
   16078           0 :   __pyx_L0:;
   16079           0 :   return __pyx_r;
   16080             : }
   16081             : 
   16082             : /* "View.MemoryView":1137
   16083             :  * 
   16084             :  * @cython.cdivision(True)
   16085             :  * cdef void _copy_strided_to_strided(char *src_data, Py_ssize_t *src_strides,             # <<<<<<<<<<<<<<
   16086             :  *                                    char *dst_data, Py_ssize_t *dst_strides,
   16087             :  *                                    Py_ssize_t *src_shape, Py_ssize_t *dst_shape,
   16088             :  */
   16089             : 
   16090           0 : static void _copy_strided_to_strided(char *__pyx_v_src_data, Py_ssize_t *__pyx_v_src_strides, char *__pyx_v_dst_data, Py_ssize_t *__pyx_v_dst_strides, Py_ssize_t *__pyx_v_src_shape, Py_ssize_t *__pyx_v_dst_shape, int __pyx_v_ndim, size_t __pyx_v_itemsize) {
   16091           0 :   CYTHON_UNUSED Py_ssize_t __pyx_v_i;
   16092           0 :   CYTHON_UNUSED Py_ssize_t __pyx_v_src_extent;
   16093           0 :   Py_ssize_t __pyx_v_dst_extent;
   16094           0 :   Py_ssize_t __pyx_v_src_stride;
   16095           0 :   Py_ssize_t __pyx_v_dst_stride;
   16096           0 :   int __pyx_t_1;
   16097           0 :   int __pyx_t_2;
   16098           0 :   Py_ssize_t __pyx_t_3;
   16099           0 :   Py_ssize_t __pyx_t_4;
   16100           0 :   Py_ssize_t __pyx_t_5;
   16101             : 
   16102             :   /* "View.MemoryView":1144
   16103             :  * 
   16104             :  *     cdef Py_ssize_t i
   16105             :  *     cdef Py_ssize_t src_extent = src_shape[0]             # <<<<<<<<<<<<<<
   16106             :  *     cdef Py_ssize_t dst_extent = dst_shape[0]
   16107             :  *     cdef Py_ssize_t src_stride = src_strides[0]
   16108             :  */
   16109           0 :   __pyx_v_src_extent = (__pyx_v_src_shape[0]);
   16110             : 
   16111             :   /* "View.MemoryView":1145
   16112             :  *     cdef Py_ssize_t i
   16113             :  *     cdef Py_ssize_t src_extent = src_shape[0]
   16114             :  *     cdef Py_ssize_t dst_extent = dst_shape[0]             # <<<<<<<<<<<<<<
   16115             :  *     cdef Py_ssize_t src_stride = src_strides[0]
   16116             :  *     cdef Py_ssize_t dst_stride = dst_strides[0]
   16117             :  */
   16118           0 :   __pyx_v_dst_extent = (__pyx_v_dst_shape[0]);
   16119             : 
   16120             :   /* "View.MemoryView":1146
   16121             :  *     cdef Py_ssize_t src_extent = src_shape[0]
   16122             :  *     cdef Py_ssize_t dst_extent = dst_shape[0]
   16123             :  *     cdef Py_ssize_t src_stride = src_strides[0]             # <<<<<<<<<<<<<<
   16124             :  *     cdef Py_ssize_t dst_stride = dst_strides[0]
   16125             :  * 
   16126             :  */
   16127           0 :   __pyx_v_src_stride = (__pyx_v_src_strides[0]);
   16128             : 
   16129             :   /* "View.MemoryView":1147
   16130             :  *     cdef Py_ssize_t dst_extent = dst_shape[0]
   16131             :  *     cdef Py_ssize_t src_stride = src_strides[0]
   16132             :  *     cdef Py_ssize_t dst_stride = dst_strides[0]             # <<<<<<<<<<<<<<
   16133             :  * 
   16134             :  *     if ndim == 1:
   16135             :  */
   16136           0 :   __pyx_v_dst_stride = (__pyx_v_dst_strides[0]);
   16137             : 
   16138             :   /* "View.MemoryView":1149
   16139             :  *     cdef Py_ssize_t dst_stride = dst_strides[0]
   16140             :  * 
   16141             :  *     if ndim == 1:             # <<<<<<<<<<<<<<
   16142             :  *         if (src_stride > 0 and dst_stride > 0 and
   16143             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16144             :  */
   16145           0 :   __pyx_t_1 = (__pyx_v_ndim == 1);
   16146           0 :   if (__pyx_t_1) {
   16147             : 
   16148             :     /* "View.MemoryView":1150
   16149             :  * 
   16150             :  *     if ndim == 1:
   16151             :  *         if (src_stride > 0 and dst_stride > 0 and             # <<<<<<<<<<<<<<
   16152             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16153             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)
   16154             :  */
   16155           0 :     __pyx_t_2 = (__pyx_v_src_stride > 0);
   16156           0 :     if (__pyx_t_2) {
   16157           0 :     } else {
   16158           0 :       __pyx_t_1 = __pyx_t_2;
   16159           0 :       goto __pyx_L5_bool_binop_done;
   16160             :     }
   16161           0 :     __pyx_t_2 = (__pyx_v_dst_stride > 0);
   16162           0 :     if (__pyx_t_2) {
   16163           0 :     } else {
   16164           0 :       __pyx_t_1 = __pyx_t_2;
   16165           0 :       goto __pyx_L5_bool_binop_done;
   16166             :     }
   16167             : 
   16168             :     /* "View.MemoryView":1151
   16169             :  *     if ndim == 1:
   16170             :  *         if (src_stride > 0 and dst_stride > 0 and
   16171             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):             # <<<<<<<<<<<<<<
   16172             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)
   16173             :  *         else:
   16174             :  */
   16175           0 :     __pyx_t_2 = (((size_t)__pyx_v_src_stride) == __pyx_v_itemsize);
   16176           0 :     if (__pyx_t_2) {
   16177           0 :       __pyx_t_2 = (__pyx_v_itemsize == ((size_t)__pyx_v_dst_stride));
   16178             :     }
   16179             :     __pyx_t_1 = __pyx_t_2;
   16180           0 :     __pyx_L5_bool_binop_done:;
   16181             : 
   16182             :     /* "View.MemoryView":1150
   16183             :  * 
   16184             :  *     if ndim == 1:
   16185             :  *         if (src_stride > 0 and dst_stride > 0 and             # <<<<<<<<<<<<<<
   16186             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16187             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)
   16188             :  */
   16189           0 :     if (__pyx_t_1) {
   16190             : 
   16191             :       /* "View.MemoryView":1152
   16192             :  *         if (src_stride > 0 and dst_stride > 0 and
   16193             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16194             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)             # <<<<<<<<<<<<<<
   16195             :  *         else:
   16196             :  *             for i in range(dst_extent):
   16197             :  */
   16198           0 :       (void)(memcpy(__pyx_v_dst_data, __pyx_v_src_data, (__pyx_v_itemsize * __pyx_v_dst_extent)));
   16199             : 
   16200             :       /* "View.MemoryView":1150
   16201             :  * 
   16202             :  *     if ndim == 1:
   16203             :  *         if (src_stride > 0 and dst_stride > 0 and             # <<<<<<<<<<<<<<
   16204             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16205             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)
   16206             :  */
   16207           0 :       goto __pyx_L4;
   16208             :     }
   16209             : 
   16210             :     /* "View.MemoryView":1154
   16211             :  *             memcpy(dst_data, src_data, itemsize * dst_extent)
   16212             :  *         else:
   16213             :  *             for i in range(dst_extent):             # <<<<<<<<<<<<<<
   16214             :  *                 memcpy(dst_data, src_data, itemsize)
   16215             :  *                 src_data += src_stride
   16216             :  */
   16217             :     /*else*/ {
   16218             :       __pyx_t_3 = __pyx_v_dst_extent;
   16219             :       __pyx_t_4 = __pyx_t_3;
   16220           0 :       for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
   16221           0 :         __pyx_v_i = __pyx_t_5;
   16222             : 
   16223             :         /* "View.MemoryView":1155
   16224             :  *         else:
   16225             :  *             for i in range(dst_extent):
   16226             :  *                 memcpy(dst_data, src_data, itemsize)             # <<<<<<<<<<<<<<
   16227             :  *                 src_data += src_stride
   16228             :  *                 dst_data += dst_stride
   16229             :  */
   16230           0 :         (void)(memcpy(__pyx_v_dst_data, __pyx_v_src_data, __pyx_v_itemsize));
   16231             : 
   16232             :         /* "View.MemoryView":1156
   16233             :  *             for i in range(dst_extent):
   16234             :  *                 memcpy(dst_data, src_data, itemsize)
   16235             :  *                 src_data += src_stride             # <<<<<<<<<<<<<<
   16236             :  *                 dst_data += dst_stride
   16237             :  *     else:
   16238             :  */
   16239           0 :         __pyx_v_src_data = (__pyx_v_src_data + __pyx_v_src_stride);
   16240             : 
   16241             :         /* "View.MemoryView":1157
   16242             :  *                 memcpy(dst_data, src_data, itemsize)
   16243             :  *                 src_data += src_stride
   16244             :  *                 dst_data += dst_stride             # <<<<<<<<<<<<<<
   16245             :  *     else:
   16246             :  *         for i in range(dst_extent):
   16247             :  */
   16248           0 :         __pyx_v_dst_data = (__pyx_v_dst_data + __pyx_v_dst_stride);
   16249             :       }
   16250             :     }
   16251           0 :     __pyx_L4:;
   16252             : 
   16253             :     /* "View.MemoryView":1149
   16254             :  *     cdef Py_ssize_t dst_stride = dst_strides[0]
   16255             :  * 
   16256             :  *     if ndim == 1:             # <<<<<<<<<<<<<<
   16257             :  *         if (src_stride > 0 and dst_stride > 0 and
   16258             :  *             <size_t> src_stride == itemsize == <size_t> dst_stride):
   16259             :  */
   16260           0 :     goto __pyx_L3;
   16261             :   }
   16262             : 
   16263             :   /* "View.MemoryView":1159
   16264             :  *                 dst_data += dst_stride
   16265             :  *     else:
   16266             :  *         for i in range(dst_extent):             # <<<<<<<<<<<<<<
   16267             :  *             _copy_strided_to_strided(src_data, src_strides + 1,
   16268             :  *                                      dst_data, dst_strides + 1,
   16269             :  */
   16270             :   /*else*/ {
   16271             :     __pyx_t_3 = __pyx_v_dst_extent;
   16272             :     __pyx_t_4 = __pyx_t_3;
   16273           0 :     for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
   16274           0 :       __pyx_v_i = __pyx_t_5;
   16275             : 
   16276             :       /* "View.MemoryView":1160
   16277             :  *     else:
   16278             :  *         for i in range(dst_extent):
   16279             :  *             _copy_strided_to_strided(src_data, src_strides + 1,             # <<<<<<<<<<<<<<
   16280             :  *                                      dst_data, dst_strides + 1,
   16281             :  *                                      src_shape + 1, dst_shape + 1,
   16282             :  */
   16283           0 :       _copy_strided_to_strided(__pyx_v_src_data, (__pyx_v_src_strides + 1), __pyx_v_dst_data, (__pyx_v_dst_strides + 1), (__pyx_v_src_shape + 1), (__pyx_v_dst_shape + 1), (__pyx_v_ndim - 1), __pyx_v_itemsize);
   16284             : 
   16285             :       /* "View.MemoryView":1164
   16286             :  *                                      src_shape + 1, dst_shape + 1,
   16287             :  *                                      ndim - 1, itemsize)
   16288             :  *             src_data += src_stride             # <<<<<<<<<<<<<<
   16289             :  *             dst_data += dst_stride
   16290             :  * 
   16291             :  */
   16292           0 :       __pyx_v_src_data = (__pyx_v_src_data + __pyx_v_src_stride);
   16293             : 
   16294             :       /* "View.MemoryView":1165
   16295             :  *                                      ndim - 1, itemsize)
   16296             :  *             src_data += src_stride
   16297             :  *             dst_data += dst_stride             # <<<<<<<<<<<<<<
   16298             :  * 
   16299             :  * cdef void copy_strided_to_strided(__Pyx_memviewslice *src,
   16300             :  */
   16301           0 :       __pyx_v_dst_data = (__pyx_v_dst_data + __pyx_v_dst_stride);
   16302             :     }
   16303             :   }
   16304           0 :   __pyx_L3:;
   16305             : 
   16306             :   /* "View.MemoryView":1137
   16307             :  * 
   16308             :  * @cython.cdivision(True)
   16309             :  * cdef void _copy_strided_to_strided(char *src_data, Py_ssize_t *src_strides,             # <<<<<<<<<<<<<<
   16310             :  *                                    char *dst_data, Py_ssize_t *dst_strides,
   16311             :  *                                    Py_ssize_t *src_shape, Py_ssize_t *dst_shape,
   16312             :  */
   16313             : 
   16314             :   /* function exit code */
   16315           0 : }
   16316             : 
   16317             : /* "View.MemoryView":1167
   16318             :  *             dst_data += dst_stride
   16319             :  * 
   16320             :  * cdef void copy_strided_to_strided(__Pyx_memviewslice *src,             # <<<<<<<<<<<<<<
   16321             :  *                                   __Pyx_memviewslice *dst,
   16322             :  *                                   int ndim, size_t itemsize) noexcept nogil:
   16323             :  */
   16324             : 
   16325           0 : static void copy_strided_to_strided(__Pyx_memviewslice *__pyx_v_src, __Pyx_memviewslice *__pyx_v_dst, int __pyx_v_ndim, size_t __pyx_v_itemsize) {
   16326             : 
   16327             :   /* "View.MemoryView":1170
   16328             :  *                                   __Pyx_memviewslice *dst,
   16329             :  *                                   int ndim, size_t itemsize) noexcept nogil:
   16330             :  *     _copy_strided_to_strided(src.data, src.strides, dst.data, dst.strides,             # <<<<<<<<<<<<<<
   16331             :  *                              src.shape, dst.shape, ndim, itemsize)
   16332             :  * 
   16333             :  */
   16334           0 :   _copy_strided_to_strided(__pyx_v_src->data, __pyx_v_src->strides, __pyx_v_dst->data, __pyx_v_dst->strides, __pyx_v_src->shape, __pyx_v_dst->shape, __pyx_v_ndim, __pyx_v_itemsize);
   16335             : 
   16336             :   /* "View.MemoryView":1167
   16337             :  *             dst_data += dst_stride
   16338             :  * 
   16339             :  * cdef void copy_strided_to_strided(__Pyx_memviewslice *src,             # <<<<<<<<<<<<<<
   16340             :  *                                   __Pyx_memviewslice *dst,
   16341             :  *                                   int ndim, size_t itemsize) noexcept nogil:
   16342             :  */
   16343             : 
   16344             :   /* function exit code */
   16345           0 : }
   16346             : 
   16347             : /* "View.MemoryView":1174
   16348             :  * 
   16349             :  * @cname('__pyx_memoryview_slice_get_size')
   16350             :  * cdef Py_ssize_t slice_get_size(__Pyx_memviewslice *src, int ndim) noexcept nogil:             # <<<<<<<<<<<<<<
   16351             :  *     "Return the size of the memory occupied by the slice in number of bytes"
   16352             :  *     cdef Py_ssize_t shape, size = src.memview.view.itemsize
   16353             :  */
   16354             : 
   16355           0 : static Py_ssize_t __pyx_memoryview_slice_get_size(__Pyx_memviewslice *__pyx_v_src, int __pyx_v_ndim) {
   16356           0 :   Py_ssize_t __pyx_v_shape;
   16357           0 :   Py_ssize_t __pyx_v_size;
   16358           0 :   Py_ssize_t __pyx_r;
   16359           0 :   Py_ssize_t __pyx_t_1;
   16360           0 :   Py_ssize_t *__pyx_t_2;
   16361           0 :   Py_ssize_t *__pyx_t_3;
   16362           0 :   Py_ssize_t *__pyx_t_4;
   16363             : 
   16364             :   /* "View.MemoryView":1176
   16365             :  * cdef Py_ssize_t slice_get_size(__Pyx_memviewslice *src, int ndim) noexcept nogil:
   16366             :  *     "Return the size of the memory occupied by the slice in number of bytes"
   16367             :  *     cdef Py_ssize_t shape, size = src.memview.view.itemsize             # <<<<<<<<<<<<<<
   16368             :  * 
   16369             :  *     for shape in src.shape[:ndim]:
   16370             :  */
   16371           0 :   __pyx_t_1 = __pyx_v_src->memview->view.itemsize;
   16372           0 :   __pyx_v_size = __pyx_t_1;
   16373             : 
   16374             :   /* "View.MemoryView":1178
   16375             :  *     cdef Py_ssize_t shape, size = src.memview.view.itemsize
   16376             :  * 
   16377             :  *     for shape in src.shape[:ndim]:             # <<<<<<<<<<<<<<
   16378             :  *         size *= shape
   16379             :  * 
   16380             :  */
   16381           0 :   __pyx_t_3 = (__pyx_v_src->shape + __pyx_v_ndim);
   16382           0 :   for (__pyx_t_4 = __pyx_v_src->shape; __pyx_t_4 < __pyx_t_3; __pyx_t_4++) {
   16383           0 :     __pyx_t_2 = __pyx_t_4;
   16384           0 :     __pyx_v_shape = (__pyx_t_2[0]);
   16385             : 
   16386             :     /* "View.MemoryView":1179
   16387             :  * 
   16388             :  *     for shape in src.shape[:ndim]:
   16389             :  *         size *= shape             # <<<<<<<<<<<<<<
   16390             :  * 
   16391             :  *     return size
   16392             :  */
   16393           0 :     __pyx_v_size = (__pyx_v_size * __pyx_v_shape);
   16394             :   }
   16395             : 
   16396             :   /* "View.MemoryView":1181
   16397             :  *         size *= shape
   16398             :  * 
   16399             :  *     return size             # <<<<<<<<<<<<<<
   16400             :  * 
   16401             :  * @cname('__pyx_fill_contig_strides_array')
   16402             :  */
   16403           0 :   __pyx_r = __pyx_v_size;
   16404           0 :   goto __pyx_L0;
   16405             : 
   16406             :   /* "View.MemoryView":1174
   16407             :  * 
   16408             :  * @cname('__pyx_memoryview_slice_get_size')
   16409             :  * cdef Py_ssize_t slice_get_size(__Pyx_memviewslice *src, int ndim) noexcept nogil:             # <<<<<<<<<<<<<<
   16410             :  *     "Return the size of the memory occupied by the slice in number of bytes"
   16411             :  *     cdef Py_ssize_t shape, size = src.memview.view.itemsize
   16412             :  */
   16413             : 
   16414             :   /* function exit code */
   16415           0 :   __pyx_L0:;
   16416           0 :   return __pyx_r;
   16417             : }
   16418             : 
   16419             : /* "View.MemoryView":1184
   16420             :  * 
   16421             :  * @cname('__pyx_fill_contig_strides_array')
   16422             :  * cdef Py_ssize_t fill_contig_strides_array(             # <<<<<<<<<<<<<<
   16423             :  *                 Py_ssize_t *shape, Py_ssize_t *strides, Py_ssize_t stride,
   16424             :  *                 int ndim, char order) noexcept nogil:
   16425             :  */
   16426             : 
   16427           0 : static Py_ssize_t __pyx_fill_contig_strides_array(Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides, Py_ssize_t __pyx_v_stride, int __pyx_v_ndim, char __pyx_v_order) {
   16428           0 :   int __pyx_v_idx;
   16429           0 :   Py_ssize_t __pyx_r;
   16430           0 :   int __pyx_t_1;
   16431           0 :   int __pyx_t_2;
   16432           0 :   int __pyx_t_3;
   16433           0 :   int __pyx_t_4;
   16434             : 
   16435             :   /* "View.MemoryView":1193
   16436             :  *     cdef int idx
   16437             :  * 
   16438             :  *     if order == 'F':             # <<<<<<<<<<<<<<
   16439             :  *         for idx in range(ndim):
   16440             :  *             strides[idx] = stride
   16441             :  */
   16442           0 :   __pyx_t_1 = (__pyx_v_order == 'F');
   16443           0 :   if (__pyx_t_1) {
   16444             : 
   16445             :     /* "View.MemoryView":1194
   16446             :  * 
   16447             :  *     if order == 'F':
   16448             :  *         for idx in range(ndim):             # <<<<<<<<<<<<<<
   16449             :  *             strides[idx] = stride
   16450             :  *             stride *= shape[idx]
   16451             :  */
   16452           0 :     __pyx_t_2 = __pyx_v_ndim;
   16453             :     __pyx_t_3 = __pyx_t_2;
   16454           0 :     for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   16455           0 :       __pyx_v_idx = __pyx_t_4;
   16456             : 
   16457             :       /* "View.MemoryView":1195
   16458             :  *     if order == 'F':
   16459             :  *         for idx in range(ndim):
   16460             :  *             strides[idx] = stride             # <<<<<<<<<<<<<<
   16461             :  *             stride *= shape[idx]
   16462             :  *     else:
   16463             :  */
   16464           0 :       (__pyx_v_strides[__pyx_v_idx]) = __pyx_v_stride;
   16465             : 
   16466             :       /* "View.MemoryView":1196
   16467             :  *         for idx in range(ndim):
   16468             :  *             strides[idx] = stride
   16469             :  *             stride *= shape[idx]             # <<<<<<<<<<<<<<
   16470             :  *     else:
   16471             :  *         for idx in range(ndim - 1, -1, -1):
   16472             :  */
   16473           0 :       __pyx_v_stride = (__pyx_v_stride * (__pyx_v_shape[__pyx_v_idx]));
   16474             :     }
   16475             : 
   16476             :     /* "View.MemoryView":1193
   16477             :  *     cdef int idx
   16478             :  * 
   16479             :  *     if order == 'F':             # <<<<<<<<<<<<<<
   16480             :  *         for idx in range(ndim):
   16481             :  *             strides[idx] = stride
   16482             :  */
   16483           0 :     goto __pyx_L3;
   16484             :   }
   16485             : 
   16486             :   /* "View.MemoryView":1198
   16487             :  *             stride *= shape[idx]
   16488             :  *     else:
   16489             :  *         for idx in range(ndim - 1, -1, -1):             # <<<<<<<<<<<<<<
   16490             :  *             strides[idx] = stride
   16491             :  *             stride *= shape[idx]
   16492             :  */
   16493             :   /*else*/ {
   16494           0 :     for (__pyx_t_2 = (__pyx_v_ndim - 1); __pyx_t_2 > -1; __pyx_t_2-=1) {
   16495           0 :       __pyx_v_idx = __pyx_t_2;
   16496             : 
   16497             :       /* "View.MemoryView":1199
   16498             :  *     else:
   16499             :  *         for idx in range(ndim - 1, -1, -1):
   16500             :  *             strides[idx] = stride             # <<<<<<<<<<<<<<
   16501             :  *             stride *= shape[idx]
   16502             :  * 
   16503             :  */
   16504           0 :       (__pyx_v_strides[__pyx_v_idx]) = __pyx_v_stride;
   16505             : 
   16506             :       /* "View.MemoryView":1200
   16507             :  *         for idx in range(ndim - 1, -1, -1):
   16508             :  *             strides[idx] = stride
   16509             :  *             stride *= shape[idx]             # <<<<<<<<<<<<<<
   16510             :  * 
   16511             :  *     return stride
   16512             :  */
   16513           0 :       __pyx_v_stride = (__pyx_v_stride * (__pyx_v_shape[__pyx_v_idx]));
   16514             :     }
   16515             :   }
   16516           0 :   __pyx_L3:;
   16517             : 
   16518             :   /* "View.MemoryView":1202
   16519             :  *             stride *= shape[idx]
   16520             :  * 
   16521             :  *     return stride             # <<<<<<<<<<<<<<
   16522             :  * 
   16523             :  * @cname('__pyx_memoryview_copy_data_to_temp')
   16524             :  */
   16525           0 :   __pyx_r = __pyx_v_stride;
   16526           0 :   goto __pyx_L0;
   16527             : 
   16528             :   /* "View.MemoryView":1184
   16529             :  * 
   16530             :  * @cname('__pyx_fill_contig_strides_array')
   16531             :  * cdef Py_ssize_t fill_contig_strides_array(             # <<<<<<<<<<<<<<
   16532             :  *                 Py_ssize_t *shape, Py_ssize_t *strides, Py_ssize_t stride,
   16533             :  *                 int ndim, char order) noexcept nogil:
   16534             :  */
   16535             : 
   16536             :   /* function exit code */
   16537           0 :   __pyx_L0:;
   16538           0 :   return __pyx_r;
   16539             : }
   16540             : 
   16541             : /* "View.MemoryView":1205
   16542             :  * 
   16543             :  * @cname('__pyx_memoryview_copy_data_to_temp')
   16544             :  * cdef void *copy_data_to_temp(__Pyx_memviewslice *src,             # <<<<<<<<<<<<<<
   16545             :  *                              __Pyx_memviewslice *tmpslice,
   16546             :  *                              char order,
   16547             :  */
   16548             : 
   16549           0 : static void *__pyx_memoryview_copy_data_to_temp(__Pyx_memviewslice *__pyx_v_src, __Pyx_memviewslice *__pyx_v_tmpslice, char __pyx_v_order, int __pyx_v_ndim) {
   16550           0 :   int __pyx_v_i;
   16551           0 :   void *__pyx_v_result;
   16552           0 :   size_t __pyx_v_itemsize;
   16553           0 :   size_t __pyx_v_size;
   16554           0 :   void *__pyx_r;
   16555           0 :   Py_ssize_t __pyx_t_1;
   16556           0 :   int __pyx_t_2;
   16557           0 :   int __pyx_t_3;
   16558           0 :   struct __pyx_memoryview_obj *__pyx_t_4;
   16559           0 :   int __pyx_t_5;
   16560           0 :   int __pyx_t_6;
   16561           0 :   int __pyx_lineno = 0;
   16562           0 :   const char *__pyx_filename = NULL;
   16563           0 :   int __pyx_clineno = 0;
   16564             :   #ifdef WITH_THREAD
   16565           0 :   PyGILState_STATE __pyx_gilstate_save;
   16566             :   #endif
   16567             : 
   16568             :   /* "View.MemoryView":1216
   16569             :  *     cdef void *result
   16570             :  * 
   16571             :  *     cdef size_t itemsize = src.memview.view.itemsize             # <<<<<<<<<<<<<<
   16572             :  *     cdef size_t size = slice_get_size(src, ndim)
   16573             :  * 
   16574             :  */
   16575           0 :   __pyx_t_1 = __pyx_v_src->memview->view.itemsize;
   16576           0 :   __pyx_v_itemsize = __pyx_t_1;
   16577             : 
   16578             :   /* "View.MemoryView":1217
   16579             :  * 
   16580             :  *     cdef size_t itemsize = src.memview.view.itemsize
   16581             :  *     cdef size_t size = slice_get_size(src, ndim)             # <<<<<<<<<<<<<<
   16582             :  * 
   16583             :  *     result = malloc(size)
   16584             :  */
   16585           0 :   __pyx_v_size = __pyx_memoryview_slice_get_size(__pyx_v_src, __pyx_v_ndim);
   16586             : 
   16587             :   /* "View.MemoryView":1219
   16588             :  *     cdef size_t size = slice_get_size(src, ndim)
   16589             :  * 
   16590             :  *     result = malloc(size)             # <<<<<<<<<<<<<<
   16591             :  *     if not result:
   16592             :  *         _err_no_memory()
   16593             :  */
   16594           0 :   __pyx_v_result = malloc(__pyx_v_size);
   16595             : 
   16596             :   /* "View.MemoryView":1220
   16597             :  * 
   16598             :  *     result = malloc(size)
   16599             :  *     if not result:             # <<<<<<<<<<<<<<
   16600             :  *         _err_no_memory()
   16601             :  * 
   16602             :  */
   16603           0 :   __pyx_t_2 = (!(__pyx_v_result != 0));
   16604           0 :   if (__pyx_t_2) {
   16605             : 
   16606             :     /* "View.MemoryView":1221
   16607             :  *     result = malloc(size)
   16608             :  *     if not result:
   16609             :  *         _err_no_memory()             # <<<<<<<<<<<<<<
   16610             :  * 
   16611             :  * 
   16612             :  */
   16613           0 :     __pyx_t_3 = __pyx_memoryview_err_no_memory(); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(1, 1221, __pyx_L1_error)
   16614             : 
   16615             :     /* "View.MemoryView":1220
   16616             :  * 
   16617             :  *     result = malloc(size)
   16618             :  *     if not result:             # <<<<<<<<<<<<<<
   16619             :  *         _err_no_memory()
   16620             :  * 
   16621             :  */
   16622             :   }
   16623             : 
   16624             :   /* "View.MemoryView":1224
   16625             :  * 
   16626             :  * 
   16627             :  *     tmpslice.data = <char *> result             # <<<<<<<<<<<<<<
   16628             :  *     tmpslice.memview = src.memview
   16629             :  *     for i in range(ndim):
   16630             :  */
   16631           0 :   __pyx_v_tmpslice->data = ((char *)__pyx_v_result);
   16632             : 
   16633             :   /* "View.MemoryView":1225
   16634             :  * 
   16635             :  *     tmpslice.data = <char *> result
   16636             :  *     tmpslice.memview = src.memview             # <<<<<<<<<<<<<<
   16637             :  *     for i in range(ndim):
   16638             :  *         tmpslice.shape[i] = src.shape[i]
   16639             :  */
   16640           0 :   __pyx_t_4 = __pyx_v_src->memview;
   16641           0 :   __pyx_v_tmpslice->memview = __pyx_t_4;
   16642             : 
   16643             :   /* "View.MemoryView":1226
   16644             :  *     tmpslice.data = <char *> result
   16645             :  *     tmpslice.memview = src.memview
   16646             :  *     for i in range(ndim):             # <<<<<<<<<<<<<<
   16647             :  *         tmpslice.shape[i] = src.shape[i]
   16648             :  *         tmpslice.suboffsets[i] = -1
   16649             :  */
   16650           0 :   __pyx_t_3 = __pyx_v_ndim;
   16651           0 :   __pyx_t_5 = __pyx_t_3;
   16652           0 :   for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
   16653           0 :     __pyx_v_i = __pyx_t_6;
   16654             : 
   16655             :     /* "View.MemoryView":1227
   16656             :  *     tmpslice.memview = src.memview
   16657             :  *     for i in range(ndim):
   16658             :  *         tmpslice.shape[i] = src.shape[i]             # <<<<<<<<<<<<<<
   16659             :  *         tmpslice.suboffsets[i] = -1
   16660             :  * 
   16661             :  */
   16662           0 :     (__pyx_v_tmpslice->shape[__pyx_v_i]) = (__pyx_v_src->shape[__pyx_v_i]);
   16663             : 
   16664             :     /* "View.MemoryView":1228
   16665             :  *     for i in range(ndim):
   16666             :  *         tmpslice.shape[i] = src.shape[i]
   16667             :  *         tmpslice.suboffsets[i] = -1             # <<<<<<<<<<<<<<
   16668             :  * 
   16669             :  *     fill_contig_strides_array(&tmpslice.shape[0], &tmpslice.strides[0], itemsize, ndim, order)
   16670             :  */
   16671           0 :     (__pyx_v_tmpslice->suboffsets[__pyx_v_i]) = -1L;
   16672             :   }
   16673             : 
   16674             :   /* "View.MemoryView":1230
   16675             :  *         tmpslice.suboffsets[i] = -1
   16676             :  * 
   16677             :  *     fill_contig_strides_array(&tmpslice.shape[0], &tmpslice.strides[0], itemsize, ndim, order)             # <<<<<<<<<<<<<<
   16678             :  * 
   16679             :  * 
   16680             :  */
   16681           0 :   (void)(__pyx_fill_contig_strides_array((&(__pyx_v_tmpslice->shape[0])), (&(__pyx_v_tmpslice->strides[0])), __pyx_v_itemsize, __pyx_v_ndim, __pyx_v_order));
   16682             : 
   16683             :   /* "View.MemoryView":1233
   16684             :  * 
   16685             :  * 
   16686             :  *     for i in range(ndim):             # <<<<<<<<<<<<<<
   16687             :  *         if tmpslice.shape[i] == 1:
   16688             :  *             tmpslice.strides[i] = 0
   16689             :  */
   16690           0 :   __pyx_t_3 = __pyx_v_ndim;
   16691           0 :   __pyx_t_5 = __pyx_t_3;
   16692           0 :   for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
   16693           0 :     __pyx_v_i = __pyx_t_6;
   16694             : 
   16695             :     /* "View.MemoryView":1234
   16696             :  * 
   16697             :  *     for i in range(ndim):
   16698             :  *         if tmpslice.shape[i] == 1:             # <<<<<<<<<<<<<<
   16699             :  *             tmpslice.strides[i] = 0
   16700             :  * 
   16701             :  */
   16702           0 :     __pyx_t_2 = ((__pyx_v_tmpslice->shape[__pyx_v_i]) == 1);
   16703           0 :     if (__pyx_t_2) {
   16704             : 
   16705             :       /* "View.MemoryView":1235
   16706             :  *     for i in range(ndim):
   16707             :  *         if tmpslice.shape[i] == 1:
   16708             :  *             tmpslice.strides[i] = 0             # <<<<<<<<<<<<<<
   16709             :  * 
   16710             :  *     if slice_is_contig(src[0], order, ndim):
   16711             :  */
   16712           0 :       (__pyx_v_tmpslice->strides[__pyx_v_i]) = 0;
   16713             : 
   16714             :       /* "View.MemoryView":1234
   16715             :  * 
   16716             :  *     for i in range(ndim):
   16717             :  *         if tmpslice.shape[i] == 1:             # <<<<<<<<<<<<<<
   16718             :  *             tmpslice.strides[i] = 0
   16719             :  * 
   16720             :  */
   16721             :     }
   16722             :   }
   16723             : 
   16724             :   /* "View.MemoryView":1237
   16725             :  *             tmpslice.strides[i] = 0
   16726             :  * 
   16727             :  *     if slice_is_contig(src[0], order, ndim):             # <<<<<<<<<<<<<<
   16728             :  *         memcpy(result, src.data, size)
   16729             :  *     else:
   16730             :  */
   16731           0 :   __pyx_t_2 = __pyx_memviewslice_is_contig((__pyx_v_src[0]), __pyx_v_order, __pyx_v_ndim);
   16732           0 :   if (__pyx_t_2) {
   16733             : 
   16734             :     /* "View.MemoryView":1238
   16735             :  * 
   16736             :  *     if slice_is_contig(src[0], order, ndim):
   16737             :  *         memcpy(result, src.data, size)             # <<<<<<<<<<<<<<
   16738             :  *     else:
   16739             :  *         copy_strided_to_strided(src, tmpslice, ndim, itemsize)
   16740             :  */
   16741           0 :     (void)(memcpy(__pyx_v_result, __pyx_v_src->data, __pyx_v_size));
   16742             : 
   16743             :     /* "View.MemoryView":1237
   16744             :  *             tmpslice.strides[i] = 0
   16745             :  * 
   16746             :  *     if slice_is_contig(src[0], order, ndim):             # <<<<<<<<<<<<<<
   16747             :  *         memcpy(result, src.data, size)
   16748             :  *     else:
   16749             :  */
   16750           0 :     goto __pyx_L9;
   16751             :   }
   16752             : 
   16753             :   /* "View.MemoryView":1240
   16754             :  *         memcpy(result, src.data, size)
   16755             :  *     else:
   16756             :  *         copy_strided_to_strided(src, tmpslice, ndim, itemsize)             # <<<<<<<<<<<<<<
   16757             :  * 
   16758             :  *     return result
   16759             :  */
   16760             :   /*else*/ {
   16761           0 :     copy_strided_to_strided(__pyx_v_src, __pyx_v_tmpslice, __pyx_v_ndim, __pyx_v_itemsize);
   16762             :   }
   16763           0 :   __pyx_L9:;
   16764             : 
   16765             :   /* "View.MemoryView":1242
   16766             :  *         copy_strided_to_strided(src, tmpslice, ndim, itemsize)
   16767             :  * 
   16768             :  *     return result             # <<<<<<<<<<<<<<
   16769             :  * 
   16770             :  * 
   16771             :  */
   16772           0 :   __pyx_r = __pyx_v_result;
   16773           0 :   goto __pyx_L0;
   16774             : 
   16775             :   /* "View.MemoryView":1205
   16776             :  * 
   16777             :  * @cname('__pyx_memoryview_copy_data_to_temp')
   16778             :  * cdef void *copy_data_to_temp(__Pyx_memviewslice *src,             # <<<<<<<<<<<<<<
   16779             :  *                              __Pyx_memviewslice *tmpslice,
   16780             :  *                              char order,
   16781             :  */
   16782             : 
   16783             :   /* function exit code */
   16784           0 :   __pyx_L1_error:;
   16785             :   #ifdef WITH_THREAD
   16786           0 :   __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   16787             :   #endif
   16788           0 :   __Pyx_AddTraceback("View.MemoryView.copy_data_to_temp", __pyx_clineno, __pyx_lineno, __pyx_filename);
   16789           0 :   __pyx_r = NULL;
   16790             :   #ifdef WITH_THREAD
   16791           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   16792             :   #endif
   16793           0 :   __pyx_L0:;
   16794           0 :   return __pyx_r;
   16795             : }
   16796             : 
   16797             : /* "View.MemoryView":1247
   16798             :  * 
   16799             :  * @cname('__pyx_memoryview_err_extents')
   16800             :  * cdef int _err_extents(int i, Py_ssize_t extent1,             # <<<<<<<<<<<<<<
   16801             :  *                              Py_ssize_t extent2) except -1 with gil:
   16802             :  *     raise ValueError, f"got differing extents in dimension {i} (got {extent1} and {extent2})"
   16803             :  */
   16804             : 
   16805           0 : static int __pyx_memoryview_err_extents(int __pyx_v_i, Py_ssize_t __pyx_v_extent1, Py_ssize_t __pyx_v_extent2) {
   16806           0 :   int __pyx_r;
   16807             :   __Pyx_RefNannyDeclarations
   16808           0 :   PyObject *__pyx_t_1 = NULL;
   16809           0 :   Py_ssize_t __pyx_t_2;
   16810           0 :   Py_UCS4 __pyx_t_3;
   16811           0 :   PyObject *__pyx_t_4 = NULL;
   16812           0 :   int __pyx_lineno = 0;
   16813           0 :   const char *__pyx_filename = NULL;
   16814           0 :   int __pyx_clineno = 0;
   16815             :   #ifdef WITH_THREAD
   16816           0 :   PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   16817             :   #endif
   16818           0 :   __Pyx_RefNannySetupContext("_err_extents", 0);
   16819             : 
   16820             :   /* "View.MemoryView":1249
   16821             :  * cdef int _err_extents(int i, Py_ssize_t extent1,
   16822             :  *                              Py_ssize_t extent2) except -1 with gil:
   16823             :  *     raise ValueError, f"got differing extents in dimension {i} (got {extent1} and {extent2})"             # <<<<<<<<<<<<<<
   16824             :  * 
   16825             :  * @cname('__pyx_memoryview_err_dim')
   16826             :  */
   16827           0 :   __pyx_t_1 = PyTuple_New(7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1249, __pyx_L1_error)
   16828           0 :   __Pyx_GOTREF(__pyx_t_1);
   16829           0 :   __pyx_t_2 = 0;
   16830           0 :   __pyx_t_3 = 127;
   16831           0 :   __Pyx_INCREF(__pyx_kp_u_got_differing_extents_in_dimensi);
   16832           0 :   __pyx_t_2 += 35;
   16833           0 :   __Pyx_GIVEREF(__pyx_kp_u_got_differing_extents_in_dimensi);
   16834           0 :   PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_kp_u_got_differing_extents_in_dimensi);
   16835           0 :   __pyx_t_4 = __Pyx_PyUnicode_From_int(__pyx_v_i, 0, ' ', 'd'); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1249, __pyx_L1_error)
   16836           0 :   __Pyx_GOTREF(__pyx_t_4);
   16837           0 :   __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4);
   16838           0 :   __Pyx_GIVEREF(__pyx_t_4);
   16839           0 :   PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_4);
   16840           0 :   __pyx_t_4 = 0;
   16841           0 :   __Pyx_INCREF(__pyx_kp_u_got);
   16842           0 :   __pyx_t_2 += 6;
   16843           0 :   __Pyx_GIVEREF(__pyx_kp_u_got);
   16844           0 :   PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_kp_u_got);
   16845           0 :   __pyx_t_4 = __Pyx_PyUnicode_From_Py_ssize_t(__pyx_v_extent1, 0, ' ', 'd'); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1249, __pyx_L1_error)
   16846           0 :   __Pyx_GOTREF(__pyx_t_4);
   16847           0 :   __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4);
   16848           0 :   __Pyx_GIVEREF(__pyx_t_4);
   16849           0 :   PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_t_4);
   16850           0 :   __pyx_t_4 = 0;
   16851           0 :   __Pyx_INCREF(__pyx_kp_u_and);
   16852           0 :   __pyx_t_2 += 5;
   16853           0 :   __Pyx_GIVEREF(__pyx_kp_u_and);
   16854           0 :   PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_kp_u_and);
   16855           0 :   __pyx_t_4 = __Pyx_PyUnicode_From_Py_ssize_t(__pyx_v_extent2, 0, ' ', 'd'); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1249, __pyx_L1_error)
   16856           0 :   __Pyx_GOTREF(__pyx_t_4);
   16857           0 :   __pyx_t_2 += __Pyx_PyUnicode_GET_LENGTH(__pyx_t_4);
   16858           0 :   __Pyx_GIVEREF(__pyx_t_4);
   16859           0 :   PyTuple_SET_ITEM(__pyx_t_1, 5, __pyx_t_4);
   16860           0 :   __pyx_t_4 = 0;
   16861           0 :   __Pyx_INCREF(__pyx_kp_u__7);
   16862           0 :   __pyx_t_2 += 1;
   16863           0 :   __Pyx_GIVEREF(__pyx_kp_u__7);
   16864           0 :   PyTuple_SET_ITEM(__pyx_t_1, 6, __pyx_kp_u__7);
   16865           0 :   __pyx_t_4 = __Pyx_PyUnicode_Join(__pyx_t_1, 7, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 1249, __pyx_L1_error)
   16866           0 :   __Pyx_GOTREF(__pyx_t_4);
   16867           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   16868           0 :   __Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_4, 0, 0);
   16869           0 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   16870           0 :   __PYX_ERR(1, 1249, __pyx_L1_error)
   16871             : 
   16872             :   /* "View.MemoryView":1247
   16873             :  * 
   16874             :  * @cname('__pyx_memoryview_err_extents')
   16875             :  * cdef int _err_extents(int i, Py_ssize_t extent1,             # <<<<<<<<<<<<<<
   16876             :  *                              Py_ssize_t extent2) except -1 with gil:
   16877             :  *     raise ValueError, f"got differing extents in dimension {i} (got {extent1} and {extent2})"
   16878             :  */
   16879             : 
   16880             :   /* function exit code */
   16881           0 :   __pyx_L1_error:;
   16882           0 :   __Pyx_XDECREF(__pyx_t_1);
   16883           0 :   __Pyx_XDECREF(__pyx_t_4);
   16884           0 :   __Pyx_AddTraceback("View.MemoryView._err_extents", __pyx_clineno, __pyx_lineno, __pyx_filename);
   16885           0 :   __pyx_r = -1;
   16886           0 :   __Pyx_RefNannyFinishContext();
   16887             :   #ifdef WITH_THREAD
   16888           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   16889             :   #endif
   16890           0 :   return __pyx_r;
   16891             : }
   16892             : 
   16893             : /* "View.MemoryView":1252
   16894             :  * 
   16895             :  * @cname('__pyx_memoryview_err_dim')
   16896             :  * cdef int _err_dim(PyObject *error, str msg, int dim) except -1 with gil:             # <<<<<<<<<<<<<<
   16897             :  *     raise <object>error, msg % dim
   16898             :  * 
   16899             :  */
   16900             : 
   16901           0 : static int __pyx_memoryview_err_dim(PyObject *__pyx_v_error, PyObject *__pyx_v_msg, int __pyx_v_dim) {
   16902           0 :   int __pyx_r;
   16903             :   __Pyx_RefNannyDeclarations
   16904           0 :   PyObject *__pyx_t_1 = NULL;
   16905           0 :   PyObject *__pyx_t_2 = NULL;
   16906           0 :   int __pyx_lineno = 0;
   16907           0 :   const char *__pyx_filename = NULL;
   16908           0 :   int __pyx_clineno = 0;
   16909             :   #ifdef WITH_THREAD
   16910           0 :   PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   16911             :   #endif
   16912           0 :   __Pyx_RefNannySetupContext("_err_dim", 0);
   16913           0 :   __Pyx_INCREF(__pyx_v_msg);
   16914             : 
   16915             :   /* "View.MemoryView":1253
   16916             :  * @cname('__pyx_memoryview_err_dim')
   16917             :  * cdef int _err_dim(PyObject *error, str msg, int dim) except -1 with gil:
   16918             :  *     raise <object>error, msg % dim             # <<<<<<<<<<<<<<
   16919             :  * 
   16920             :  * @cname('__pyx_memoryview_err')
   16921             :  */
   16922           0 :   __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_dim); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1253, __pyx_L1_error)
   16923           0 :   __Pyx_GOTREF(__pyx_t_1);
   16924           0 :   __pyx_t_2 = __Pyx_PyString_FormatSafe(__pyx_v_msg, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 1253, __pyx_L1_error)
   16925           0 :   __Pyx_GOTREF(__pyx_t_2);
   16926           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   16927           0 :   __Pyx_Raise(((PyObject *)__pyx_v_error), __pyx_t_2, 0, 0);
   16928           0 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   16929           0 :   __PYX_ERR(1, 1253, __pyx_L1_error)
   16930             : 
   16931             :   /* "View.MemoryView":1252
   16932             :  * 
   16933             :  * @cname('__pyx_memoryview_err_dim')
   16934             :  * cdef int _err_dim(PyObject *error, str msg, int dim) except -1 with gil:             # <<<<<<<<<<<<<<
   16935             :  *     raise <object>error, msg % dim
   16936             :  * 
   16937             :  */
   16938             : 
   16939             :   /* function exit code */
   16940           0 :   __pyx_L1_error:;
   16941           0 :   __Pyx_XDECREF(__pyx_t_1);
   16942           0 :   __Pyx_XDECREF(__pyx_t_2);
   16943           0 :   __Pyx_AddTraceback("View.MemoryView._err_dim", __pyx_clineno, __pyx_lineno, __pyx_filename);
   16944           0 :   __pyx_r = -1;
   16945           0 :   __Pyx_XDECREF(__pyx_v_msg);
   16946           0 :   __Pyx_RefNannyFinishContext();
   16947             :   #ifdef WITH_THREAD
   16948           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   16949             :   #endif
   16950           0 :   return __pyx_r;
   16951             : }
   16952             : 
   16953             : /* "View.MemoryView":1256
   16954             :  * 
   16955             :  * @cname('__pyx_memoryview_err')
   16956             :  * cdef int _err(PyObject *error, str msg) except -1 with gil:             # <<<<<<<<<<<<<<
   16957             :  *     raise <object>error, msg
   16958             :  * 
   16959             :  */
   16960             : 
   16961           0 : static int __pyx_memoryview_err(PyObject *__pyx_v_error, PyObject *__pyx_v_msg) {
   16962           0 :   int __pyx_r;
   16963             :   __Pyx_RefNannyDeclarations
   16964           0 :   int __pyx_lineno = 0;
   16965           0 :   const char *__pyx_filename = NULL;
   16966           0 :   int __pyx_clineno = 0;
   16967             :   #ifdef WITH_THREAD
   16968           0 :   PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   16969             :   #endif
   16970           0 :   __Pyx_RefNannySetupContext("_err", 0);
   16971           0 :   __Pyx_INCREF(__pyx_v_msg);
   16972             : 
   16973             :   /* "View.MemoryView":1257
   16974             :  * @cname('__pyx_memoryview_err')
   16975             :  * cdef int _err(PyObject *error, str msg) except -1 with gil:
   16976             :  *     raise <object>error, msg             # <<<<<<<<<<<<<<
   16977             :  * 
   16978             :  * @cname('__pyx_memoryview_err_no_memory')
   16979             :  */
   16980           0 :   __Pyx_Raise(((PyObject *)__pyx_v_error), __pyx_v_msg, 0, 0);
   16981           0 :   __PYX_ERR(1, 1257, __pyx_L1_error)
   16982             : 
   16983             :   /* "View.MemoryView":1256
   16984             :  * 
   16985             :  * @cname('__pyx_memoryview_err')
   16986             :  * cdef int _err(PyObject *error, str msg) except -1 with gil:             # <<<<<<<<<<<<<<
   16987             :  *     raise <object>error, msg
   16988             :  * 
   16989             :  */
   16990             : 
   16991             :   /* function exit code */
   16992           0 :   __pyx_L1_error:;
   16993           0 :   __Pyx_AddTraceback("View.MemoryView._err", __pyx_clineno, __pyx_lineno, __pyx_filename);
   16994           0 :   __pyx_r = -1;
   16995           0 :   __Pyx_XDECREF(__pyx_v_msg);
   16996           0 :   __Pyx_RefNannyFinishContext();
   16997             :   #ifdef WITH_THREAD
   16998           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   16999             :   #endif
   17000           0 :   return __pyx_r;
   17001             : }
   17002             : 
   17003             : /* "View.MemoryView":1260
   17004             :  * 
   17005             :  * @cname('__pyx_memoryview_err_no_memory')
   17006             :  * cdef int _err_no_memory() except -1 with gil:             # <<<<<<<<<<<<<<
   17007             :  *     raise MemoryError
   17008             :  * 
   17009             :  */
   17010             : 
   17011           0 : static int __pyx_memoryview_err_no_memory(void) {
   17012           0 :   int __pyx_r;
   17013           0 :   int __pyx_lineno = 0;
   17014           0 :   const char *__pyx_filename = NULL;
   17015           0 :   int __pyx_clineno = 0;
   17016             :   #ifdef WITH_THREAD
   17017           0 :   PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   17018             :   #endif
   17019             : 
   17020             :   /* "View.MemoryView":1261
   17021             :  * @cname('__pyx_memoryview_err_no_memory')
   17022             :  * cdef int _err_no_memory() except -1 with gil:
   17023             :  *     raise MemoryError             # <<<<<<<<<<<<<<
   17024             :  * 
   17025             :  * 
   17026             :  */
   17027           0 :   PyErr_NoMemory(); __PYX_ERR(1, 1261, __pyx_L1_error)
   17028             : 
   17029             :   /* "View.MemoryView":1260
   17030             :  * 
   17031             :  * @cname('__pyx_memoryview_err_no_memory')
   17032             :  * cdef int _err_no_memory() except -1 with gil:             # <<<<<<<<<<<<<<
   17033             :  *     raise MemoryError
   17034             :  * 
   17035             :  */
   17036             : 
   17037             :   /* function exit code */
   17038           0 :   __pyx_L1_error:;
   17039           0 :   __Pyx_AddTraceback("View.MemoryView._err_no_memory", __pyx_clineno, __pyx_lineno, __pyx_filename);
   17040           0 :   __pyx_r = -1;
   17041             :   #ifdef WITH_THREAD
   17042           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   17043             :   #endif
   17044           0 :   return __pyx_r;
   17045             : }
   17046             : 
   17047             : /* "View.MemoryView":1265
   17048             :  * 
   17049             :  * @cname('__pyx_memoryview_copy_contents')
   17050             :  * cdef int memoryview_copy_contents(__Pyx_memviewslice src,             # <<<<<<<<<<<<<<
   17051             :  *                                   __Pyx_memviewslice dst,
   17052             :  *                                   int src_ndim, int dst_ndim,
   17053             :  */
   17054             : 
   17055           0 : static int __pyx_memoryview_copy_contents(__Pyx_memviewslice __pyx_v_src, __Pyx_memviewslice __pyx_v_dst, int __pyx_v_src_ndim, int __pyx_v_dst_ndim, int __pyx_v_dtype_is_object) {
   17056           0 :   void *__pyx_v_tmpdata;
   17057           0 :   size_t __pyx_v_itemsize;
   17058           0 :   int __pyx_v_i;
   17059           0 :   char __pyx_v_order;
   17060           0 :   int __pyx_v_broadcasting;
   17061           0 :   int __pyx_v_direct_copy;
   17062           0 :   __Pyx_memviewslice __pyx_v_tmp;
   17063           0 :   int __pyx_v_ndim;
   17064           0 :   int __pyx_r;
   17065           0 :   Py_ssize_t __pyx_t_1;
   17066           0 :   int __pyx_t_2;
   17067           0 :   int __pyx_t_3;
   17068           0 :   int __pyx_t_4;
   17069           0 :   int __pyx_t_5;
   17070           0 :   int __pyx_t_6;
   17071           0 :   void *__pyx_t_7;
   17072           0 :   int __pyx_lineno = 0;
   17073           0 :   const char *__pyx_filename = NULL;
   17074           0 :   int __pyx_clineno = 0;
   17075             :   #ifdef WITH_THREAD
   17076           0 :   PyGILState_STATE __pyx_gilstate_save;
   17077             :   #endif
   17078             : 
   17079             :   /* "View.MemoryView":1273
   17080             :  *     Check for overlapping memory and verify the shapes.
   17081             :  *     """
   17082             :  *     cdef void *tmpdata = NULL             # <<<<<<<<<<<<<<
   17083             :  *     cdef size_t itemsize = src.memview.view.itemsize
   17084             :  *     cdef int i
   17085             :  */
   17086           0 :   __pyx_v_tmpdata = NULL;
   17087             : 
   17088             :   /* "View.MemoryView":1274
   17089             :  *     """
   17090             :  *     cdef void *tmpdata = NULL
   17091             :  *     cdef size_t itemsize = src.memview.view.itemsize             # <<<<<<<<<<<<<<
   17092             :  *     cdef int i
   17093             :  *     cdef char order = get_best_order(&src, src_ndim)
   17094             :  */
   17095           0 :   __pyx_t_1 = __pyx_v_src.memview->view.itemsize;
   17096           0 :   __pyx_v_itemsize = __pyx_t_1;
   17097             : 
   17098             :   /* "View.MemoryView":1276
   17099             :  *     cdef size_t itemsize = src.memview.view.itemsize
   17100             :  *     cdef int i
   17101             :  *     cdef char order = get_best_order(&src, src_ndim)             # <<<<<<<<<<<<<<
   17102             :  *     cdef bint broadcasting = False
   17103             :  *     cdef bint direct_copy = False
   17104             :  */
   17105           0 :   __pyx_v_order = __pyx_get_best_slice_order((&__pyx_v_src), __pyx_v_src_ndim);
   17106             : 
   17107             :   /* "View.MemoryView":1277
   17108             :  *     cdef int i
   17109             :  *     cdef char order = get_best_order(&src, src_ndim)
   17110             :  *     cdef bint broadcasting = False             # <<<<<<<<<<<<<<
   17111             :  *     cdef bint direct_copy = False
   17112             :  *     cdef __Pyx_memviewslice tmp
   17113             :  */
   17114           0 :   __pyx_v_broadcasting = 0;
   17115             : 
   17116             :   /* "View.MemoryView":1278
   17117             :  *     cdef char order = get_best_order(&src, src_ndim)
   17118             :  *     cdef bint broadcasting = False
   17119             :  *     cdef bint direct_copy = False             # <<<<<<<<<<<<<<
   17120             :  *     cdef __Pyx_memviewslice tmp
   17121             :  * 
   17122             :  */
   17123           0 :   __pyx_v_direct_copy = 0;
   17124             : 
   17125             :   /* "View.MemoryView":1281
   17126             :  *     cdef __Pyx_memviewslice tmp
   17127             :  * 
   17128             :  *     if src_ndim < dst_ndim:             # <<<<<<<<<<<<<<
   17129             :  *         broadcast_leading(&src, src_ndim, dst_ndim)
   17130             :  *     elif dst_ndim < src_ndim:
   17131             :  */
   17132           0 :   __pyx_t_2 = (__pyx_v_src_ndim < __pyx_v_dst_ndim);
   17133           0 :   if (__pyx_t_2) {
   17134             : 
   17135             :     /* "View.MemoryView":1282
   17136             :  * 
   17137             :  *     if src_ndim < dst_ndim:
   17138             :  *         broadcast_leading(&src, src_ndim, dst_ndim)             # <<<<<<<<<<<<<<
   17139             :  *     elif dst_ndim < src_ndim:
   17140             :  *         broadcast_leading(&dst, dst_ndim, src_ndim)
   17141             :  */
   17142           0 :     __pyx_memoryview_broadcast_leading((&__pyx_v_src), __pyx_v_src_ndim, __pyx_v_dst_ndim);
   17143             : 
   17144             :     /* "View.MemoryView":1281
   17145             :  *     cdef __Pyx_memviewslice tmp
   17146             :  * 
   17147             :  *     if src_ndim < dst_ndim:             # <<<<<<<<<<<<<<
   17148             :  *         broadcast_leading(&src, src_ndim, dst_ndim)
   17149             :  *     elif dst_ndim < src_ndim:
   17150             :  */
   17151           0 :     goto __pyx_L3;
   17152             :   }
   17153             : 
   17154             :   /* "View.MemoryView":1283
   17155             :  *     if src_ndim < dst_ndim:
   17156             :  *         broadcast_leading(&src, src_ndim, dst_ndim)
   17157             :  *     elif dst_ndim < src_ndim:             # <<<<<<<<<<<<<<
   17158             :  *         broadcast_leading(&dst, dst_ndim, src_ndim)
   17159             :  * 
   17160             :  */
   17161           0 :   __pyx_t_2 = (__pyx_v_dst_ndim < __pyx_v_src_ndim);
   17162           0 :   if (__pyx_t_2) {
   17163             : 
   17164             :     /* "View.MemoryView":1284
   17165             :  *         broadcast_leading(&src, src_ndim, dst_ndim)
   17166             :  *     elif dst_ndim < src_ndim:
   17167             :  *         broadcast_leading(&dst, dst_ndim, src_ndim)             # <<<<<<<<<<<<<<
   17168             :  * 
   17169             :  *     cdef int ndim = max(src_ndim, dst_ndim)
   17170             :  */
   17171           0 :     __pyx_memoryview_broadcast_leading((&__pyx_v_dst), __pyx_v_dst_ndim, __pyx_v_src_ndim);
   17172             : 
   17173             :     /* "View.MemoryView":1283
   17174             :  *     if src_ndim < dst_ndim:
   17175             :  *         broadcast_leading(&src, src_ndim, dst_ndim)
   17176             :  *     elif dst_ndim < src_ndim:             # <<<<<<<<<<<<<<
   17177             :  *         broadcast_leading(&dst, dst_ndim, src_ndim)
   17178             :  * 
   17179             :  */
   17180             :   }
   17181           0 :   __pyx_L3:;
   17182             : 
   17183             :   /* "View.MemoryView":1286
   17184             :  *         broadcast_leading(&dst, dst_ndim, src_ndim)
   17185             :  * 
   17186             :  *     cdef int ndim = max(src_ndim, dst_ndim)             # <<<<<<<<<<<<<<
   17187             :  * 
   17188             :  *     for i in range(ndim):
   17189             :  */
   17190           0 :   __pyx_t_3 = __pyx_v_dst_ndim;
   17191           0 :   __pyx_t_4 = __pyx_v_src_ndim;
   17192           0 :   __pyx_t_2 = (__pyx_t_3 > __pyx_t_4);
   17193           0 :   if (__pyx_t_2) {
   17194             :     __pyx_t_5 = __pyx_t_3;
   17195             :   } else {
   17196             :     __pyx_t_5 = __pyx_t_4;
   17197             :   }
   17198           0 :   __pyx_v_ndim = __pyx_t_5;
   17199             : 
   17200             :   /* "View.MemoryView":1288
   17201             :  *     cdef int ndim = max(src_ndim, dst_ndim)
   17202             :  * 
   17203             :  *     for i in range(ndim):             # <<<<<<<<<<<<<<
   17204             :  *         if src.shape[i] != dst.shape[i]:
   17205             :  *             if src.shape[i] == 1:
   17206             :  */
   17207           0 :   __pyx_t_5 = __pyx_v_ndim;
   17208           0 :   __pyx_t_3 = __pyx_t_5;
   17209           0 :   for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   17210           0 :     __pyx_v_i = __pyx_t_4;
   17211             : 
   17212             :     /* "View.MemoryView":1289
   17213             :  * 
   17214             :  *     for i in range(ndim):
   17215             :  *         if src.shape[i] != dst.shape[i]:             # <<<<<<<<<<<<<<
   17216             :  *             if src.shape[i] == 1:
   17217             :  *                 broadcasting = True
   17218             :  */
   17219           0 :     __pyx_t_2 = ((__pyx_v_src.shape[__pyx_v_i]) != (__pyx_v_dst.shape[__pyx_v_i]));
   17220           0 :     if (__pyx_t_2) {
   17221             : 
   17222             :       /* "View.MemoryView":1290
   17223             :  *     for i in range(ndim):
   17224             :  *         if src.shape[i] != dst.shape[i]:
   17225             :  *             if src.shape[i] == 1:             # <<<<<<<<<<<<<<
   17226             :  *                 broadcasting = True
   17227             :  *                 src.strides[i] = 0
   17228             :  */
   17229           0 :       __pyx_t_2 = ((__pyx_v_src.shape[__pyx_v_i]) == 1);
   17230           0 :       if (__pyx_t_2) {
   17231             : 
   17232             :         /* "View.MemoryView":1291
   17233             :  *         if src.shape[i] != dst.shape[i]:
   17234             :  *             if src.shape[i] == 1:
   17235             :  *                 broadcasting = True             # <<<<<<<<<<<<<<
   17236             :  *                 src.strides[i] = 0
   17237             :  *             else:
   17238             :  */
   17239           0 :         __pyx_v_broadcasting = 1;
   17240             : 
   17241             :         /* "View.MemoryView":1292
   17242             :  *             if src.shape[i] == 1:
   17243             :  *                 broadcasting = True
   17244             :  *                 src.strides[i] = 0             # <<<<<<<<<<<<<<
   17245             :  *             else:
   17246             :  *                 _err_extents(i, dst.shape[i], src.shape[i])
   17247             :  */
   17248           0 :         (__pyx_v_src.strides[__pyx_v_i]) = 0;
   17249             : 
   17250             :         /* "View.MemoryView":1290
   17251             :  *     for i in range(ndim):
   17252             :  *         if src.shape[i] != dst.shape[i]:
   17253             :  *             if src.shape[i] == 1:             # <<<<<<<<<<<<<<
   17254             :  *                 broadcasting = True
   17255             :  *                 src.strides[i] = 0
   17256             :  */
   17257           0 :         goto __pyx_L7;
   17258             :       }
   17259             : 
   17260             :       /* "View.MemoryView":1294
   17261             :  *                 src.strides[i] = 0
   17262             :  *             else:
   17263             :  *                 _err_extents(i, dst.shape[i], src.shape[i])             # <<<<<<<<<<<<<<
   17264             :  * 
   17265             :  *         if src.suboffsets[i] >= 0:
   17266             :  */
   17267             :       /*else*/ {
   17268           0 :         __pyx_t_6 = __pyx_memoryview_err_extents(__pyx_v_i, (__pyx_v_dst.shape[__pyx_v_i]), (__pyx_v_src.shape[__pyx_v_i])); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 1294, __pyx_L1_error)
   17269             :       }
   17270           0 :       __pyx_L7:;
   17271             : 
   17272             :       /* "View.MemoryView":1289
   17273             :  * 
   17274             :  *     for i in range(ndim):
   17275             :  *         if src.shape[i] != dst.shape[i]:             # <<<<<<<<<<<<<<
   17276             :  *             if src.shape[i] == 1:
   17277             :  *                 broadcasting = True
   17278             :  */
   17279             :     }
   17280             : 
   17281             :     /* "View.MemoryView":1296
   17282             :  *                 _err_extents(i, dst.shape[i], src.shape[i])
   17283             :  * 
   17284             :  *         if src.suboffsets[i] >= 0:             # <<<<<<<<<<<<<<
   17285             :  *             _err_dim(PyExc_ValueError, "Dimension %d is not direct", i)
   17286             :  * 
   17287             :  */
   17288           0 :     __pyx_t_2 = ((__pyx_v_src.suboffsets[__pyx_v_i]) >= 0);
   17289           0 :     if (__pyx_t_2) {
   17290             : 
   17291             :       /* "View.MemoryView":1297
   17292             :  * 
   17293             :  *         if src.suboffsets[i] >= 0:
   17294             :  *             _err_dim(PyExc_ValueError, "Dimension %d is not direct", i)             # <<<<<<<<<<<<<<
   17295             :  * 
   17296             :  *     if slices_overlap(&src, &dst, ndim, itemsize):
   17297             :  */
   17298           0 :       __pyx_t_6 = __pyx_memoryview_err_dim(PyExc_ValueError, __pyx_kp_s_Dimension_d_is_not_direct, __pyx_v_i); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(1, 1297, __pyx_L1_error)
   17299             : 
   17300             :       /* "View.MemoryView":1296
   17301             :  *                 _err_extents(i, dst.shape[i], src.shape[i])
   17302             :  * 
   17303             :  *         if src.suboffsets[i] >= 0:             # <<<<<<<<<<<<<<
   17304             :  *             _err_dim(PyExc_ValueError, "Dimension %d is not direct", i)
   17305             :  * 
   17306             :  */
   17307             :     }
   17308             :   }
   17309             : 
   17310             :   /* "View.MemoryView":1299
   17311             :  *             _err_dim(PyExc_ValueError, "Dimension %d is not direct", i)
   17312             :  * 
   17313             :  *     if slices_overlap(&src, &dst, ndim, itemsize):             # <<<<<<<<<<<<<<
   17314             :  * 
   17315             :  *         if not slice_is_contig(src, order, ndim):
   17316             :  */
   17317           0 :   __pyx_t_2 = __pyx_slices_overlap((&__pyx_v_src), (&__pyx_v_dst), __pyx_v_ndim, __pyx_v_itemsize);
   17318           0 :   if (__pyx_t_2) {
   17319             : 
   17320             :     /* "View.MemoryView":1301
   17321             :  *     if slices_overlap(&src, &dst, ndim, itemsize):
   17322             :  * 
   17323             :  *         if not slice_is_contig(src, order, ndim):             # <<<<<<<<<<<<<<
   17324             :  *             order = get_best_order(&dst, ndim)
   17325             :  * 
   17326             :  */
   17327           0 :     __pyx_t_2 = (!__pyx_memviewslice_is_contig(__pyx_v_src, __pyx_v_order, __pyx_v_ndim));
   17328           0 :     if (__pyx_t_2) {
   17329             : 
   17330             :       /* "View.MemoryView":1302
   17331             :  * 
   17332             :  *         if not slice_is_contig(src, order, ndim):
   17333             :  *             order = get_best_order(&dst, ndim)             # <<<<<<<<<<<<<<
   17334             :  * 
   17335             :  *         tmpdata = copy_data_to_temp(&src, &tmp, order, ndim)
   17336             :  */
   17337           0 :       __pyx_v_order = __pyx_get_best_slice_order((&__pyx_v_dst), __pyx_v_ndim);
   17338             : 
   17339             :       /* "View.MemoryView":1301
   17340             :  *     if slices_overlap(&src, &dst, ndim, itemsize):
   17341             :  * 
   17342             :  *         if not slice_is_contig(src, order, ndim):             # <<<<<<<<<<<<<<
   17343             :  *             order = get_best_order(&dst, ndim)
   17344             :  * 
   17345             :  */
   17346             :     }
   17347             : 
   17348             :     /* "View.MemoryView":1304
   17349             :  *             order = get_best_order(&dst, ndim)
   17350             :  * 
   17351             :  *         tmpdata = copy_data_to_temp(&src, &tmp, order, ndim)             # <<<<<<<<<<<<<<
   17352             :  *         src = tmp
   17353             :  * 
   17354             :  */
   17355           0 :     __pyx_t_7 = __pyx_memoryview_copy_data_to_temp((&__pyx_v_src), (&__pyx_v_tmp), __pyx_v_order, __pyx_v_ndim); if (unlikely(__pyx_t_7 == ((void *)NULL))) __PYX_ERR(1, 1304, __pyx_L1_error)
   17356           0 :     __pyx_v_tmpdata = __pyx_t_7;
   17357             : 
   17358             :     /* "View.MemoryView":1305
   17359             :  * 
   17360             :  *         tmpdata = copy_data_to_temp(&src, &tmp, order, ndim)
   17361             :  *         src = tmp             # <<<<<<<<<<<<<<
   17362             :  * 
   17363             :  *     if not broadcasting:
   17364             :  */
   17365           0 :     __pyx_v_src = __pyx_v_tmp;
   17366             : 
   17367             :     /* "View.MemoryView":1299
   17368             :  *             _err_dim(PyExc_ValueError, "Dimension %d is not direct", i)
   17369             :  * 
   17370             :  *     if slices_overlap(&src, &dst, ndim, itemsize):             # <<<<<<<<<<<<<<
   17371             :  * 
   17372             :  *         if not slice_is_contig(src, order, ndim):
   17373             :  */
   17374             :   }
   17375             : 
   17376             :   /* "View.MemoryView":1307
   17377             :  *         src = tmp
   17378             :  * 
   17379             :  *     if not broadcasting:             # <<<<<<<<<<<<<<
   17380             :  * 
   17381             :  * 
   17382             :  */
   17383           0 :   __pyx_t_2 = (!__pyx_v_broadcasting);
   17384           0 :   if (__pyx_t_2) {
   17385             : 
   17386             :     /* "View.MemoryView":1310
   17387             :  * 
   17388             :  * 
   17389             :  *         if slice_is_contig(src, 'C', ndim):             # <<<<<<<<<<<<<<
   17390             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)
   17391             :  *         elif slice_is_contig(src, 'F', ndim):
   17392             :  */
   17393           0 :     __pyx_t_2 = __pyx_memviewslice_is_contig(__pyx_v_src, 'C', __pyx_v_ndim);
   17394           0 :     if (__pyx_t_2) {
   17395             : 
   17396             :       /* "View.MemoryView":1311
   17397             :  * 
   17398             :  *         if slice_is_contig(src, 'C', ndim):
   17399             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)             # <<<<<<<<<<<<<<
   17400             :  *         elif slice_is_contig(src, 'F', ndim):
   17401             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)
   17402             :  */
   17403           0 :       __pyx_v_direct_copy = __pyx_memviewslice_is_contig(__pyx_v_dst, 'C', __pyx_v_ndim);
   17404             : 
   17405             :       /* "View.MemoryView":1310
   17406             :  * 
   17407             :  * 
   17408             :  *         if slice_is_contig(src, 'C', ndim):             # <<<<<<<<<<<<<<
   17409             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)
   17410             :  *         elif slice_is_contig(src, 'F', ndim):
   17411             :  */
   17412           0 :       goto __pyx_L12;
   17413             :     }
   17414             : 
   17415             :     /* "View.MemoryView":1312
   17416             :  *         if slice_is_contig(src, 'C', ndim):
   17417             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)
   17418             :  *         elif slice_is_contig(src, 'F', ndim):             # <<<<<<<<<<<<<<
   17419             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)
   17420             :  * 
   17421             :  */
   17422           0 :     __pyx_t_2 = __pyx_memviewslice_is_contig(__pyx_v_src, 'F', __pyx_v_ndim);
   17423           0 :     if (__pyx_t_2) {
   17424             : 
   17425             :       /* "View.MemoryView":1313
   17426             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)
   17427             :  *         elif slice_is_contig(src, 'F', ndim):
   17428             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)             # <<<<<<<<<<<<<<
   17429             :  * 
   17430             :  *         if direct_copy:
   17431             :  */
   17432           0 :       __pyx_v_direct_copy = __pyx_memviewslice_is_contig(__pyx_v_dst, 'F', __pyx_v_ndim);
   17433             : 
   17434             :       /* "View.MemoryView":1312
   17435             :  *         if slice_is_contig(src, 'C', ndim):
   17436             :  *             direct_copy = slice_is_contig(dst, 'C', ndim)
   17437             :  *         elif slice_is_contig(src, 'F', ndim):             # <<<<<<<<<<<<<<
   17438             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)
   17439             :  * 
   17440             :  */
   17441             :     }
   17442           0 :     __pyx_L12:;
   17443             : 
   17444             :     /* "View.MemoryView":1315
   17445             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)
   17446             :  * 
   17447             :  *         if direct_copy:             # <<<<<<<<<<<<<<
   17448             :  * 
   17449             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17450             :  */
   17451           0 :     if (__pyx_v_direct_copy) {
   17452             : 
   17453             :       /* "View.MemoryView":1317
   17454             :  *         if direct_copy:
   17455             :  * 
   17456             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=False)             # <<<<<<<<<<<<<<
   17457             :  *             memcpy(dst.data, src.data, slice_get_size(&src, ndim))
   17458             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17459             :  */
   17460           0 :       __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
   17461             : 
   17462             :       /* "View.MemoryView":1318
   17463             :  * 
   17464             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17465             :  *             memcpy(dst.data, src.data, slice_get_size(&src, ndim))             # <<<<<<<<<<<<<<
   17466             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17467             :  *             free(tmpdata)
   17468             :  */
   17469           0 :       (void)(memcpy(__pyx_v_dst.data, __pyx_v_src.data, __pyx_memoryview_slice_get_size((&__pyx_v_src), __pyx_v_ndim)));
   17470             : 
   17471             :       /* "View.MemoryView":1319
   17472             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17473             :  *             memcpy(dst.data, src.data, slice_get_size(&src, ndim))
   17474             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=True)             # <<<<<<<<<<<<<<
   17475             :  *             free(tmpdata)
   17476             :  *             return 0
   17477             :  */
   17478           0 :       __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
   17479             : 
   17480             :       /* "View.MemoryView":1320
   17481             :  *             memcpy(dst.data, src.data, slice_get_size(&src, ndim))
   17482             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17483             :  *             free(tmpdata)             # <<<<<<<<<<<<<<
   17484             :  *             return 0
   17485             :  * 
   17486             :  */
   17487           0 :       free(__pyx_v_tmpdata);
   17488             : 
   17489             :       /* "View.MemoryView":1321
   17490             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17491             :  *             free(tmpdata)
   17492             :  *             return 0             # <<<<<<<<<<<<<<
   17493             :  * 
   17494             :  *     if order == 'F' == get_best_order(&dst, ndim):
   17495             :  */
   17496           0 :       __pyx_r = 0;
   17497           0 :       goto __pyx_L0;
   17498             : 
   17499             :       /* "View.MemoryView":1315
   17500             :  *             direct_copy = slice_is_contig(dst, 'F', ndim)
   17501             :  * 
   17502             :  *         if direct_copy:             # <<<<<<<<<<<<<<
   17503             :  * 
   17504             :  *             refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17505             :  */
   17506             :     }
   17507             : 
   17508             :     /* "View.MemoryView":1307
   17509             :  *         src = tmp
   17510             :  * 
   17511             :  *     if not broadcasting:             # <<<<<<<<<<<<<<
   17512             :  * 
   17513             :  * 
   17514             :  */
   17515             :   }
   17516             : 
   17517             :   /* "View.MemoryView":1323
   17518             :  *             return 0
   17519             :  * 
   17520             :  *     if order == 'F' == get_best_order(&dst, ndim):             # <<<<<<<<<<<<<<
   17521             :  * 
   17522             :  * 
   17523             :  */
   17524           0 :   __pyx_t_2 = (__pyx_v_order == 'F');
   17525           0 :   if (__pyx_t_2) {
   17526           0 :     __pyx_t_2 = ('F' == __pyx_get_best_slice_order((&__pyx_v_dst), __pyx_v_ndim));
   17527             :   }
   17528           0 :   if (__pyx_t_2) {
   17529             : 
   17530             :     /* "View.MemoryView":1326
   17531             :  * 
   17532             :  * 
   17533             :  *         transpose_memslice(&src)             # <<<<<<<<<<<<<<
   17534             :  *         transpose_memslice(&dst)
   17535             :  * 
   17536             :  */
   17537           0 :     __pyx_t_5 = __pyx_memslice_transpose((&__pyx_v_src)); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 1326, __pyx_L1_error)
   17538             : 
   17539             :     /* "View.MemoryView":1327
   17540             :  * 
   17541             :  *         transpose_memslice(&src)
   17542             :  *         transpose_memslice(&dst)             # <<<<<<<<<<<<<<
   17543             :  * 
   17544             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17545             :  */
   17546           0 :     __pyx_t_5 = __pyx_memslice_transpose((&__pyx_v_dst)); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 1327, __pyx_L1_error)
   17547             : 
   17548             :     /* "View.MemoryView":1323
   17549             :  *             return 0
   17550             :  * 
   17551             :  *     if order == 'F' == get_best_order(&dst, ndim):             # <<<<<<<<<<<<<<
   17552             :  * 
   17553             :  * 
   17554             :  */
   17555             :   }
   17556             : 
   17557             :   /* "View.MemoryView":1329
   17558             :  *         transpose_memslice(&dst)
   17559             :  * 
   17560             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=False)             # <<<<<<<<<<<<<<
   17561             :  *     copy_strided_to_strided(&src, &dst, ndim, itemsize)
   17562             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17563             :  */
   17564           0 :   __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
   17565             : 
   17566             :   /* "View.MemoryView":1330
   17567             :  * 
   17568             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17569             :  *     copy_strided_to_strided(&src, &dst, ndim, itemsize)             # <<<<<<<<<<<<<<
   17570             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17571             :  * 
   17572             :  */
   17573           0 :   copy_strided_to_strided((&__pyx_v_src), (&__pyx_v_dst), __pyx_v_ndim, __pyx_v_itemsize);
   17574             : 
   17575             :   /* "View.MemoryView":1331
   17576             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=False)
   17577             :  *     copy_strided_to_strided(&src, &dst, ndim, itemsize)
   17578             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=True)             # <<<<<<<<<<<<<<
   17579             :  * 
   17580             :  *     free(tmpdata)
   17581             :  */
   17582           0 :   __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
   17583             : 
   17584             :   /* "View.MemoryView":1333
   17585             :  *     refcount_copying(&dst, dtype_is_object, ndim, inc=True)
   17586             :  * 
   17587             :  *     free(tmpdata)             # <<<<<<<<<<<<<<
   17588             :  *     return 0
   17589             :  * 
   17590             :  */
   17591           0 :   free(__pyx_v_tmpdata);
   17592             : 
   17593             :   /* "View.MemoryView":1334
   17594             :  * 
   17595             :  *     free(tmpdata)
   17596             :  *     return 0             # <<<<<<<<<<<<<<
   17597             :  * 
   17598             :  * @cname('__pyx_memoryview_broadcast_leading')
   17599             :  */
   17600           0 :   __pyx_r = 0;
   17601           0 :   goto __pyx_L0;
   17602             : 
   17603             :   /* "View.MemoryView":1265
   17604             :  * 
   17605             :  * @cname('__pyx_memoryview_copy_contents')
   17606             :  * cdef int memoryview_copy_contents(__Pyx_memviewslice src,             # <<<<<<<<<<<<<<
   17607             :  *                                   __Pyx_memviewslice dst,
   17608             :  *                                   int src_ndim, int dst_ndim,
   17609             :  */
   17610             : 
   17611             :   /* function exit code */
   17612           0 :   __pyx_L1_error:;
   17613             :   #ifdef WITH_THREAD
   17614           0 :   __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   17615             :   #endif
   17616           0 :   __Pyx_AddTraceback("View.MemoryView.memoryview_copy_contents", __pyx_clineno, __pyx_lineno, __pyx_filename);
   17617           0 :   __pyx_r = -1;
   17618             :   #ifdef WITH_THREAD
   17619           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   17620             :   #endif
   17621           0 :   __pyx_L0:;
   17622           0 :   return __pyx_r;
   17623             : }
   17624             : 
   17625             : /* "View.MemoryView":1337
   17626             :  * 
   17627             :  * @cname('__pyx_memoryview_broadcast_leading')
   17628             :  * cdef void broadcast_leading(__Pyx_memviewslice *mslice,             # <<<<<<<<<<<<<<
   17629             :  *                             int ndim,
   17630             :  *                             int ndim_other) noexcept nogil:
   17631             :  */
   17632             : 
   17633           0 : static void __pyx_memoryview_broadcast_leading(__Pyx_memviewslice *__pyx_v_mslice, int __pyx_v_ndim, int __pyx_v_ndim_other) {
   17634           0 :   int __pyx_v_i;
   17635           0 :   int __pyx_v_offset;
   17636           0 :   int __pyx_t_1;
   17637           0 :   int __pyx_t_2;
   17638           0 :   int __pyx_t_3;
   17639             : 
   17640             :   /* "View.MemoryView":1341
   17641             :  *                             int ndim_other) noexcept nogil:
   17642             :  *     cdef int i
   17643             :  *     cdef int offset = ndim_other - ndim             # <<<<<<<<<<<<<<
   17644             :  * 
   17645             :  *     for i in range(ndim - 1, -1, -1):
   17646             :  */
   17647           0 :   __pyx_v_offset = (__pyx_v_ndim_other - __pyx_v_ndim);
   17648             : 
   17649             :   /* "View.MemoryView":1343
   17650             :  *     cdef int offset = ndim_other - ndim
   17651             :  * 
   17652             :  *     for i in range(ndim - 1, -1, -1):             # <<<<<<<<<<<<<<
   17653             :  *         mslice.shape[i + offset] = mslice.shape[i]
   17654             :  *         mslice.strides[i + offset] = mslice.strides[i]
   17655             :  */
   17656           0 :   for (__pyx_t_1 = (__pyx_v_ndim - 1); __pyx_t_1 > -1; __pyx_t_1-=1) {
   17657           0 :     __pyx_v_i = __pyx_t_1;
   17658             : 
   17659             :     /* "View.MemoryView":1344
   17660             :  * 
   17661             :  *     for i in range(ndim - 1, -1, -1):
   17662             :  *         mslice.shape[i + offset] = mslice.shape[i]             # <<<<<<<<<<<<<<
   17663             :  *         mslice.strides[i + offset] = mslice.strides[i]
   17664             :  *         mslice.suboffsets[i + offset] = mslice.suboffsets[i]
   17665             :  */
   17666           0 :     (__pyx_v_mslice->shape[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->shape[__pyx_v_i]);
   17667             : 
   17668             :     /* "View.MemoryView":1345
   17669             :  *     for i in range(ndim - 1, -1, -1):
   17670             :  *         mslice.shape[i + offset] = mslice.shape[i]
   17671             :  *         mslice.strides[i + offset] = mslice.strides[i]             # <<<<<<<<<<<<<<
   17672             :  *         mslice.suboffsets[i + offset] = mslice.suboffsets[i]
   17673             :  * 
   17674             :  */
   17675           0 :     (__pyx_v_mslice->strides[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->strides[__pyx_v_i]);
   17676             : 
   17677             :     /* "View.MemoryView":1346
   17678             :  *         mslice.shape[i + offset] = mslice.shape[i]
   17679             :  *         mslice.strides[i + offset] = mslice.strides[i]
   17680             :  *         mslice.suboffsets[i + offset] = mslice.suboffsets[i]             # <<<<<<<<<<<<<<
   17681             :  * 
   17682             :  *     for i in range(offset):
   17683             :  */
   17684           0 :     (__pyx_v_mslice->suboffsets[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->suboffsets[__pyx_v_i]);
   17685             :   }
   17686             : 
   17687             :   /* "View.MemoryView":1348
   17688             :  *         mslice.suboffsets[i + offset] = mslice.suboffsets[i]
   17689             :  * 
   17690             :  *     for i in range(offset):             # <<<<<<<<<<<<<<
   17691             :  *         mslice.shape[i] = 1
   17692             :  *         mslice.strides[i] = mslice.strides[0]
   17693             :  */
   17694           0 :   __pyx_t_1 = __pyx_v_offset;
   17695             :   __pyx_t_2 = __pyx_t_1;
   17696           0 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   17697           0 :     __pyx_v_i = __pyx_t_3;
   17698             : 
   17699             :     /* "View.MemoryView":1349
   17700             :  * 
   17701             :  *     for i in range(offset):
   17702             :  *         mslice.shape[i] = 1             # <<<<<<<<<<<<<<
   17703             :  *         mslice.strides[i] = mslice.strides[0]
   17704             :  *         mslice.suboffsets[i] = -1
   17705             :  */
   17706           0 :     (__pyx_v_mslice->shape[__pyx_v_i]) = 1;
   17707             : 
   17708             :     /* "View.MemoryView":1350
   17709             :  *     for i in range(offset):
   17710             :  *         mslice.shape[i] = 1
   17711             :  *         mslice.strides[i] = mslice.strides[0]             # <<<<<<<<<<<<<<
   17712             :  *         mslice.suboffsets[i] = -1
   17713             :  * 
   17714             :  */
   17715           0 :     (__pyx_v_mslice->strides[__pyx_v_i]) = (__pyx_v_mslice->strides[0]);
   17716             : 
   17717             :     /* "View.MemoryView":1351
   17718             :  *         mslice.shape[i] = 1
   17719             :  *         mslice.strides[i] = mslice.strides[0]
   17720             :  *         mslice.suboffsets[i] = -1             # <<<<<<<<<<<<<<
   17721             :  * 
   17722             :  * 
   17723             :  */
   17724           0 :     (__pyx_v_mslice->suboffsets[__pyx_v_i]) = -1L;
   17725             :   }
   17726             : 
   17727             :   /* "View.MemoryView":1337
   17728             :  * 
   17729             :  * @cname('__pyx_memoryview_broadcast_leading')
   17730             :  * cdef void broadcast_leading(__Pyx_memviewslice *mslice,             # <<<<<<<<<<<<<<
   17731             :  *                             int ndim,
   17732             :  *                             int ndim_other) noexcept nogil:
   17733             :  */
   17734             : 
   17735             :   /* function exit code */
   17736           0 : }
   17737             : 
   17738             : /* "View.MemoryView":1359
   17739             :  * 
   17740             :  * @cname('__pyx_memoryview_refcount_copying')
   17741             :  * cdef void refcount_copying(__Pyx_memviewslice *dst, bint dtype_is_object, int ndim, bint inc) noexcept nogil:             # <<<<<<<<<<<<<<
   17742             :  * 
   17743             :  *     if dtype_is_object:
   17744             :  */
   17745             : 
   17746           0 : static void __pyx_memoryview_refcount_copying(__Pyx_memviewslice *__pyx_v_dst, int __pyx_v_dtype_is_object, int __pyx_v_ndim, int __pyx_v_inc) {
   17747             : 
   17748             :   /* "View.MemoryView":1361
   17749             :  * cdef void refcount_copying(__Pyx_memviewslice *dst, bint dtype_is_object, int ndim, bint inc) noexcept nogil:
   17750             :  * 
   17751             :  *     if dtype_is_object:             # <<<<<<<<<<<<<<
   17752             :  *         refcount_objects_in_slice_with_gil(dst.data, dst.shape, dst.strides, ndim, inc)
   17753             :  * 
   17754             :  */
   17755           0 :   if (__pyx_v_dtype_is_object) {
   17756             : 
   17757             :     /* "View.MemoryView":1362
   17758             :  * 
   17759             :  *     if dtype_is_object:
   17760             :  *         refcount_objects_in_slice_with_gil(dst.data, dst.shape, dst.strides, ndim, inc)             # <<<<<<<<<<<<<<
   17761             :  * 
   17762             :  * @cname('__pyx_memoryview_refcount_objects_in_slice_with_gil')
   17763             :  */
   17764           0 :     __pyx_memoryview_refcount_objects_in_slice_with_gil(__pyx_v_dst->data, __pyx_v_dst->shape, __pyx_v_dst->strides, __pyx_v_ndim, __pyx_v_inc);
   17765             : 
   17766             :     /* "View.MemoryView":1361
   17767             :  * cdef void refcount_copying(__Pyx_memviewslice *dst, bint dtype_is_object, int ndim, bint inc) noexcept nogil:
   17768             :  * 
   17769             :  *     if dtype_is_object:             # <<<<<<<<<<<<<<
   17770             :  *         refcount_objects_in_slice_with_gil(dst.data, dst.shape, dst.strides, ndim, inc)
   17771             :  * 
   17772             :  */
   17773             :   }
   17774             : 
   17775             :   /* "View.MemoryView":1359
   17776             :  * 
   17777             :  * @cname('__pyx_memoryview_refcount_copying')
   17778             :  * cdef void refcount_copying(__Pyx_memviewslice *dst, bint dtype_is_object, int ndim, bint inc) noexcept nogil:             # <<<<<<<<<<<<<<
   17779             :  * 
   17780             :  *     if dtype_is_object:
   17781             :  */
   17782             : 
   17783             :   /* function exit code */
   17784           0 : }
   17785             : 
   17786             : /* "View.MemoryView":1365
   17787             :  * 
   17788             :  * @cname('__pyx_memoryview_refcount_objects_in_slice_with_gil')
   17789             :  * cdef void refcount_objects_in_slice_with_gil(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   17790             :  *                                              Py_ssize_t *strides, int ndim,
   17791             :  *                                              bint inc) noexcept with gil:
   17792             :  */
   17793             : 
   17794           0 : static void __pyx_memoryview_refcount_objects_in_slice_with_gil(char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides, int __pyx_v_ndim, int __pyx_v_inc) {
   17795             :   #ifdef WITH_THREAD
   17796           0 :   PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   17797             :   #endif
   17798             : 
   17799             :   /* "View.MemoryView":1368
   17800             :  *                                              Py_ssize_t *strides, int ndim,
   17801             :  *                                              bint inc) noexcept with gil:
   17802             :  *     refcount_objects_in_slice(data, shape, strides, ndim, inc)             # <<<<<<<<<<<<<<
   17803             :  * 
   17804             :  * @cname('__pyx_memoryview_refcount_objects_in_slice')
   17805             :  */
   17806           0 :   __pyx_memoryview_refcount_objects_in_slice(__pyx_v_data, __pyx_v_shape, __pyx_v_strides, __pyx_v_ndim, __pyx_v_inc);
   17807             : 
   17808             :   /* "View.MemoryView":1365
   17809             :  * 
   17810             :  * @cname('__pyx_memoryview_refcount_objects_in_slice_with_gil')
   17811             :  * cdef void refcount_objects_in_slice_with_gil(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   17812             :  *                                              Py_ssize_t *strides, int ndim,
   17813             :  *                                              bint inc) noexcept with gil:
   17814             :  */
   17815             : 
   17816             :   /* function exit code */
   17817             :   #ifdef WITH_THREAD
   17818           0 :   __Pyx_PyGILState_Release(__pyx_gilstate_save);
   17819             :   #endif
   17820           0 : }
   17821             : 
   17822             : /* "View.MemoryView":1371
   17823             :  * 
   17824             :  * @cname('__pyx_memoryview_refcount_objects_in_slice')
   17825             :  * cdef void refcount_objects_in_slice(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   17826             :  *                                     Py_ssize_t *strides, int ndim, bint inc) noexcept:
   17827             :  *     cdef Py_ssize_t i
   17828             :  */
   17829             : 
   17830           0 : static void __pyx_memoryview_refcount_objects_in_slice(char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides, int __pyx_v_ndim, int __pyx_v_inc) {
   17831           0 :   CYTHON_UNUSED Py_ssize_t __pyx_v_i;
   17832           0 :   Py_ssize_t __pyx_v_stride;
   17833           0 :   Py_ssize_t __pyx_t_1;
   17834           0 :   Py_ssize_t __pyx_t_2;
   17835           0 :   Py_ssize_t __pyx_t_3;
   17836           0 :   int __pyx_t_4;
   17837             : 
   17838             :   /* "View.MemoryView":1374
   17839             :  *                                     Py_ssize_t *strides, int ndim, bint inc) noexcept:
   17840             :  *     cdef Py_ssize_t i
   17841             :  *     cdef Py_ssize_t stride = strides[0]             # <<<<<<<<<<<<<<
   17842             :  * 
   17843             :  *     for i in range(shape[0]):
   17844             :  */
   17845           0 :   __pyx_v_stride = (__pyx_v_strides[0]);
   17846             : 
   17847             :   /* "View.MemoryView":1376
   17848             :  *     cdef Py_ssize_t stride = strides[0]
   17849             :  * 
   17850             :  *     for i in range(shape[0]):             # <<<<<<<<<<<<<<
   17851             :  *         if ndim == 1:
   17852             :  *             if inc:
   17853             :  */
   17854           0 :   __pyx_t_1 = (__pyx_v_shape[0]);
   17855           0 :   __pyx_t_2 = __pyx_t_1;
   17856           0 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   17857           0 :     __pyx_v_i = __pyx_t_3;
   17858             : 
   17859             :     /* "View.MemoryView":1377
   17860             :  * 
   17861             :  *     for i in range(shape[0]):
   17862             :  *         if ndim == 1:             # <<<<<<<<<<<<<<
   17863             :  *             if inc:
   17864             :  *                 Py_INCREF((<PyObject **> data)[0])
   17865             :  */
   17866           0 :     __pyx_t_4 = (__pyx_v_ndim == 1);
   17867           0 :     if (__pyx_t_4) {
   17868             : 
   17869             :       /* "View.MemoryView":1378
   17870             :  *     for i in range(shape[0]):
   17871             :  *         if ndim == 1:
   17872             :  *             if inc:             # <<<<<<<<<<<<<<
   17873             :  *                 Py_INCREF((<PyObject **> data)[0])
   17874             :  *             else:
   17875             :  */
   17876           0 :       if (__pyx_v_inc) {
   17877             : 
   17878             :         /* "View.MemoryView":1379
   17879             :  *         if ndim == 1:
   17880             :  *             if inc:
   17881             :  *                 Py_INCREF((<PyObject **> data)[0])             # <<<<<<<<<<<<<<
   17882             :  *             else:
   17883             :  *                 Py_DECREF((<PyObject **> data)[0])
   17884             :  */
   17885           0 :         Py_INCREF((((PyObject **)__pyx_v_data)[0]));
   17886             : 
   17887             :         /* "View.MemoryView":1378
   17888             :  *     for i in range(shape[0]):
   17889             :  *         if ndim == 1:
   17890             :  *             if inc:             # <<<<<<<<<<<<<<
   17891             :  *                 Py_INCREF((<PyObject **> data)[0])
   17892             :  *             else:
   17893             :  */
   17894           0 :         goto __pyx_L6;
   17895             :       }
   17896             : 
   17897             :       /* "View.MemoryView":1381
   17898             :  *                 Py_INCREF((<PyObject **> data)[0])
   17899             :  *             else:
   17900             :  *                 Py_DECREF((<PyObject **> data)[0])             # <<<<<<<<<<<<<<
   17901             :  *         else:
   17902             :  *             refcount_objects_in_slice(data, shape + 1, strides + 1, ndim - 1, inc)
   17903             :  */
   17904             :       /*else*/ {
   17905           0 :         Py_DECREF((((PyObject **)__pyx_v_data)[0]));
   17906             :       }
   17907           0 :       __pyx_L6:;
   17908             : 
   17909             :       /* "View.MemoryView":1377
   17910             :  * 
   17911             :  *     for i in range(shape[0]):
   17912             :  *         if ndim == 1:             # <<<<<<<<<<<<<<
   17913             :  *             if inc:
   17914             :  *                 Py_INCREF((<PyObject **> data)[0])
   17915             :  */
   17916           0 :       goto __pyx_L5;
   17917             :     }
   17918             : 
   17919             :     /* "View.MemoryView":1383
   17920             :  *                 Py_DECREF((<PyObject **> data)[0])
   17921             :  *         else:
   17922             :  *             refcount_objects_in_slice(data, shape + 1, strides + 1, ndim - 1, inc)             # <<<<<<<<<<<<<<
   17923             :  * 
   17924             :  *         data += stride
   17925             :  */
   17926             :     /*else*/ {
   17927           0 :       __pyx_memoryview_refcount_objects_in_slice(__pyx_v_data, (__pyx_v_shape + 1), (__pyx_v_strides + 1), (__pyx_v_ndim - 1), __pyx_v_inc);
   17928             :     }
   17929           0 :     __pyx_L5:;
   17930             : 
   17931             :     /* "View.MemoryView":1385
   17932             :  *             refcount_objects_in_slice(data, shape + 1, strides + 1, ndim - 1, inc)
   17933             :  * 
   17934             :  *         data += stride             # <<<<<<<<<<<<<<
   17935             :  * 
   17936             :  * 
   17937             :  */
   17938           0 :     __pyx_v_data = (__pyx_v_data + __pyx_v_stride);
   17939             :   }
   17940             : 
   17941             :   /* "View.MemoryView":1371
   17942             :  * 
   17943             :  * @cname('__pyx_memoryview_refcount_objects_in_slice')
   17944             :  * cdef void refcount_objects_in_slice(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   17945             :  *                                     Py_ssize_t *strides, int ndim, bint inc) noexcept:
   17946             :  *     cdef Py_ssize_t i
   17947             :  */
   17948             : 
   17949             :   /* function exit code */
   17950           0 : }
   17951             : 
   17952             : /* "View.MemoryView":1391
   17953             :  * 
   17954             :  * @cname('__pyx_memoryview_slice_assign_scalar')
   17955             :  * cdef void slice_assign_scalar(__Pyx_memviewslice *dst, int ndim,             # <<<<<<<<<<<<<<
   17956             :  *                               size_t itemsize, void *item,
   17957             :  *                               bint dtype_is_object) noexcept nogil:
   17958             :  */
   17959             : 
   17960           0 : static void __pyx_memoryview_slice_assign_scalar(__Pyx_memviewslice *__pyx_v_dst, int __pyx_v_ndim, size_t __pyx_v_itemsize, void *__pyx_v_item, int __pyx_v_dtype_is_object) {
   17961             : 
   17962             :   /* "View.MemoryView":1394
   17963             :  *                               size_t itemsize, void *item,
   17964             :  *                               bint dtype_is_object) noexcept nogil:
   17965             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=False)             # <<<<<<<<<<<<<<
   17966             :  *     _slice_assign_scalar(dst.data, dst.shape, dst.strides, ndim, itemsize, item)
   17967             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=True)
   17968             :  */
   17969           0 :   __pyx_memoryview_refcount_copying(__pyx_v_dst, __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
   17970             : 
   17971             :   /* "View.MemoryView":1395
   17972             :  *                               bint dtype_is_object) noexcept nogil:
   17973             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=False)
   17974             :  *     _slice_assign_scalar(dst.data, dst.shape, dst.strides, ndim, itemsize, item)             # <<<<<<<<<<<<<<
   17975             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=True)
   17976             :  * 
   17977             :  */
   17978           0 :   __pyx_memoryview__slice_assign_scalar(__pyx_v_dst->data, __pyx_v_dst->shape, __pyx_v_dst->strides, __pyx_v_ndim, __pyx_v_itemsize, __pyx_v_item);
   17979             : 
   17980             :   /* "View.MemoryView":1396
   17981             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=False)
   17982             :  *     _slice_assign_scalar(dst.data, dst.shape, dst.strides, ndim, itemsize, item)
   17983             :  *     refcount_copying(dst, dtype_is_object, ndim, inc=True)             # <<<<<<<<<<<<<<
   17984             :  * 
   17985             :  * 
   17986             :  */
   17987           0 :   __pyx_memoryview_refcount_copying(__pyx_v_dst, __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
   17988             : 
   17989             :   /* "View.MemoryView":1391
   17990             :  * 
   17991             :  * @cname('__pyx_memoryview_slice_assign_scalar')
   17992             :  * cdef void slice_assign_scalar(__Pyx_memviewslice *dst, int ndim,             # <<<<<<<<<<<<<<
   17993             :  *                               size_t itemsize, void *item,
   17994             :  *                               bint dtype_is_object) noexcept nogil:
   17995             :  */
   17996             : 
   17997             :   /* function exit code */
   17998           0 : }
   17999             : 
   18000             : /* "View.MemoryView":1400
   18001             :  * 
   18002             :  * @cname('__pyx_memoryview__slice_assign_scalar')
   18003             :  * cdef void _slice_assign_scalar(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   18004             :  *                               Py_ssize_t *strides, int ndim,
   18005             :  *                               size_t itemsize, void *item) noexcept nogil:
   18006             :  */
   18007             : 
   18008           0 : static void __pyx_memoryview__slice_assign_scalar(char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides, int __pyx_v_ndim, size_t __pyx_v_itemsize, void *__pyx_v_item) {
   18009           0 :   CYTHON_UNUSED Py_ssize_t __pyx_v_i;
   18010           0 :   Py_ssize_t __pyx_v_stride;
   18011           0 :   Py_ssize_t __pyx_v_extent;
   18012           0 :   int __pyx_t_1;
   18013           0 :   Py_ssize_t __pyx_t_2;
   18014           0 :   Py_ssize_t __pyx_t_3;
   18015           0 :   Py_ssize_t __pyx_t_4;
   18016             : 
   18017             :   /* "View.MemoryView":1404
   18018             :  *                               size_t itemsize, void *item) noexcept nogil:
   18019             :  *     cdef Py_ssize_t i
   18020             :  *     cdef Py_ssize_t stride = strides[0]             # <<<<<<<<<<<<<<
   18021             :  *     cdef Py_ssize_t extent = shape[0]
   18022             :  * 
   18023             :  */
   18024           0 :   __pyx_v_stride = (__pyx_v_strides[0]);
   18025             : 
   18026             :   /* "View.MemoryView":1405
   18027             :  *     cdef Py_ssize_t i
   18028             :  *     cdef Py_ssize_t stride = strides[0]
   18029             :  *     cdef Py_ssize_t extent = shape[0]             # <<<<<<<<<<<<<<
   18030             :  * 
   18031             :  *     if ndim == 1:
   18032             :  */
   18033           0 :   __pyx_v_extent = (__pyx_v_shape[0]);
   18034             : 
   18035             :   /* "View.MemoryView":1407
   18036             :  *     cdef Py_ssize_t extent = shape[0]
   18037             :  * 
   18038             :  *     if ndim == 1:             # <<<<<<<<<<<<<<
   18039             :  *         for i in range(extent):
   18040             :  *             memcpy(data, item, itemsize)
   18041             :  */
   18042           0 :   __pyx_t_1 = (__pyx_v_ndim == 1);
   18043           0 :   if (__pyx_t_1) {
   18044             : 
   18045             :     /* "View.MemoryView":1408
   18046             :  * 
   18047             :  *     if ndim == 1:
   18048             :  *         for i in range(extent):             # <<<<<<<<<<<<<<
   18049             :  *             memcpy(data, item, itemsize)
   18050             :  *             data += stride
   18051             :  */
   18052             :     __pyx_t_2 = __pyx_v_extent;
   18053             :     __pyx_t_3 = __pyx_t_2;
   18054           0 :     for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   18055           0 :       __pyx_v_i = __pyx_t_4;
   18056             : 
   18057             :       /* "View.MemoryView":1409
   18058             :  *     if ndim == 1:
   18059             :  *         for i in range(extent):
   18060             :  *             memcpy(data, item, itemsize)             # <<<<<<<<<<<<<<
   18061             :  *             data += stride
   18062             :  *     else:
   18063             :  */
   18064           0 :       (void)(memcpy(__pyx_v_data, __pyx_v_item, __pyx_v_itemsize));
   18065             : 
   18066             :       /* "View.MemoryView":1410
   18067             :  *         for i in range(extent):
   18068             :  *             memcpy(data, item, itemsize)
   18069             :  *             data += stride             # <<<<<<<<<<<<<<
   18070             :  *     else:
   18071             :  *         for i in range(extent):
   18072             :  */
   18073           0 :       __pyx_v_data = (__pyx_v_data + __pyx_v_stride);
   18074             :     }
   18075             : 
   18076             :     /* "View.MemoryView":1407
   18077             :  *     cdef Py_ssize_t extent = shape[0]
   18078             :  * 
   18079             :  *     if ndim == 1:             # <<<<<<<<<<<<<<
   18080             :  *         for i in range(extent):
   18081             :  *             memcpy(data, item, itemsize)
   18082             :  */
   18083           0 :     goto __pyx_L3;
   18084             :   }
   18085             : 
   18086             :   /* "View.MemoryView":1412
   18087             :  *             data += stride
   18088             :  *     else:
   18089             :  *         for i in range(extent):             # <<<<<<<<<<<<<<
   18090             :  *             _slice_assign_scalar(data, shape + 1, strides + 1, ndim - 1, itemsize, item)
   18091             :  *             data += stride
   18092             :  */
   18093             :   /*else*/ {
   18094             :     __pyx_t_2 = __pyx_v_extent;
   18095             :     __pyx_t_3 = __pyx_t_2;
   18096           0 :     for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
   18097           0 :       __pyx_v_i = __pyx_t_4;
   18098             : 
   18099             :       /* "View.MemoryView":1413
   18100             :  *     else:
   18101             :  *         for i in range(extent):
   18102             :  *             _slice_assign_scalar(data, shape + 1, strides + 1, ndim - 1, itemsize, item)             # <<<<<<<<<<<<<<
   18103             :  *             data += stride
   18104             :  * 
   18105             :  */
   18106           0 :       __pyx_memoryview__slice_assign_scalar(__pyx_v_data, (__pyx_v_shape + 1), (__pyx_v_strides + 1), (__pyx_v_ndim - 1), __pyx_v_itemsize, __pyx_v_item);
   18107             : 
   18108             :       /* "View.MemoryView":1414
   18109             :  *         for i in range(extent):
   18110             :  *             _slice_assign_scalar(data, shape + 1, strides + 1, ndim - 1, itemsize, item)
   18111             :  *             data += stride             # <<<<<<<<<<<<<<
   18112             :  * 
   18113             :  * 
   18114             :  */
   18115           0 :       __pyx_v_data = (__pyx_v_data + __pyx_v_stride);
   18116             :     }
   18117             :   }
   18118           0 :   __pyx_L3:;
   18119             : 
   18120             :   /* "View.MemoryView":1400
   18121             :  * 
   18122             :  * @cname('__pyx_memoryview__slice_assign_scalar')
   18123             :  * cdef void _slice_assign_scalar(char *data, Py_ssize_t *shape,             # <<<<<<<<<<<<<<
   18124             :  *                               Py_ssize_t *strides, int ndim,
   18125             :  *                               size_t itemsize, void *item) noexcept nogil:
   18126             :  */
   18127             : 
   18128             :   /* function exit code */
   18129           0 : }
   18130             : 
   18131             : /* "(tree fragment)":1
   18132             :  * def __pyx_unpickle_Enum(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
   18133             :  *     cdef object __pyx_PickleError
   18134             :  *     cdef object __pyx_result
   18135             :  */
   18136             : 
   18137             : /* Python wrapper */
   18138             : static PyObject *__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum(PyObject *__pyx_self, 
   18139             : #if CYTHON_METH_FASTCALL
   18140             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   18141             : #else
   18142             : PyObject *__pyx_args, PyObject *__pyx_kwds
   18143             : #endif
   18144             : ); /*proto*/
   18145             : static PyMethodDef __pyx_mdef_15View_dot_MemoryView_1__pyx_unpickle_Enum = {"__pyx_unpickle_Enum", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0};
   18146           0 : static PyObject *__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum(PyObject *__pyx_self, 
   18147             : #if CYTHON_METH_FASTCALL
   18148             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   18149             : #else
   18150             : PyObject *__pyx_args, PyObject *__pyx_kwds
   18151             : #endif
   18152             : ) {
   18153           0 :   PyObject *__pyx_v___pyx_type = 0;
   18154           0 :   long __pyx_v___pyx_checksum;
   18155           0 :   PyObject *__pyx_v___pyx_state = 0;
   18156             :   #if !CYTHON_METH_FASTCALL
   18157             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   18158             :   #endif
   18159           0 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   18160           0 :   PyObject* values[3] = {0,0,0};
   18161           0 :   int __pyx_lineno = 0;
   18162           0 :   const char *__pyx_filename = NULL;
   18163           0 :   int __pyx_clineno = 0;
   18164           0 :   PyObject *__pyx_r = 0;
   18165             :   __Pyx_RefNannyDeclarations
   18166           0 :   __Pyx_RefNannySetupContext("__pyx_unpickle_Enum (wrapper)", 0);
   18167             :   #if !CYTHON_METH_FASTCALL
   18168             :   #if CYTHON_ASSUME_SAFE_MACROS
   18169             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   18170             :   #else
   18171             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   18172             :   #endif
   18173             :   #endif
   18174           0 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   18175             :   {
   18176           0 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
   18177           0 :     if (__pyx_kwds) {
   18178           0 :       Py_ssize_t kw_args;
   18179           0 :       switch (__pyx_nargs) {
   18180           0 :         case  3: values[2] = __Pyx_Arg_FASTCALL(__pyx_args, 2);
   18181           0 :         CYTHON_FALLTHROUGH;
   18182           0 :         case  2: values[1] = __Pyx_Arg_FASTCALL(__pyx_args, 1);
   18183           0 :         CYTHON_FALLTHROUGH;
   18184           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   18185           0 :         CYTHON_FALLTHROUGH;
   18186           0 :         case  0: break;
   18187           0 :         default: goto __pyx_L5_argtuple_error;
   18188             :       }
   18189           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
   18190           0 :       switch (__pyx_nargs) {
   18191           0 :         case  0:
   18192           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_type)) != 0)) {
   18193           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
   18194           0 :           kw_args--;
   18195             :         }
   18196           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
   18197           0 :         else goto __pyx_L5_argtuple_error;
   18198           0 :         CYTHON_FALLTHROUGH;
   18199             :         case  1:
   18200           0 :         if (likely((values[1] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_checksum)) != 0)) {
   18201           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[1]);
   18202           0 :           kw_args--;
   18203             :         }
   18204           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
   18205             :         else {
   18206           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Enum", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
   18207             :         }
   18208           0 :         CYTHON_FALLTHROUGH;
   18209             :         case  2:
   18210           0 :         if (likely((values[2] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_pyx_state)) != 0)) {
   18211           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[2]);
   18212           0 :           kw_args--;
   18213             :         }
   18214           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
   18215             :         else {
   18216           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Enum", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
   18217             :         }
   18218             :       }
   18219           0 :       if (unlikely(kw_args > 0)) {
   18220           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   18221           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__pyx_unpickle_Enum") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
   18222             :       }
   18223           0 :     } else if (unlikely(__pyx_nargs != 3)) {
   18224           0 :       goto __pyx_L5_argtuple_error;
   18225             :     } else {
   18226           0 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   18227           0 :       values[1] = __Pyx_Arg_FASTCALL(__pyx_args, 1);
   18228           0 :       values[2] = __Pyx_Arg_FASTCALL(__pyx_args, 2);
   18229             :     }
   18230           0 :     __pyx_v___pyx_type = values[0];
   18231           0 :     __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
   18232           0 :     __pyx_v___pyx_state = values[2];
   18233             :   }
   18234           0 :   goto __pyx_L6_skip;
   18235           0 :   __pyx_L5_argtuple_error:;
   18236           0 :   __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Enum", 1, 3, 3, __pyx_nargs); __PYX_ERR(1, 1, __pyx_L3_error)
   18237           0 :   __pyx_L6_skip:;
   18238           0 :   goto __pyx_L4_argument_unpacking_done;
   18239           0 :   __pyx_L3_error:;
   18240             :   {
   18241           0 :     Py_ssize_t __pyx_temp;
   18242           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   18243             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   18244             :     }
   18245             :   }
   18246           0 :   __Pyx_AddTraceback("View.MemoryView.__pyx_unpickle_Enum", __pyx_clineno, __pyx_lineno, __pyx_filename);
   18247           0 :   __Pyx_RefNannyFinishContext();
   18248           0 :   return NULL;
   18249           0 :   __pyx_L4_argument_unpacking_done:;
   18250           0 :   __pyx_r = __pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);
   18251             : 
   18252             :   /* function exit code */
   18253             :   {
   18254           0 :     Py_ssize_t __pyx_temp;
   18255           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   18256             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   18257             :     }
   18258             :   }
   18259             :   __Pyx_RefNannyFinishContext();
   18260             :   return __pyx_r;
   18261             : }
   18262             : 
   18263           0 : static PyObject *__pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
   18264           0 :   PyObject *__pyx_v___pyx_PickleError = 0;
   18265           0 :   PyObject *__pyx_v___pyx_result = 0;
   18266           0 :   PyObject *__pyx_r = NULL;
   18267             :   __Pyx_RefNannyDeclarations
   18268           0 :   PyObject *__pyx_t_1 = NULL;
   18269           0 :   int __pyx_t_2;
   18270           0 :   PyObject *__pyx_t_3 = NULL;
   18271           0 :   PyObject *__pyx_t_4 = NULL;
   18272           0 :   unsigned int __pyx_t_5;
   18273           0 :   int __pyx_lineno = 0;
   18274           0 :   const char *__pyx_filename = NULL;
   18275           0 :   int __pyx_clineno = 0;
   18276           0 :   __Pyx_RefNannySetupContext("__pyx_unpickle_Enum", 1);
   18277             : 
   18278             :   /* "(tree fragment)":4
   18279             :  *     cdef object __pyx_PickleError
   18280             :  *     cdef object __pyx_result
   18281             :  *     if __pyx_checksum not in (0x82a3537, 0x6ae9995, 0xb068931):             # <<<<<<<<<<<<<<
   18282             :  *         from pickle import PickleError as __pyx_PickleError
   18283             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18284             :  */
   18285           0 :   __pyx_t_1 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
   18286           0 :   __Pyx_GOTREF(__pyx_t_1);
   18287           0 :   __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_t_1, __pyx_tuple__8, Py_NE)); if (unlikely((__pyx_t_2 < 0))) __PYX_ERR(1, 4, __pyx_L1_error)
   18288           0 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18289           0 :   if (__pyx_t_2) {
   18290             : 
   18291             :     /* "(tree fragment)":5
   18292             :  *     cdef object __pyx_result
   18293             :  *     if __pyx_checksum not in (0x82a3537, 0x6ae9995, 0xb068931):
   18294             :  *         from pickle import PickleError as __pyx_PickleError             # <<<<<<<<<<<<<<
   18295             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18296             :  *     __pyx_result = Enum.__new__(__pyx_type)
   18297             :  */
   18298           0 :     __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 5, __pyx_L1_error)
   18299           0 :     __Pyx_GOTREF(__pyx_t_1);
   18300           0 :     __Pyx_INCREF(__pyx_n_s_PickleError);
   18301           0 :     __Pyx_GIVEREF(__pyx_n_s_PickleError);
   18302           0 :     if (__Pyx_PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_PickleError)) __PYX_ERR(1, 5, __pyx_L1_error);
   18303           0 :     __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_1, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
   18304           0 :     __Pyx_GOTREF(__pyx_t_3);
   18305           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18306           0 :     __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 5, __pyx_L1_error)
   18307           0 :     __Pyx_GOTREF(__pyx_t_1);
   18308           0 :     __Pyx_INCREF(__pyx_t_1);
   18309           0 :     __pyx_v___pyx_PickleError = __pyx_t_1;
   18310           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18311           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   18312             : 
   18313             :     /* "(tree fragment)":6
   18314             :  *     if __pyx_checksum not in (0x82a3537, 0x6ae9995, 0xb068931):
   18315             :  *         from pickle import PickleError as __pyx_PickleError
   18316             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum             # <<<<<<<<<<<<<<
   18317             :  *     __pyx_result = Enum.__new__(__pyx_type)
   18318             :  *     if __pyx_state is not None:
   18319             :  */
   18320           0 :     __pyx_t_3 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 6, __pyx_L1_error)
   18321           0 :     __Pyx_GOTREF(__pyx_t_3);
   18322           0 :     __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_0x_x_vs_0, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
   18323           0 :     __Pyx_GOTREF(__pyx_t_1);
   18324           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   18325           0 :     __Pyx_Raise(__pyx_v___pyx_PickleError, __pyx_t_1, 0, 0);
   18326           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18327           0 :     __PYX_ERR(1, 6, __pyx_L1_error)
   18328             : 
   18329             :     /* "(tree fragment)":4
   18330             :  *     cdef object __pyx_PickleError
   18331             :  *     cdef object __pyx_result
   18332             :  *     if __pyx_checksum not in (0x82a3537, 0x6ae9995, 0xb068931):             # <<<<<<<<<<<<<<
   18333             :  *         from pickle import PickleError as __pyx_PickleError
   18334             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18335             :  */
   18336             :   }
   18337             : 
   18338             :   /* "(tree fragment)":7
   18339             :  *         from pickle import PickleError as __pyx_PickleError
   18340             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18341             :  *     __pyx_result = Enum.__new__(__pyx_type)             # <<<<<<<<<<<<<<
   18342             :  *     if __pyx_state is not None:
   18343             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18344             :  */
   18345           0 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_MemviewEnum_type), __pyx_n_s_new); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
   18346           0 :   __Pyx_GOTREF(__pyx_t_3);
   18347           0 :   __pyx_t_4 = NULL;
   18348           0 :   __pyx_t_5 = 0;
   18349             :   #if CYTHON_UNPACK_METHODS
   18350           0 :   if (likely(PyMethod_Check(__pyx_t_3))) {
   18351           0 :     __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
   18352           0 :     if (likely(__pyx_t_4)) {
   18353           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
   18354           0 :       __Pyx_INCREF(__pyx_t_4);
   18355           0 :       __Pyx_INCREF(function);
   18356           0 :       __Pyx_DECREF_SET(__pyx_t_3, function);
   18357             :       __pyx_t_5 = 1;
   18358             :     }
   18359             :   }
   18360             :   #endif
   18361             :   {
   18362           0 :     PyObject *__pyx_callargs[2] = {__pyx_t_4, __pyx_v___pyx_type};
   18363           0 :     __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_3, __pyx_callargs+1-__pyx_t_5, 1+__pyx_t_5);
   18364           0 :     __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   18365           0 :     if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error)
   18366           0 :     __Pyx_GOTREF(__pyx_t_1);
   18367           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   18368             :   }
   18369           0 :   __pyx_v___pyx_result = __pyx_t_1;
   18370           0 :   __pyx_t_1 = 0;
   18371             : 
   18372             :   /* "(tree fragment)":8
   18373             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18374             :  *     __pyx_result = Enum.__new__(__pyx_type)
   18375             :  *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
   18376             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18377             :  *     return __pyx_result
   18378             :  */
   18379           0 :   __pyx_t_2 = (__pyx_v___pyx_state != Py_None);
   18380           0 :   if (__pyx_t_2) {
   18381             : 
   18382             :     /* "(tree fragment)":9
   18383             :  *     __pyx_result = Enum.__new__(__pyx_type)
   18384             :  *     if __pyx_state is not None:
   18385             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)             # <<<<<<<<<<<<<<
   18386             :  *     return __pyx_result
   18387             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):
   18388             :  */
   18389           0 :     if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None) || __Pyx_RaiseUnexpectedTypeError("tuple", __pyx_v___pyx_state))) __PYX_ERR(1, 9, __pyx_L1_error)
   18390           0 :     __pyx_t_1 = __pyx_unpickle_Enum__set_state(((struct __pyx_MemviewEnum_obj *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 9, __pyx_L1_error)
   18391           0 :     __Pyx_GOTREF(__pyx_t_1);
   18392           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18393             : 
   18394             :     /* "(tree fragment)":8
   18395             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   18396             :  *     __pyx_result = Enum.__new__(__pyx_type)
   18397             :  *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
   18398             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18399             :  *     return __pyx_result
   18400             :  */
   18401             :   }
   18402             : 
   18403             :   /* "(tree fragment)":10
   18404             :  *     if __pyx_state is not None:
   18405             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18406             :  *     return __pyx_result             # <<<<<<<<<<<<<<
   18407             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):
   18408             :  *     __pyx_result.name = __pyx_state[0]
   18409             :  */
   18410           0 :   __Pyx_XDECREF(__pyx_r);
   18411           0 :   __Pyx_INCREF(__pyx_v___pyx_result);
   18412           0 :   __pyx_r = __pyx_v___pyx_result;
   18413           0 :   goto __pyx_L0;
   18414             : 
   18415             :   /* "(tree fragment)":1
   18416             :  * def __pyx_unpickle_Enum(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
   18417             :  *     cdef object __pyx_PickleError
   18418             :  *     cdef object __pyx_result
   18419             :  */
   18420             : 
   18421             :   /* function exit code */
   18422           0 :   __pyx_L1_error:;
   18423           0 :   __Pyx_XDECREF(__pyx_t_1);
   18424           0 :   __Pyx_XDECREF(__pyx_t_3);
   18425           0 :   __Pyx_XDECREF(__pyx_t_4);
   18426           0 :   __Pyx_AddTraceback("View.MemoryView.__pyx_unpickle_Enum", __pyx_clineno, __pyx_lineno, __pyx_filename);
   18427           0 :   __pyx_r = NULL;
   18428           0 :   __pyx_L0:;
   18429           0 :   __Pyx_XDECREF(__pyx_v___pyx_PickleError);
   18430           0 :   __Pyx_XDECREF(__pyx_v___pyx_result);
   18431           0 :   __Pyx_XGIVEREF(__pyx_r);
   18432           0 :   __Pyx_RefNannyFinishContext();
   18433           0 :   return __pyx_r;
   18434             : }
   18435             : 
   18436             : /* "(tree fragment)":11
   18437             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18438             :  *     return __pyx_result
   18439             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
   18440             :  *     __pyx_result.name = __pyx_state[0]
   18441             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):
   18442             :  */
   18443             : 
   18444           0 : static PyObject *__pyx_unpickle_Enum__set_state(struct __pyx_MemviewEnum_obj *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
   18445           0 :   PyObject *__pyx_r = NULL;
   18446             :   __Pyx_RefNannyDeclarations
   18447           0 :   PyObject *__pyx_t_1 = NULL;
   18448           0 :   int __pyx_t_2;
   18449           0 :   Py_ssize_t __pyx_t_3;
   18450           0 :   int __pyx_t_4;
   18451           0 :   PyObject *__pyx_t_5 = NULL;
   18452           0 :   PyObject *__pyx_t_6 = NULL;
   18453           0 :   PyObject *__pyx_t_7 = NULL;
   18454           0 :   unsigned int __pyx_t_8;
   18455           0 :   int __pyx_lineno = 0;
   18456           0 :   const char *__pyx_filename = NULL;
   18457           0 :   int __pyx_clineno = 0;
   18458           0 :   __Pyx_RefNannySetupContext("__pyx_unpickle_Enum__set_state", 1);
   18459             : 
   18460             :   /* "(tree fragment)":12
   18461             :  *     return __pyx_result
   18462             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):
   18463             :  *     __pyx_result.name = __pyx_state[0]             # <<<<<<<<<<<<<<
   18464             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):
   18465             :  *         __pyx_result.__dict__.update(__pyx_state[1])
   18466             :  */
   18467           0 :   if (unlikely(__pyx_v___pyx_state == Py_None)) {
   18468           0 :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   18469           0 :     __PYX_ERR(1, 12, __pyx_L1_error)
   18470             :   }
   18471           0 :   __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
   18472           0 :   __Pyx_GOTREF(__pyx_t_1);
   18473           0 :   __Pyx_GIVEREF(__pyx_t_1);
   18474           0 :   __Pyx_GOTREF(__pyx_v___pyx_result->name);
   18475           0 :   __Pyx_DECREF(__pyx_v___pyx_result->name);
   18476           0 :   __pyx_v___pyx_result->name = __pyx_t_1;
   18477           0 :   __pyx_t_1 = 0;
   18478             : 
   18479             :   /* "(tree fragment)":13
   18480             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):
   18481             :  *     __pyx_result.name = __pyx_state[0]
   18482             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
   18483             :  *         __pyx_result.__dict__.update(__pyx_state[1])
   18484             :  */
   18485           0 :   if (unlikely(__pyx_v___pyx_state == Py_None)) {
   18486             :     PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   18487             :     __PYX_ERR(1, 13, __pyx_L1_error)
   18488             :   }
   18489           0 :   __pyx_t_3 = __Pyx_PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 13, __pyx_L1_error)
   18490           0 :   __pyx_t_4 = (__pyx_t_3 > 1);
   18491           0 :   if (__pyx_t_4) {
   18492           0 :   } else {
   18493           0 :     __pyx_t_2 = __pyx_t_4;
   18494           0 :     goto __pyx_L4_bool_binop_done;
   18495             :   }
   18496           0 :   __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 13, __pyx_L1_error)
   18497             :   __pyx_t_2 = __pyx_t_4;
   18498           0 :   __pyx_L4_bool_binop_done:;
   18499           0 :   if (__pyx_t_2) {
   18500             : 
   18501             :     /* "(tree fragment)":14
   18502             :  *     __pyx_result.name = __pyx_state[0]
   18503             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):
   18504             :  *         __pyx_result.__dict__.update(__pyx_state[1])             # <<<<<<<<<<<<<<
   18505             :  */
   18506           0 :     __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 14, __pyx_L1_error)
   18507           0 :     __Pyx_GOTREF(__pyx_t_5);
   18508           0 :     __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_update); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 14, __pyx_L1_error)
   18509           0 :     __Pyx_GOTREF(__pyx_t_6);
   18510           0 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   18511           0 :     if (unlikely(__pyx_v___pyx_state == Py_None)) {
   18512             :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   18513             :       __PYX_ERR(1, 14, __pyx_L1_error)
   18514             :     }
   18515           0 :     __pyx_t_5 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 14, __pyx_L1_error)
   18516           0 :     __Pyx_GOTREF(__pyx_t_5);
   18517           0 :     __pyx_t_7 = NULL;
   18518           0 :     __pyx_t_8 = 0;
   18519             :     #if CYTHON_UNPACK_METHODS
   18520           0 :     if (likely(PyMethod_Check(__pyx_t_6))) {
   18521           0 :       __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6);
   18522           0 :       if (likely(__pyx_t_7)) {
   18523           0 :         PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
   18524           0 :         __Pyx_INCREF(__pyx_t_7);
   18525           0 :         __Pyx_INCREF(function);
   18526           0 :         __Pyx_DECREF_SET(__pyx_t_6, function);
   18527             :         __pyx_t_8 = 1;
   18528             :       }
   18529             :     }
   18530             :     #endif
   18531             :     {
   18532           0 :       PyObject *__pyx_callargs[2] = {__pyx_t_7, __pyx_t_5};
   18533           0 :       __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_6, __pyx_callargs+1-__pyx_t_8, 1+__pyx_t_8);
   18534           0 :       __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
   18535           0 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   18536           0 :       if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 14, __pyx_L1_error)
   18537           0 :       __Pyx_GOTREF(__pyx_t_1);
   18538           0 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   18539             :     }
   18540           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   18541             : 
   18542             :     /* "(tree fragment)":13
   18543             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):
   18544             :  *     __pyx_result.name = __pyx_state[0]
   18545             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
   18546             :  *         __pyx_result.__dict__.update(__pyx_state[1])
   18547             :  */
   18548             :   }
   18549             : 
   18550             :   /* "(tree fragment)":11
   18551             :  *         __pyx_unpickle_Enum__set_state(<Enum> __pyx_result, __pyx_state)
   18552             :  *     return __pyx_result
   18553             :  * cdef __pyx_unpickle_Enum__set_state(Enum __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
   18554             :  *     __pyx_result.name = __pyx_state[0]
   18555             :  *     if len(__pyx_state) > 1 and hasattr(__pyx_result, '__dict__'):
   18556             :  */
   18557             : 
   18558             :   /* function exit code */
   18559           0 :   __pyx_r = Py_None; __Pyx_INCREF(Py_None);
   18560           0 :   goto __pyx_L0;
   18561           0 :   __pyx_L1_error:;
   18562           0 :   __Pyx_XDECREF(__pyx_t_1);
   18563           0 :   __Pyx_XDECREF(__pyx_t_5);
   18564           0 :   __Pyx_XDECREF(__pyx_t_6);
   18565           0 :   __Pyx_XDECREF(__pyx_t_7);
   18566           0 :   __Pyx_AddTraceback("View.MemoryView.__pyx_unpickle_Enum__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
   18567           0 :   __pyx_r = 0;
   18568           0 :   __pyx_L0:;
   18569           0 :   __Pyx_XGIVEREF(__pyx_r);
   18570           0 :   __Pyx_RefNannyFinishContext();
   18571           0 :   return __pyx_r;
   18572             : }
   18573             : 
   18574             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":286
   18575             :  * 
   18576             :  *         @property
   18577             :  *         cdef inline npy_intp itemsize(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18578             :  *             return PyDataType_ELSIZE(self)
   18579             :  * 
   18580             :  */
   18581             : 
   18582             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_5dtype_8itemsize_itemsize(PyArray_Descr *__pyx_v_self) {
   18583             :   npy_intp __pyx_r;
   18584             : 
   18585             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":287
   18586             :  *         @property
   18587             :  *         cdef inline npy_intp itemsize(self) noexcept nogil:
   18588             :  *             return PyDataType_ELSIZE(self)             # <<<<<<<<<<<<<<
   18589             :  * 
   18590             :  *         @property
   18591             :  */
   18592             :   __pyx_r = PyDataType_ELSIZE(__pyx_v_self);
   18593             :   goto __pyx_L0;
   18594             : 
   18595             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":286
   18596             :  * 
   18597             :  *         @property
   18598             :  *         cdef inline npy_intp itemsize(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18599             :  *             return PyDataType_ELSIZE(self)
   18600             :  * 
   18601             :  */
   18602             : 
   18603             :   /* function exit code */
   18604             :   __pyx_L0:;
   18605             :   return __pyx_r;
   18606             : }
   18607             : 
   18608             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":290
   18609             :  * 
   18610             :  *         @property
   18611             :  *         cdef inline npy_intp alignment(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18612             :  *             return PyDataType_ALIGNMENT(self)
   18613             :  * 
   18614             :  */
   18615             : 
   18616             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_5dtype_9alignment_alignment(PyArray_Descr *__pyx_v_self) {
   18617             :   npy_intp __pyx_r;
   18618             : 
   18619             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":291
   18620             :  *         @property
   18621             :  *         cdef inline npy_intp alignment(self) noexcept nogil:
   18622             :  *             return PyDataType_ALIGNMENT(self)             # <<<<<<<<<<<<<<
   18623             :  * 
   18624             :  *         # Use fields/names with care as they may be NULL.  You must check
   18625             :  */
   18626             :   __pyx_r = PyDataType_ALIGNMENT(__pyx_v_self);
   18627             :   goto __pyx_L0;
   18628             : 
   18629             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":290
   18630             :  * 
   18631             :  *         @property
   18632             :  *         cdef inline npy_intp alignment(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18633             :  *             return PyDataType_ALIGNMENT(self)
   18634             :  * 
   18635             :  */
   18636             : 
   18637             :   /* function exit code */
   18638             :   __pyx_L0:;
   18639             :   return __pyx_r;
   18640             : }
   18641             : 
   18642             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":296
   18643             :  *         # for this using PyDataType_HASFIELDS.
   18644             :  *         @property
   18645             :  *         cdef inline object fields(self):             # <<<<<<<<<<<<<<
   18646             :  *             return <object>PyDataType_FIELDS(self)
   18647             :  * 
   18648             :  */
   18649             : 
   18650             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_5dtype_6fields_fields(PyArray_Descr *__pyx_v_self) {
   18651             :   PyObject *__pyx_r = NULL;
   18652             :   __Pyx_RefNannyDeclarations
   18653             :   PyObject *__pyx_t_1;
   18654             :   __Pyx_RefNannySetupContext("fields", 1);
   18655             : 
   18656             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":297
   18657             :  *         @property
   18658             :  *         cdef inline object fields(self):
   18659             :  *             return <object>PyDataType_FIELDS(self)             # <<<<<<<<<<<<<<
   18660             :  * 
   18661             :  *         @property
   18662             :  */
   18663             :   __Pyx_XDECREF(__pyx_r);
   18664             :   __pyx_t_1 = PyDataType_FIELDS(__pyx_v_self);
   18665             :   __Pyx_INCREF(((PyObject *)__pyx_t_1));
   18666             :   __pyx_r = ((PyObject *)__pyx_t_1);
   18667             :   goto __pyx_L0;
   18668             : 
   18669             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":296
   18670             :  *         # for this using PyDataType_HASFIELDS.
   18671             :  *         @property
   18672             :  *         cdef inline object fields(self):             # <<<<<<<<<<<<<<
   18673             :  *             return <object>PyDataType_FIELDS(self)
   18674             :  * 
   18675             :  */
   18676             : 
   18677             :   /* function exit code */
   18678             :   __pyx_L0:;
   18679             :   __Pyx_XGIVEREF(__pyx_r);
   18680             :   __Pyx_RefNannyFinishContext();
   18681             :   return __pyx_r;
   18682             : }
   18683             : 
   18684             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":300
   18685             :  * 
   18686             :  *         @property
   18687             :  *         cdef inline tuple names(self):             # <<<<<<<<<<<<<<
   18688             :  *             return <tuple>PyDataType_NAMES(self)
   18689             :  * 
   18690             :  */
   18691             : 
   18692             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_5dtype_5names_names(PyArray_Descr *__pyx_v_self) {
   18693             :   PyObject *__pyx_r = NULL;
   18694             :   __Pyx_RefNannyDeclarations
   18695             :   PyObject *__pyx_t_1;
   18696             :   __Pyx_RefNannySetupContext("names", 1);
   18697             : 
   18698             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":301
   18699             :  *         @property
   18700             :  *         cdef inline tuple names(self):
   18701             :  *             return <tuple>PyDataType_NAMES(self)             # <<<<<<<<<<<<<<
   18702             :  * 
   18703             :  *         # Use PyDataType_HASSUBARRAY to test whether this field is
   18704             :  */
   18705             :   __Pyx_XDECREF(__pyx_r);
   18706             :   __pyx_t_1 = PyDataType_NAMES(__pyx_v_self);
   18707             :   __Pyx_INCREF(((PyObject*)__pyx_t_1));
   18708             :   __pyx_r = ((PyObject*)__pyx_t_1);
   18709             :   goto __pyx_L0;
   18710             : 
   18711             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":300
   18712             :  * 
   18713             :  *         @property
   18714             :  *         cdef inline tuple names(self):             # <<<<<<<<<<<<<<
   18715             :  *             return <tuple>PyDataType_NAMES(self)
   18716             :  * 
   18717             :  */
   18718             : 
   18719             :   /* function exit code */
   18720             :   __pyx_L0:;
   18721             :   __Pyx_XGIVEREF(__pyx_r);
   18722             :   __Pyx_RefNannyFinishContext();
   18723             :   return __pyx_r;
   18724             : }
   18725             : 
   18726             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":307
   18727             :  *         # this field via the inline helper method PyDataType_SHAPE.
   18728             :  *         @property
   18729             :  *         cdef inline PyArray_ArrayDescr* subarray(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18730             :  *             return PyDataType_SUBARRAY(self)
   18731             :  * 
   18732             :  */
   18733             : 
   18734             : static CYTHON_INLINE PyArray_ArrayDescr *__pyx_f_5numpy_5dtype_8subarray_subarray(PyArray_Descr *__pyx_v_self) {
   18735             :   PyArray_ArrayDescr *__pyx_r;
   18736             : 
   18737             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":308
   18738             :  *         @property
   18739             :  *         cdef inline PyArray_ArrayDescr* subarray(self) noexcept nogil:
   18740             :  *             return PyDataType_SUBARRAY(self)             # <<<<<<<<<<<<<<
   18741             :  * 
   18742             :  *         @property
   18743             :  */
   18744             :   __pyx_r = PyDataType_SUBARRAY(__pyx_v_self);
   18745             :   goto __pyx_L0;
   18746             : 
   18747             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":307
   18748             :  *         # this field via the inline helper method PyDataType_SHAPE.
   18749             :  *         @property
   18750             :  *         cdef inline PyArray_ArrayDescr* subarray(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18751             :  *             return PyDataType_SUBARRAY(self)
   18752             :  * 
   18753             :  */
   18754             : 
   18755             :   /* function exit code */
   18756             :   __pyx_L0:;
   18757             :   return __pyx_r;
   18758             : }
   18759             : 
   18760             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":311
   18761             :  * 
   18762             :  *         @property
   18763             :  *         cdef inline npy_uint64 flags(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18764             :  *             """The data types flags."""
   18765             :  *             return PyDataType_FLAGS(self)
   18766             :  */
   18767             : 
   18768             : static CYTHON_INLINE npy_uint64 __pyx_f_5numpy_5dtype_5flags_flags(PyArray_Descr *__pyx_v_self) {
   18769             :   npy_uint64 __pyx_r;
   18770             : 
   18771             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":313
   18772             :  *         cdef inline npy_uint64 flags(self) noexcept nogil:
   18773             :  *             """The data types flags."""
   18774             :  *             return PyDataType_FLAGS(self)             # <<<<<<<<<<<<<<
   18775             :  * 
   18776             :  * 
   18777             :  */
   18778             :   __pyx_r = PyDataType_FLAGS(__pyx_v_self);
   18779             :   goto __pyx_L0;
   18780             : 
   18781             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":311
   18782             :  * 
   18783             :  *         @property
   18784             :  *         cdef inline npy_uint64 flags(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18785             :  *             """The data types flags."""
   18786             :  *             return PyDataType_FLAGS(self)
   18787             :  */
   18788             : 
   18789             :   /* function exit code */
   18790             :   __pyx_L0:;
   18791             :   return __pyx_r;
   18792             : }
   18793             : 
   18794             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":323
   18795             :  * 
   18796             :  *         @property
   18797             :  *         cdef inline int numiter(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18798             :  *             """The number of arrays that need to be broadcast to the same shape."""
   18799             :  *             return PyArray_MultiIter_NUMITER(self)
   18800             :  */
   18801             : 
   18802             : static CYTHON_INLINE int __pyx_f_5numpy_9broadcast_7numiter_numiter(PyArrayMultiIterObject *__pyx_v_self) {
   18803             :   int __pyx_r;
   18804             : 
   18805             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":325
   18806             :  *         cdef inline int numiter(self) noexcept nogil:
   18807             :  *             """The number of arrays that need to be broadcast to the same shape."""
   18808             :  *             return PyArray_MultiIter_NUMITER(self)             # <<<<<<<<<<<<<<
   18809             :  * 
   18810             :  *         @property
   18811             :  */
   18812             :   __pyx_r = PyArray_MultiIter_NUMITER(__pyx_v_self);
   18813             :   goto __pyx_L0;
   18814             : 
   18815             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":323
   18816             :  * 
   18817             :  *         @property
   18818             :  *         cdef inline int numiter(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18819             :  *             """The number of arrays that need to be broadcast to the same shape."""
   18820             :  *             return PyArray_MultiIter_NUMITER(self)
   18821             :  */
   18822             : 
   18823             :   /* function exit code */
   18824             :   __pyx_L0:;
   18825             :   return __pyx_r;
   18826             : }
   18827             : 
   18828             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":328
   18829             :  * 
   18830             :  *         @property
   18831             :  *         cdef inline npy_intp size(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18832             :  *             """The total broadcasted size."""
   18833             :  *             return PyArray_MultiIter_SIZE(self)
   18834             :  */
   18835             : 
   18836             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_9broadcast_4size_size(PyArrayMultiIterObject *__pyx_v_self) {
   18837             :   npy_intp __pyx_r;
   18838             : 
   18839             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":330
   18840             :  *         cdef inline npy_intp size(self) noexcept nogil:
   18841             :  *             """The total broadcasted size."""
   18842             :  *             return PyArray_MultiIter_SIZE(self)             # <<<<<<<<<<<<<<
   18843             :  * 
   18844             :  *         @property
   18845             :  */
   18846             :   __pyx_r = PyArray_MultiIter_SIZE(__pyx_v_self);
   18847             :   goto __pyx_L0;
   18848             : 
   18849             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":328
   18850             :  * 
   18851             :  *         @property
   18852             :  *         cdef inline npy_intp size(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18853             :  *             """The total broadcasted size."""
   18854             :  *             return PyArray_MultiIter_SIZE(self)
   18855             :  */
   18856             : 
   18857             :   /* function exit code */
   18858             :   __pyx_L0:;
   18859             :   return __pyx_r;
   18860             : }
   18861             : 
   18862             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":333
   18863             :  * 
   18864             :  *         @property
   18865             :  *         cdef inline npy_intp index(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18866             :  *             """The current (1-d) index into the broadcasted result."""
   18867             :  *             return PyArray_MultiIter_INDEX(self)
   18868             :  */
   18869             : 
   18870             : static CYTHON_INLINE npy_intp __pyx_f_5numpy_9broadcast_5index_index(PyArrayMultiIterObject *__pyx_v_self) {
   18871             :   npy_intp __pyx_r;
   18872             : 
   18873             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":335
   18874             :  *         cdef inline npy_intp index(self) noexcept nogil:
   18875             :  *             """The current (1-d) index into the broadcasted result."""
   18876             :  *             return PyArray_MultiIter_INDEX(self)             # <<<<<<<<<<<<<<
   18877             :  * 
   18878             :  *         @property
   18879             :  */
   18880             :   __pyx_r = PyArray_MultiIter_INDEX(__pyx_v_self);
   18881             :   goto __pyx_L0;
   18882             : 
   18883             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":333
   18884             :  * 
   18885             :  *         @property
   18886             :  *         cdef inline npy_intp index(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18887             :  *             """The current (1-d) index into the broadcasted result."""
   18888             :  *             return PyArray_MultiIter_INDEX(self)
   18889             :  */
   18890             : 
   18891             :   /* function exit code */
   18892             :   __pyx_L0:;
   18893             :   return __pyx_r;
   18894             : }
   18895             : 
   18896             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":338
   18897             :  * 
   18898             :  *         @property
   18899             :  *         cdef inline int nd(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18900             :  *             """The number of dimensions in the broadcasted result."""
   18901             :  *             return PyArray_MultiIter_NDIM(self)
   18902             :  */
   18903             : 
   18904             : static CYTHON_INLINE int __pyx_f_5numpy_9broadcast_2nd_nd(PyArrayMultiIterObject *__pyx_v_self) {
   18905             :   int __pyx_r;
   18906             : 
   18907             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":340
   18908             :  *         cdef inline int nd(self) noexcept nogil:
   18909             :  *             """The number of dimensions in the broadcasted result."""
   18910             :  *             return PyArray_MultiIter_NDIM(self)             # <<<<<<<<<<<<<<
   18911             :  * 
   18912             :  *         @property
   18913             :  */
   18914             :   __pyx_r = PyArray_MultiIter_NDIM(__pyx_v_self);
   18915             :   goto __pyx_L0;
   18916             : 
   18917             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":338
   18918             :  * 
   18919             :  *         @property
   18920             :  *         cdef inline int nd(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18921             :  *             """The number of dimensions in the broadcasted result."""
   18922             :  *             return PyArray_MultiIter_NDIM(self)
   18923             :  */
   18924             : 
   18925             :   /* function exit code */
   18926             :   __pyx_L0:;
   18927             :   return __pyx_r;
   18928             : }
   18929             : 
   18930             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":343
   18931             :  * 
   18932             :  *         @property
   18933             :  *         cdef inline npy_intp* dimensions(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18934             :  *             """The shape of the broadcasted result."""
   18935             :  *             return PyArray_MultiIter_DIMS(self)
   18936             :  */
   18937             : 
   18938             : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_9broadcast_10dimensions_dimensions(PyArrayMultiIterObject *__pyx_v_self) {
   18939             :   npy_intp *__pyx_r;
   18940             : 
   18941             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":345
   18942             :  *         cdef inline npy_intp* dimensions(self) noexcept nogil:
   18943             :  *             """The shape of the broadcasted result."""
   18944             :  *             return PyArray_MultiIter_DIMS(self)             # <<<<<<<<<<<<<<
   18945             :  * 
   18946             :  *         @property
   18947             :  */
   18948             :   __pyx_r = PyArray_MultiIter_DIMS(__pyx_v_self);
   18949             :   goto __pyx_L0;
   18950             : 
   18951             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":343
   18952             :  * 
   18953             :  *         @property
   18954             :  *         cdef inline npy_intp* dimensions(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18955             :  *             """The shape of the broadcasted result."""
   18956             :  *             return PyArray_MultiIter_DIMS(self)
   18957             :  */
   18958             : 
   18959             :   /* function exit code */
   18960             :   __pyx_L0:;
   18961             :   return __pyx_r;
   18962             : }
   18963             : 
   18964             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":348
   18965             :  * 
   18966             :  *         @property
   18967             :  *         cdef inline void** iters(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18968             :  *             """An array of iterator objects that holds the iterators for the arrays to be broadcast together.
   18969             :  *             On return, the iterators are adjusted for broadcasting."""
   18970             :  */
   18971             : 
   18972             : static CYTHON_INLINE void **__pyx_f_5numpy_9broadcast_5iters_iters(PyArrayMultiIterObject *__pyx_v_self) {
   18973             :   void **__pyx_r;
   18974             : 
   18975             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":351
   18976             :  *             """An array of iterator objects that holds the iterators for the arrays to be broadcast together.
   18977             :  *             On return, the iterators are adjusted for broadcasting."""
   18978             :  *             return PyArray_MultiIter_ITERS(self)             # <<<<<<<<<<<<<<
   18979             :  * 
   18980             :  * 
   18981             :  */
   18982             :   __pyx_r = PyArray_MultiIter_ITERS(__pyx_v_self);
   18983             :   goto __pyx_L0;
   18984             : 
   18985             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":348
   18986             :  * 
   18987             :  *         @property
   18988             :  *         cdef inline void** iters(self) noexcept nogil:             # <<<<<<<<<<<<<<
   18989             :  *             """An array of iterator objects that holds the iterators for the arrays to be broadcast together.
   18990             :  *             On return, the iterators are adjusted for broadcasting."""
   18991             :  */
   18992             : 
   18993             :   /* function exit code */
   18994             :   __pyx_L0:;
   18995             :   return __pyx_r;
   18996             : }
   18997             : 
   18998             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":366
   18999             :  * 
   19000             :  *         @property
   19001             :  *         cdef inline PyObject* base(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19002             :  *             """Returns a borrowed reference to the object owning the data/memory.
   19003             :  *             """
   19004             :  */
   19005             : 
   19006             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_7ndarray_4base_base(PyArrayObject *__pyx_v_self) {
   19007             :   PyObject *__pyx_r;
   19008             : 
   19009             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":369
   19010             :  *             """Returns a borrowed reference to the object owning the data/memory.
   19011             :  *             """
   19012             :  *             return PyArray_BASE(self)             # <<<<<<<<<<<<<<
   19013             :  * 
   19014             :  *         @property
   19015             :  */
   19016             :   __pyx_r = PyArray_BASE(__pyx_v_self);
   19017             :   goto __pyx_L0;
   19018             : 
   19019             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":366
   19020             :  * 
   19021             :  *         @property
   19022             :  *         cdef inline PyObject* base(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19023             :  *             """Returns a borrowed reference to the object owning the data/memory.
   19024             :  *             """
   19025             :  */
   19026             : 
   19027             :   /* function exit code */
   19028             :   __pyx_L0:;
   19029             :   return __pyx_r;
   19030             : }
   19031             : 
   19032             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":372
   19033             :  * 
   19034             :  *         @property
   19035             :  *         cdef inline dtype descr(self):             # <<<<<<<<<<<<<<
   19036             :  *             """Returns an owned reference to the dtype of the array.
   19037             :  *             """
   19038             :  */
   19039             : 
   19040             : static CYTHON_INLINE PyArray_Descr *__pyx_f_5numpy_7ndarray_5descr_descr(PyArrayObject *__pyx_v_self) {
   19041             :   PyArray_Descr *__pyx_r = NULL;
   19042             :   __Pyx_RefNannyDeclarations
   19043             :   PyArray_Descr *__pyx_t_1;
   19044             :   __Pyx_RefNannySetupContext("descr", 1);
   19045             : 
   19046             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":375
   19047             :  *             """Returns an owned reference to the dtype of the array.
   19048             :  *             """
   19049             :  *             return <dtype>PyArray_DESCR(self)             # <<<<<<<<<<<<<<
   19050             :  * 
   19051             :  *         @property
   19052             :  */
   19053             :   __Pyx_XDECREF((PyObject *)__pyx_r);
   19054             :   __pyx_t_1 = PyArray_DESCR(__pyx_v_self);
   19055             :   __Pyx_INCREF((PyObject *)((PyArray_Descr *)__pyx_t_1));
   19056             :   __pyx_r = ((PyArray_Descr *)__pyx_t_1);
   19057             :   goto __pyx_L0;
   19058             : 
   19059             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":372
   19060             :  * 
   19061             :  *         @property
   19062             :  *         cdef inline dtype descr(self):             # <<<<<<<<<<<<<<
   19063             :  *             """Returns an owned reference to the dtype of the array.
   19064             :  *             """
   19065             :  */
   19066             : 
   19067             :   /* function exit code */
   19068             :   __pyx_L0:;
   19069             :   __Pyx_XGIVEREF((PyObject *)__pyx_r);
   19070             :   __Pyx_RefNannyFinishContext();
   19071             :   return __pyx_r;
   19072             : }
   19073             : 
   19074             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":378
   19075             :  * 
   19076             :  *         @property
   19077             :  *         cdef inline int ndim(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19078             :  *             """Returns the number of dimensions in the array.
   19079             :  *             """
   19080             :  */
   19081             : 
   19082         595 : static CYTHON_INLINE int __pyx_f_5numpy_7ndarray_4ndim_ndim(PyArrayObject *__pyx_v_self) {
   19083         595 :   int __pyx_r;
   19084             : 
   19085             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":381
   19086             :  *             """Returns the number of dimensions in the array.
   19087             :  *             """
   19088             :  *             return PyArray_NDIM(self)             # <<<<<<<<<<<<<<
   19089             :  * 
   19090             :  *         @property
   19091             :  */
   19092         595 :   __pyx_r = PyArray_NDIM(__pyx_v_self);
   19093         595 :   goto __pyx_L0;
   19094             : 
   19095             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":378
   19096             :  * 
   19097             :  *         @property
   19098             :  *         cdef inline int ndim(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19099             :  *             """Returns the number of dimensions in the array.
   19100             :  *             """
   19101             :  */
   19102             : 
   19103             :   /* function exit code */
   19104         595 :   __pyx_L0:;
   19105         595 :   return __pyx_r;
   19106             : }
   19107             : 
   19108             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":384
   19109             :  * 
   19110             :  *         @property
   19111             :  *         cdef inline npy_intp *shape(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19112             :  *             """Returns a pointer to the dimensions/shape of the array.
   19113             :  *             The number of elements matches the number of dimensions of the array (ndim).
   19114             :  */
   19115             : 
   19116         357 : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_7ndarray_5shape_shape(PyArrayObject *__pyx_v_self) {
   19117         357 :   npy_intp *__pyx_r;
   19118             : 
   19119             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":389
   19120             :  *             Can return NULL for 0-dimensional arrays.
   19121             :  *             """
   19122             :  *             return PyArray_DIMS(self)             # <<<<<<<<<<<<<<
   19123             :  * 
   19124             :  *         @property
   19125             :  */
   19126         357 :   __pyx_r = PyArray_DIMS(__pyx_v_self);
   19127         357 :   goto __pyx_L0;
   19128             : 
   19129             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":384
   19130             :  * 
   19131             :  *         @property
   19132             :  *         cdef inline npy_intp *shape(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19133             :  *             """Returns a pointer to the dimensions/shape of the array.
   19134             :  *             The number of elements matches the number of dimensions of the array (ndim).
   19135             :  */
   19136             : 
   19137             :   /* function exit code */
   19138         357 :   __pyx_L0:;
   19139         357 :   return __pyx_r;
   19140             : }
   19141             : 
   19142             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":392
   19143             :  * 
   19144             :  *         @property
   19145             :  *         cdef inline npy_intp *strides(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19146             :  *             """Returns a pointer to the strides of the array.
   19147             :  *             The number of elements matches the number of dimensions of the array (ndim).
   19148             :  */
   19149             : 
   19150         238 : static CYTHON_INLINE npy_intp *__pyx_f_5numpy_7ndarray_7strides_strides(PyArrayObject *__pyx_v_self) {
   19151         238 :   npy_intp *__pyx_r;
   19152             : 
   19153             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":396
   19154             :  *             The number of elements matches the number of dimensions of the array (ndim).
   19155             :  *             """
   19156             :  *             return PyArray_STRIDES(self)             # <<<<<<<<<<<<<<
   19157             :  * 
   19158             :  *         @property
   19159             :  */
   19160         238 :   __pyx_r = PyArray_STRIDES(__pyx_v_self);
   19161         238 :   goto __pyx_L0;
   19162             : 
   19163             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":392
   19164             :  * 
   19165             :  *         @property
   19166             :  *         cdef inline npy_intp *strides(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19167             :  *             """Returns a pointer to the strides of the array.
   19168             :  *             The number of elements matches the number of dimensions of the array (ndim).
   19169             :  */
   19170             : 
   19171             :   /* function exit code */
   19172         238 :   __pyx_L0:;
   19173         238 :   return __pyx_r;
   19174             : }
   19175             : 
   19176             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":399
   19177             :  * 
   19178             :  *         @property
   19179             :  *         cdef inline npy_intp size(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19180             :  *             """Returns the total size (in number of elements) of the array.
   19181             :  *             """
   19182             :  */
   19183             : 
   19184         238 : static CYTHON_INLINE npy_intp __pyx_f_5numpy_7ndarray_4size_size(PyArrayObject *__pyx_v_self) {
   19185         238 :   npy_intp __pyx_r;
   19186             : 
   19187             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":402
   19188             :  *             """Returns the total size (in number of elements) of the array.
   19189             :  *             """
   19190             :  *             return PyArray_SIZE(self)             # <<<<<<<<<<<<<<
   19191             :  * 
   19192             :  *         @property
   19193             :  */
   19194         476 :   __pyx_r = PyArray_SIZE(__pyx_v_self);
   19195         238 :   goto __pyx_L0;
   19196             : 
   19197             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":399
   19198             :  * 
   19199             :  *         @property
   19200             :  *         cdef inline npy_intp size(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19201             :  *             """Returns the total size (in number of elements) of the array.
   19202             :  *             """
   19203             :  */
   19204             : 
   19205             :   /* function exit code */
   19206         238 :   __pyx_L0:;
   19207         238 :   return __pyx_r;
   19208             : }
   19209             : 
   19210             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":405
   19211             :  * 
   19212             :  *         @property
   19213             :  *         cdef inline char* data(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19214             :  *             """The pointer to the data buffer as a char*.
   19215             :  *             This is provided for legacy reasons to avoid direct struct field access.
   19216             :  */
   19217             : 
   19218         119 : static CYTHON_INLINE char *__pyx_f_5numpy_7ndarray_4data_data(PyArrayObject *__pyx_v_self) {
   19219         119 :   char *__pyx_r;
   19220             : 
   19221             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":411
   19222             :  *             of `PyArray_DATA()` instead, which returns a 'void*'.
   19223             :  *             """
   19224             :  *             return PyArray_BYTES(self)             # <<<<<<<<<<<<<<
   19225             :  * 
   19226             :  * 
   19227             :  */
   19228         119 :   __pyx_r = PyArray_BYTES(__pyx_v_self);
   19229         119 :   goto __pyx_L0;
   19230             : 
   19231             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":405
   19232             :  * 
   19233             :  *         @property
   19234             :  *         cdef inline char* data(self) noexcept nogil:             # <<<<<<<<<<<<<<
   19235             :  *             """The pointer to the data buffer as a char*.
   19236             :  *             This is provided for legacy reasons to avoid direct struct field access.
   19237             :  */
   19238             : 
   19239             :   /* function exit code */
   19240         119 :   __pyx_L0:;
   19241         119 :   return __pyx_r;
   19242             : }
   19243             : 
   19244             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":806
   19245             :  * ctypedef long double complex clongdouble_t
   19246             :  * 
   19247             :  * cdef inline object PyArray_MultiIterNew1(a):             # <<<<<<<<<<<<<<
   19248             :  *     return PyArray_MultiIterNew(1, <void*>a)
   19249             :  * 
   19250             :  */
   19251             : 
   19252             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew1(PyObject *__pyx_v_a) {
   19253             :   PyObject *__pyx_r = NULL;
   19254             :   __Pyx_RefNannyDeclarations
   19255             :   PyObject *__pyx_t_1 = NULL;
   19256             :   int __pyx_lineno = 0;
   19257             :   const char *__pyx_filename = NULL;
   19258             :   int __pyx_clineno = 0;
   19259             :   __Pyx_RefNannySetupContext("PyArray_MultiIterNew1", 1);
   19260             : 
   19261             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":807
   19262             :  * 
   19263             :  * cdef inline object PyArray_MultiIterNew1(a):
   19264             :  *     return PyArray_MultiIterNew(1, <void*>a)             # <<<<<<<<<<<<<<
   19265             :  * 
   19266             :  * cdef inline object PyArray_MultiIterNew2(a, b):
   19267             :  */
   19268             :   __Pyx_XDECREF(__pyx_r);
   19269             :   __pyx_t_1 = PyArray_MultiIterNew(1, ((void *)__pyx_v_a)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 807, __pyx_L1_error)
   19270             :   __Pyx_GOTREF(__pyx_t_1);
   19271             :   __pyx_r = __pyx_t_1;
   19272             :   __pyx_t_1 = 0;
   19273             :   goto __pyx_L0;
   19274             : 
   19275             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":806
   19276             :  * ctypedef long double complex clongdouble_t
   19277             :  * 
   19278             :  * cdef inline object PyArray_MultiIterNew1(a):             # <<<<<<<<<<<<<<
   19279             :  *     return PyArray_MultiIterNew(1, <void*>a)
   19280             :  * 
   19281             :  */
   19282             : 
   19283             :   /* function exit code */
   19284             :   __pyx_L1_error:;
   19285             :   __Pyx_XDECREF(__pyx_t_1);
   19286             :   __Pyx_AddTraceback("numpy.PyArray_MultiIterNew1", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19287             :   __pyx_r = 0;
   19288             :   __pyx_L0:;
   19289             :   __Pyx_XGIVEREF(__pyx_r);
   19290             :   __Pyx_RefNannyFinishContext();
   19291             :   return __pyx_r;
   19292             : }
   19293             : 
   19294             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":809
   19295             :  *     return PyArray_MultiIterNew(1, <void*>a)
   19296             :  * 
   19297             :  * cdef inline object PyArray_MultiIterNew2(a, b):             # <<<<<<<<<<<<<<
   19298             :  *     return PyArray_MultiIterNew(2, <void*>a, <void*>b)
   19299             :  * 
   19300             :  */
   19301             : 
   19302             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew2(PyObject *__pyx_v_a, PyObject *__pyx_v_b) {
   19303             :   PyObject *__pyx_r = NULL;
   19304             :   __Pyx_RefNannyDeclarations
   19305             :   PyObject *__pyx_t_1 = NULL;
   19306             :   int __pyx_lineno = 0;
   19307             :   const char *__pyx_filename = NULL;
   19308             :   int __pyx_clineno = 0;
   19309             :   __Pyx_RefNannySetupContext("PyArray_MultiIterNew2", 1);
   19310             : 
   19311             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":810
   19312             :  * 
   19313             :  * cdef inline object PyArray_MultiIterNew2(a, b):
   19314             :  *     return PyArray_MultiIterNew(2, <void*>a, <void*>b)             # <<<<<<<<<<<<<<
   19315             :  * 
   19316             :  * cdef inline object PyArray_MultiIterNew3(a, b, c):
   19317             :  */
   19318             :   __Pyx_XDECREF(__pyx_r);
   19319             :   __pyx_t_1 = PyArray_MultiIterNew(2, ((void *)__pyx_v_a), ((void *)__pyx_v_b)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 810, __pyx_L1_error)
   19320             :   __Pyx_GOTREF(__pyx_t_1);
   19321             :   __pyx_r = __pyx_t_1;
   19322             :   __pyx_t_1 = 0;
   19323             :   goto __pyx_L0;
   19324             : 
   19325             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":809
   19326             :  *     return PyArray_MultiIterNew(1, <void*>a)
   19327             :  * 
   19328             :  * cdef inline object PyArray_MultiIterNew2(a, b):             # <<<<<<<<<<<<<<
   19329             :  *     return PyArray_MultiIterNew(2, <void*>a, <void*>b)
   19330             :  * 
   19331             :  */
   19332             : 
   19333             :   /* function exit code */
   19334             :   __pyx_L1_error:;
   19335             :   __Pyx_XDECREF(__pyx_t_1);
   19336             :   __Pyx_AddTraceback("numpy.PyArray_MultiIterNew2", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19337             :   __pyx_r = 0;
   19338             :   __pyx_L0:;
   19339             :   __Pyx_XGIVEREF(__pyx_r);
   19340             :   __Pyx_RefNannyFinishContext();
   19341             :   return __pyx_r;
   19342             : }
   19343             : 
   19344             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":812
   19345             :  *     return PyArray_MultiIterNew(2, <void*>a, <void*>b)
   19346             :  * 
   19347             :  * cdef inline object PyArray_MultiIterNew3(a, b, c):             # <<<<<<<<<<<<<<
   19348             :  *     return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
   19349             :  * 
   19350             :  */
   19351             : 
   19352             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew3(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c) {
   19353             :   PyObject *__pyx_r = NULL;
   19354             :   __Pyx_RefNannyDeclarations
   19355             :   PyObject *__pyx_t_1 = NULL;
   19356             :   int __pyx_lineno = 0;
   19357             :   const char *__pyx_filename = NULL;
   19358             :   int __pyx_clineno = 0;
   19359             :   __Pyx_RefNannySetupContext("PyArray_MultiIterNew3", 1);
   19360             : 
   19361             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":813
   19362             :  * 
   19363             :  * cdef inline object PyArray_MultiIterNew3(a, b, c):
   19364             :  *     return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)             # <<<<<<<<<<<<<<
   19365             :  * 
   19366             :  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):
   19367             :  */
   19368             :   __Pyx_XDECREF(__pyx_r);
   19369             :   __pyx_t_1 = PyArray_MultiIterNew(3, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 813, __pyx_L1_error)
   19370             :   __Pyx_GOTREF(__pyx_t_1);
   19371             :   __pyx_r = __pyx_t_1;
   19372             :   __pyx_t_1 = 0;
   19373             :   goto __pyx_L0;
   19374             : 
   19375             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":812
   19376             :  *     return PyArray_MultiIterNew(2, <void*>a, <void*>b)
   19377             :  * 
   19378             :  * cdef inline object PyArray_MultiIterNew3(a, b, c):             # <<<<<<<<<<<<<<
   19379             :  *     return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
   19380             :  * 
   19381             :  */
   19382             : 
   19383             :   /* function exit code */
   19384             :   __pyx_L1_error:;
   19385             :   __Pyx_XDECREF(__pyx_t_1);
   19386             :   __Pyx_AddTraceback("numpy.PyArray_MultiIterNew3", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19387             :   __pyx_r = 0;
   19388             :   __pyx_L0:;
   19389             :   __Pyx_XGIVEREF(__pyx_r);
   19390             :   __Pyx_RefNannyFinishContext();
   19391             :   return __pyx_r;
   19392             : }
   19393             : 
   19394             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":815
   19395             :  *     return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
   19396             :  * 
   19397             :  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):             # <<<<<<<<<<<<<<
   19398             :  *     return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
   19399             :  * 
   19400             :  */
   19401             : 
   19402             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew4(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d) {
   19403             :   PyObject *__pyx_r = NULL;
   19404             :   __Pyx_RefNannyDeclarations
   19405             :   PyObject *__pyx_t_1 = NULL;
   19406             :   int __pyx_lineno = 0;
   19407             :   const char *__pyx_filename = NULL;
   19408             :   int __pyx_clineno = 0;
   19409             :   __Pyx_RefNannySetupContext("PyArray_MultiIterNew4", 1);
   19410             : 
   19411             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":816
   19412             :  * 
   19413             :  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):
   19414             :  *     return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)             # <<<<<<<<<<<<<<
   19415             :  * 
   19416             :  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):
   19417             :  */
   19418             :   __Pyx_XDECREF(__pyx_r);
   19419             :   __pyx_t_1 = PyArray_MultiIterNew(4, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c), ((void *)__pyx_v_d)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 816, __pyx_L1_error)
   19420             :   __Pyx_GOTREF(__pyx_t_1);
   19421             :   __pyx_r = __pyx_t_1;
   19422             :   __pyx_t_1 = 0;
   19423             :   goto __pyx_L0;
   19424             : 
   19425             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":815
   19426             :  *     return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
   19427             :  * 
   19428             :  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):             # <<<<<<<<<<<<<<
   19429             :  *     return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
   19430             :  * 
   19431             :  */
   19432             : 
   19433             :   /* function exit code */
   19434             :   __pyx_L1_error:;
   19435             :   __Pyx_XDECREF(__pyx_t_1);
   19436             :   __Pyx_AddTraceback("numpy.PyArray_MultiIterNew4", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19437             :   __pyx_r = 0;
   19438             :   __pyx_L0:;
   19439             :   __Pyx_XGIVEREF(__pyx_r);
   19440             :   __Pyx_RefNannyFinishContext();
   19441             :   return __pyx_r;
   19442             : }
   19443             : 
   19444             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":818
   19445             :  *     return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
   19446             :  * 
   19447             :  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):             # <<<<<<<<<<<<<<
   19448             :  *     return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
   19449             :  * 
   19450             :  */
   19451             : 
   19452             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew5(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d, PyObject *__pyx_v_e) {
   19453             :   PyObject *__pyx_r = NULL;
   19454             :   __Pyx_RefNannyDeclarations
   19455             :   PyObject *__pyx_t_1 = NULL;
   19456             :   int __pyx_lineno = 0;
   19457             :   const char *__pyx_filename = NULL;
   19458             :   int __pyx_clineno = 0;
   19459             :   __Pyx_RefNannySetupContext("PyArray_MultiIterNew5", 1);
   19460             : 
   19461             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":819
   19462             :  * 
   19463             :  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):
   19464             :  *     return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)             # <<<<<<<<<<<<<<
   19465             :  * 
   19466             :  * cdef inline tuple PyDataType_SHAPE(dtype d):
   19467             :  */
   19468             :   __Pyx_XDECREF(__pyx_r);
   19469             :   __pyx_t_1 = PyArray_MultiIterNew(5, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c), ((void *)__pyx_v_d), ((void *)__pyx_v_e)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 819, __pyx_L1_error)
   19470             :   __Pyx_GOTREF(__pyx_t_1);
   19471             :   __pyx_r = __pyx_t_1;
   19472             :   __pyx_t_1 = 0;
   19473             :   goto __pyx_L0;
   19474             : 
   19475             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":818
   19476             :  *     return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
   19477             :  * 
   19478             :  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):             # <<<<<<<<<<<<<<
   19479             :  *     return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
   19480             :  * 
   19481             :  */
   19482             : 
   19483             :   /* function exit code */
   19484             :   __pyx_L1_error:;
   19485             :   __Pyx_XDECREF(__pyx_t_1);
   19486             :   __Pyx_AddTraceback("numpy.PyArray_MultiIterNew5", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19487             :   __pyx_r = 0;
   19488             :   __pyx_L0:;
   19489             :   __Pyx_XGIVEREF(__pyx_r);
   19490             :   __Pyx_RefNannyFinishContext();
   19491             :   return __pyx_r;
   19492             : }
   19493             : 
   19494             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":821
   19495             :  *     return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
   19496             :  * 
   19497             :  * cdef inline tuple PyDataType_SHAPE(dtype d):             # <<<<<<<<<<<<<<
   19498             :  *     if PyDataType_HASSUBARRAY(d):
   19499             :  *         return <tuple>d.subarray.shape
   19500             :  */
   19501             : 
   19502             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyDataType_SHAPE(PyArray_Descr *__pyx_v_d) {
   19503             :   PyObject *__pyx_r = NULL;
   19504             :   __Pyx_RefNannyDeclarations
   19505             :   int __pyx_t_1;
   19506             :   PyObject *__pyx_t_2;
   19507             :   __Pyx_RefNannySetupContext("PyDataType_SHAPE", 1);
   19508             : 
   19509             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":822
   19510             :  * 
   19511             :  * cdef inline tuple PyDataType_SHAPE(dtype d):
   19512             :  *     if PyDataType_HASSUBARRAY(d):             # <<<<<<<<<<<<<<
   19513             :  *         return <tuple>d.subarray.shape
   19514             :  *     else:
   19515             :  */
   19516             :   __pyx_t_1 = PyDataType_HASSUBARRAY(__pyx_v_d);
   19517             :   if (__pyx_t_1) {
   19518             : 
   19519             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":823
   19520             :  * cdef inline tuple PyDataType_SHAPE(dtype d):
   19521             :  *     if PyDataType_HASSUBARRAY(d):
   19522             :  *         return <tuple>d.subarray.shape             # <<<<<<<<<<<<<<
   19523             :  *     else:
   19524             :  *         return ()
   19525             :  */
   19526             :     __Pyx_XDECREF(__pyx_r);
   19527             :     __pyx_t_2 = __pyx_f_5numpy_5dtype_8subarray_subarray(__pyx_v_d)->shape;
   19528             :     __Pyx_INCREF(((PyObject*)__pyx_t_2));
   19529             :     __pyx_r = ((PyObject*)__pyx_t_2);
   19530             :     goto __pyx_L0;
   19531             : 
   19532             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":822
   19533             :  * 
   19534             :  * cdef inline tuple PyDataType_SHAPE(dtype d):
   19535             :  *     if PyDataType_HASSUBARRAY(d):             # <<<<<<<<<<<<<<
   19536             :  *         return <tuple>d.subarray.shape
   19537             :  *     else:
   19538             :  */
   19539             :   }
   19540             : 
   19541             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":825
   19542             :  *         return <tuple>d.subarray.shape
   19543             :  *     else:
   19544             :  *         return ()             # <<<<<<<<<<<<<<
   19545             :  * 
   19546             :  * 
   19547             :  */
   19548             :   /*else*/ {
   19549             :     __Pyx_XDECREF(__pyx_r);
   19550             :     __Pyx_INCREF(__pyx_empty_tuple);
   19551             :     __pyx_r = __pyx_empty_tuple;
   19552             :     goto __pyx_L0;
   19553             :   }
   19554             : 
   19555             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":821
   19556             :  *     return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
   19557             :  * 
   19558             :  * cdef inline tuple PyDataType_SHAPE(dtype d):             # <<<<<<<<<<<<<<
   19559             :  *     if PyDataType_HASSUBARRAY(d):
   19560             :  *         return <tuple>d.subarray.shape
   19561             :  */
   19562             : 
   19563             :   /* function exit code */
   19564             :   __pyx_L0:;
   19565             :   __Pyx_XGIVEREF(__pyx_r);
   19566             :   __Pyx_RefNannyFinishContext();
   19567             :   return __pyx_r;
   19568             : }
   19569             : 
   19570             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1009
   19571             :  *     int _import_umath() except -1
   19572             :  * 
   19573             :  * cdef inline void set_array_base(ndarray arr, object base) except *:             # <<<<<<<<<<<<<<
   19574             :  *     Py_INCREF(base) # important to do this before stealing the reference below!
   19575             :  *     PyArray_SetBaseObject(arr, base)
   19576             :  */
   19577             : 
   19578             : static CYTHON_INLINE void __pyx_f_5numpy_set_array_base(PyArrayObject *__pyx_v_arr, PyObject *__pyx_v_base) {
   19579             :   int __pyx_t_1;
   19580             :   int __pyx_lineno = 0;
   19581             :   const char *__pyx_filename = NULL;
   19582             :   int __pyx_clineno = 0;
   19583             : 
   19584             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1010
   19585             :  * 
   19586             :  * cdef inline void set_array_base(ndarray arr, object base) except *:
   19587             :  *     Py_INCREF(base) # important to do this before stealing the reference below!             # <<<<<<<<<<<<<<
   19588             :  *     PyArray_SetBaseObject(arr, base)
   19589             :  * 
   19590             :  */
   19591             :   Py_INCREF(__pyx_v_base);
   19592             : 
   19593             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1011
   19594             :  * cdef inline void set_array_base(ndarray arr, object base) except *:
   19595             :  *     Py_INCREF(base) # important to do this before stealing the reference below!
   19596             :  *     PyArray_SetBaseObject(arr, base)             # <<<<<<<<<<<<<<
   19597             :  * 
   19598             :  * cdef inline object get_array_base(ndarray arr):
   19599             :  */
   19600             :   __pyx_t_1 = PyArray_SetBaseObject(__pyx_v_arr, __pyx_v_base); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(2, 1011, __pyx_L1_error)
   19601             : 
   19602             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1009
   19603             :  *     int _import_umath() except -1
   19604             :  * 
   19605             :  * cdef inline void set_array_base(ndarray arr, object base) except *:             # <<<<<<<<<<<<<<
   19606             :  *     Py_INCREF(base) # important to do this before stealing the reference below!
   19607             :  *     PyArray_SetBaseObject(arr, base)
   19608             :  */
   19609             : 
   19610             :   /* function exit code */
   19611             :   goto __pyx_L0;
   19612             :   __pyx_L1_error:;
   19613             :   __Pyx_AddTraceback("numpy.set_array_base", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19614             :   __pyx_L0:;
   19615             : }
   19616             : 
   19617             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1013
   19618             :  *     PyArray_SetBaseObject(arr, base)
   19619             :  * 
   19620             :  * cdef inline object get_array_base(ndarray arr):             # <<<<<<<<<<<<<<
   19621             :  *     base = PyArray_BASE(arr)
   19622             :  *     if base is NULL:
   19623             :  */
   19624             : 
   19625             : static CYTHON_INLINE PyObject *__pyx_f_5numpy_get_array_base(PyArrayObject *__pyx_v_arr) {
   19626             :   PyObject *__pyx_v_base;
   19627             :   PyObject *__pyx_r = NULL;
   19628             :   __Pyx_RefNannyDeclarations
   19629             :   int __pyx_t_1;
   19630             :   __Pyx_RefNannySetupContext("get_array_base", 1);
   19631             : 
   19632             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1014
   19633             :  * 
   19634             :  * cdef inline object get_array_base(ndarray arr):
   19635             :  *     base = PyArray_BASE(arr)             # <<<<<<<<<<<<<<
   19636             :  *     if base is NULL:
   19637             :  *         return None
   19638             :  */
   19639             :   __pyx_v_base = PyArray_BASE(__pyx_v_arr);
   19640             : 
   19641             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1015
   19642             :  * cdef inline object get_array_base(ndarray arr):
   19643             :  *     base = PyArray_BASE(arr)
   19644             :  *     if base is NULL:             # <<<<<<<<<<<<<<
   19645             :  *         return None
   19646             :  *     return <object>base
   19647             :  */
   19648             :   __pyx_t_1 = (__pyx_v_base == NULL);
   19649             :   if (__pyx_t_1) {
   19650             : 
   19651             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1016
   19652             :  *     base = PyArray_BASE(arr)
   19653             :  *     if base is NULL:
   19654             :  *         return None             # <<<<<<<<<<<<<<
   19655             :  *     return <object>base
   19656             :  * 
   19657             :  */
   19658             :     __Pyx_XDECREF(__pyx_r);
   19659             :     __pyx_r = Py_None; __Pyx_INCREF(Py_None);
   19660             :     goto __pyx_L0;
   19661             : 
   19662             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1015
   19663             :  * cdef inline object get_array_base(ndarray arr):
   19664             :  *     base = PyArray_BASE(arr)
   19665             :  *     if base is NULL:             # <<<<<<<<<<<<<<
   19666             :  *         return None
   19667             :  *     return <object>base
   19668             :  */
   19669             :   }
   19670             : 
   19671             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1017
   19672             :  *     if base is NULL:
   19673             :  *         return None
   19674             :  *     return <object>base             # <<<<<<<<<<<<<<
   19675             :  * 
   19676             :  * # Versions of the import_* functions which are more suitable for
   19677             :  */
   19678             :   __Pyx_XDECREF(__pyx_r);
   19679             :   __Pyx_INCREF(((PyObject *)__pyx_v_base));
   19680             :   __pyx_r = ((PyObject *)__pyx_v_base);
   19681             :   goto __pyx_L0;
   19682             : 
   19683             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1013
   19684             :  *     PyArray_SetBaseObject(arr, base)
   19685             :  * 
   19686             :  * cdef inline object get_array_base(ndarray arr):             # <<<<<<<<<<<<<<
   19687             :  *     base = PyArray_BASE(arr)
   19688             :  *     if base is NULL:
   19689             :  */
   19690             : 
   19691             :   /* function exit code */
   19692             :   __pyx_L0:;
   19693             :   __Pyx_XGIVEREF(__pyx_r);
   19694             :   __Pyx_RefNannyFinishContext();
   19695             :   return __pyx_r;
   19696             : }
   19697             : 
   19698             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1021
   19699             :  * # Versions of the import_* functions which are more suitable for
   19700             :  * # Cython code.
   19701             :  * cdef inline int import_array() except -1:             # <<<<<<<<<<<<<<
   19702             :  *     try:
   19703             :  *         __pyx_import_array()
   19704             :  */
   19705             : 
   19706           3 : static CYTHON_INLINE int __pyx_f_5numpy_import_array(void) {
   19707           3 :   int __pyx_r;
   19708             :   __Pyx_RefNannyDeclarations
   19709           3 :   PyObject *__pyx_t_1 = NULL;
   19710           3 :   PyObject *__pyx_t_2 = NULL;
   19711           3 :   PyObject *__pyx_t_3 = NULL;
   19712           3 :   int __pyx_t_4;
   19713           3 :   PyObject *__pyx_t_5 = NULL;
   19714           3 :   PyObject *__pyx_t_6 = NULL;
   19715           3 :   PyObject *__pyx_t_7 = NULL;
   19716           3 :   PyObject *__pyx_t_8 = NULL;
   19717           3 :   int __pyx_lineno = 0;
   19718           3 :   const char *__pyx_filename = NULL;
   19719           3 :   int __pyx_clineno = 0;
   19720           3 :   __Pyx_RefNannySetupContext("import_array", 1);
   19721             : 
   19722             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1022
   19723             :  * # Cython code.
   19724             :  * cdef inline int import_array() except -1:
   19725             :  *     try:             # <<<<<<<<<<<<<<
   19726             :  *         __pyx_import_array()
   19727             :  *     except Exception:
   19728             :  */
   19729             :   {
   19730           3 :     __Pyx_PyThreadState_declare
   19731           3 :     __Pyx_PyThreadState_assign
   19732           3 :     __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
   19733           3 :     __Pyx_XGOTREF(__pyx_t_1);
   19734           3 :     __Pyx_XGOTREF(__pyx_t_2);
   19735           3 :     __Pyx_XGOTREF(__pyx_t_3);
   19736             :     /*try:*/ {
   19737             : 
   19738             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1023
   19739             :  * cdef inline int import_array() except -1:
   19740             :  *     try:
   19741             :  *         __pyx_import_array()             # <<<<<<<<<<<<<<
   19742             :  *     except Exception:
   19743             :  *         raise ImportError("numpy._core.multiarray failed to import")
   19744             :  */
   19745           3 :       __pyx_t_4 = _import_array(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 1023, __pyx_L3_error)
   19746             : 
   19747             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1022
   19748             :  * # Cython code.
   19749             :  * cdef inline int import_array() except -1:
   19750             :  *     try:             # <<<<<<<<<<<<<<
   19751             :  *         __pyx_import_array()
   19752             :  *     except Exception:
   19753             :  */
   19754             :     }
   19755           3 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   19756           3 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   19757           3 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   19758           3 :     goto __pyx_L8_try_end;
   19759           0 :     __pyx_L3_error:;
   19760             : 
   19761             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1024
   19762             :  *     try:
   19763             :  *         __pyx_import_array()
   19764             :  *     except Exception:             # <<<<<<<<<<<<<<
   19765             :  *         raise ImportError("numpy._core.multiarray failed to import")
   19766             :  * 
   19767             :  */
   19768           0 :     __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
   19769           0 :     if (__pyx_t_4) {
   19770           0 :       __Pyx_AddTraceback("numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19771           0 :       if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 1024, __pyx_L5_except_error)
   19772           0 :       __Pyx_XGOTREF(__pyx_t_5);
   19773           0 :       __Pyx_XGOTREF(__pyx_t_6);
   19774           0 :       __Pyx_XGOTREF(__pyx_t_7);
   19775             : 
   19776             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1025
   19777             :  *         __pyx_import_array()
   19778             :  *     except Exception:
   19779             :  *         raise ImportError("numpy._core.multiarray failed to import")             # <<<<<<<<<<<<<<
   19780             :  * 
   19781             :  * cdef inline int import_umath() except -1:
   19782             :  */
   19783           0 :       __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__9, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1025, __pyx_L5_except_error)
   19784           0 :       __Pyx_GOTREF(__pyx_t_8);
   19785           0 :       __Pyx_Raise(__pyx_t_8, 0, 0, 0);
   19786           0 :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   19787           0 :       __PYX_ERR(2, 1025, __pyx_L5_except_error)
   19788             :     }
   19789           0 :     goto __pyx_L5_except_error;
   19790             : 
   19791             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1022
   19792             :  * # Cython code.
   19793             :  * cdef inline int import_array() except -1:
   19794             :  *     try:             # <<<<<<<<<<<<<<
   19795             :  *         __pyx_import_array()
   19796             :  *     except Exception:
   19797             :  */
   19798           0 :     __pyx_L5_except_error:;
   19799           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   19800           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   19801           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   19802           0 :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   19803           0 :     goto __pyx_L1_error;
   19804           3 :     __pyx_L8_try_end:;
   19805             :   }
   19806             : 
   19807             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1021
   19808             :  * # Versions of the import_* functions which are more suitable for
   19809             :  * # Cython code.
   19810             :  * cdef inline int import_array() except -1:             # <<<<<<<<<<<<<<
   19811             :  *     try:
   19812             :  *         __pyx_import_array()
   19813             :  */
   19814             : 
   19815             :   /* function exit code */
   19816           3 :   __pyx_r = 0;
   19817           3 :   goto __pyx_L0;
   19818           0 :   __pyx_L1_error:;
   19819           0 :   __Pyx_XDECREF(__pyx_t_5);
   19820           0 :   __Pyx_XDECREF(__pyx_t_6);
   19821           0 :   __Pyx_XDECREF(__pyx_t_7);
   19822           0 :   __Pyx_XDECREF(__pyx_t_8);
   19823           0 :   __Pyx_AddTraceback("numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19824           0 :   __pyx_r = -1;
   19825           3 :   __pyx_L0:;
   19826           3 :   __Pyx_RefNannyFinishContext();
   19827           3 :   return __pyx_r;
   19828             : }
   19829             : 
   19830             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1027
   19831             :  *         raise ImportError("numpy._core.multiarray failed to import")
   19832             :  * 
   19833             :  * cdef inline int import_umath() except -1:             # <<<<<<<<<<<<<<
   19834             :  *     try:
   19835             :  *         _import_umath()
   19836             :  */
   19837             : 
   19838             : static CYTHON_INLINE int __pyx_f_5numpy_import_umath(void) {
   19839             :   int __pyx_r;
   19840             :   __Pyx_RefNannyDeclarations
   19841             :   PyObject *__pyx_t_1 = NULL;
   19842             :   PyObject *__pyx_t_2 = NULL;
   19843             :   PyObject *__pyx_t_3 = NULL;
   19844             :   int __pyx_t_4;
   19845             :   PyObject *__pyx_t_5 = NULL;
   19846             :   PyObject *__pyx_t_6 = NULL;
   19847             :   PyObject *__pyx_t_7 = NULL;
   19848             :   PyObject *__pyx_t_8 = NULL;
   19849             :   int __pyx_lineno = 0;
   19850             :   const char *__pyx_filename = NULL;
   19851             :   int __pyx_clineno = 0;
   19852             :   __Pyx_RefNannySetupContext("import_umath", 1);
   19853             : 
   19854             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1028
   19855             :  * 
   19856             :  * cdef inline int import_umath() except -1:
   19857             :  *     try:             # <<<<<<<<<<<<<<
   19858             :  *         _import_umath()
   19859             :  *     except Exception:
   19860             :  */
   19861             :   {
   19862             :     __Pyx_PyThreadState_declare
   19863             :     __Pyx_PyThreadState_assign
   19864             :     __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
   19865             :     __Pyx_XGOTREF(__pyx_t_1);
   19866             :     __Pyx_XGOTREF(__pyx_t_2);
   19867             :     __Pyx_XGOTREF(__pyx_t_3);
   19868             :     /*try:*/ {
   19869             : 
   19870             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1029
   19871             :  * cdef inline int import_umath() except -1:
   19872             :  *     try:
   19873             :  *         _import_umath()             # <<<<<<<<<<<<<<
   19874             :  *     except Exception:
   19875             :  *         raise ImportError("numpy._core.umath failed to import")
   19876             :  */
   19877             :       __pyx_t_4 = _import_umath(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 1029, __pyx_L3_error)
   19878             : 
   19879             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1028
   19880             :  * 
   19881             :  * cdef inline int import_umath() except -1:
   19882             :  *     try:             # <<<<<<<<<<<<<<
   19883             :  *         _import_umath()
   19884             :  *     except Exception:
   19885             :  */
   19886             :     }
   19887             :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   19888             :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   19889             :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   19890             :     goto __pyx_L8_try_end;
   19891             :     __pyx_L3_error:;
   19892             : 
   19893             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1030
   19894             :  *     try:
   19895             :  *         _import_umath()
   19896             :  *     except Exception:             # <<<<<<<<<<<<<<
   19897             :  *         raise ImportError("numpy._core.umath failed to import")
   19898             :  * 
   19899             :  */
   19900             :     __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
   19901             :     if (__pyx_t_4) {
   19902             :       __Pyx_AddTraceback("numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19903             :       if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 1030, __pyx_L5_except_error)
   19904             :       __Pyx_XGOTREF(__pyx_t_5);
   19905             :       __Pyx_XGOTREF(__pyx_t_6);
   19906             :       __Pyx_XGOTREF(__pyx_t_7);
   19907             : 
   19908             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1031
   19909             :  *         _import_umath()
   19910             :  *     except Exception:
   19911             :  *         raise ImportError("numpy._core.umath failed to import")             # <<<<<<<<<<<<<<
   19912             :  * 
   19913             :  * cdef inline int import_ufunc() except -1:
   19914             :  */
   19915             :       __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__10, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1031, __pyx_L5_except_error)
   19916             :       __Pyx_GOTREF(__pyx_t_8);
   19917             :       __Pyx_Raise(__pyx_t_8, 0, 0, 0);
   19918             :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   19919             :       __PYX_ERR(2, 1031, __pyx_L5_except_error)
   19920             :     }
   19921             :     goto __pyx_L5_except_error;
   19922             : 
   19923             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1028
   19924             :  * 
   19925             :  * cdef inline int import_umath() except -1:
   19926             :  *     try:             # <<<<<<<<<<<<<<
   19927             :  *         _import_umath()
   19928             :  *     except Exception:
   19929             :  */
   19930             :     __pyx_L5_except_error:;
   19931             :     __Pyx_XGIVEREF(__pyx_t_1);
   19932             :     __Pyx_XGIVEREF(__pyx_t_2);
   19933             :     __Pyx_XGIVEREF(__pyx_t_3);
   19934             :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   19935             :     goto __pyx_L1_error;
   19936             :     __pyx_L8_try_end:;
   19937             :   }
   19938             : 
   19939             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1027
   19940             :  *         raise ImportError("numpy._core.multiarray failed to import")
   19941             :  * 
   19942             :  * cdef inline int import_umath() except -1:             # <<<<<<<<<<<<<<
   19943             :  *     try:
   19944             :  *         _import_umath()
   19945             :  */
   19946             : 
   19947             :   /* function exit code */
   19948             :   __pyx_r = 0;
   19949             :   goto __pyx_L0;
   19950             :   __pyx_L1_error:;
   19951             :   __Pyx_XDECREF(__pyx_t_5);
   19952             :   __Pyx_XDECREF(__pyx_t_6);
   19953             :   __Pyx_XDECREF(__pyx_t_7);
   19954             :   __Pyx_XDECREF(__pyx_t_8);
   19955             :   __Pyx_AddTraceback("numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
   19956             :   __pyx_r = -1;
   19957             :   __pyx_L0:;
   19958             :   __Pyx_RefNannyFinishContext();
   19959             :   return __pyx_r;
   19960             : }
   19961             : 
   19962             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1033
   19963             :  *         raise ImportError("numpy._core.umath failed to import")
   19964             :  * 
   19965             :  * cdef inline int import_ufunc() except -1:             # <<<<<<<<<<<<<<
   19966             :  *     try:
   19967             :  *         _import_umath()
   19968             :  */
   19969             : 
   19970             : static CYTHON_INLINE int __pyx_f_5numpy_import_ufunc(void) {
   19971             :   int __pyx_r;
   19972             :   __Pyx_RefNannyDeclarations
   19973             :   PyObject *__pyx_t_1 = NULL;
   19974             :   PyObject *__pyx_t_2 = NULL;
   19975             :   PyObject *__pyx_t_3 = NULL;
   19976             :   int __pyx_t_4;
   19977             :   PyObject *__pyx_t_5 = NULL;
   19978             :   PyObject *__pyx_t_6 = NULL;
   19979             :   PyObject *__pyx_t_7 = NULL;
   19980             :   PyObject *__pyx_t_8 = NULL;
   19981             :   int __pyx_lineno = 0;
   19982             :   const char *__pyx_filename = NULL;
   19983             :   int __pyx_clineno = 0;
   19984             :   __Pyx_RefNannySetupContext("import_ufunc", 1);
   19985             : 
   19986             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1034
   19987             :  * 
   19988             :  * cdef inline int import_ufunc() except -1:
   19989             :  *     try:             # <<<<<<<<<<<<<<
   19990             :  *         _import_umath()
   19991             :  *     except Exception:
   19992             :  */
   19993             :   {
   19994             :     __Pyx_PyThreadState_declare
   19995             :     __Pyx_PyThreadState_assign
   19996             :     __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
   19997             :     __Pyx_XGOTREF(__pyx_t_1);
   19998             :     __Pyx_XGOTREF(__pyx_t_2);
   19999             :     __Pyx_XGOTREF(__pyx_t_3);
   20000             :     /*try:*/ {
   20001             : 
   20002             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1035
   20003             :  * cdef inline int import_ufunc() except -1:
   20004             :  *     try:
   20005             :  *         _import_umath()             # <<<<<<<<<<<<<<
   20006             :  *     except Exception:
   20007             :  *         raise ImportError("numpy._core.umath failed to import")
   20008             :  */
   20009             :       __pyx_t_4 = _import_umath(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 1035, __pyx_L3_error)
   20010             : 
   20011             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1034
   20012             :  * 
   20013             :  * cdef inline int import_ufunc() except -1:
   20014             :  *     try:             # <<<<<<<<<<<<<<
   20015             :  *         _import_umath()
   20016             :  *     except Exception:
   20017             :  */
   20018             :     }
   20019             :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   20020             :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   20021             :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   20022             :     goto __pyx_L8_try_end;
   20023             :     __pyx_L3_error:;
   20024             : 
   20025             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1036
   20026             :  *     try:
   20027             :  *         _import_umath()
   20028             :  *     except Exception:             # <<<<<<<<<<<<<<
   20029             :  *         raise ImportError("numpy._core.umath failed to import")
   20030             :  * 
   20031             :  */
   20032             :     __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
   20033             :     if (__pyx_t_4) {
   20034             :       __Pyx_AddTraceback("numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
   20035             :       if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 1036, __pyx_L5_except_error)
   20036             :       __Pyx_XGOTREF(__pyx_t_5);
   20037             :       __Pyx_XGOTREF(__pyx_t_6);
   20038             :       __Pyx_XGOTREF(__pyx_t_7);
   20039             : 
   20040             :       /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1037
   20041             :  *         _import_umath()
   20042             :  *     except Exception:
   20043             :  *         raise ImportError("numpy._core.umath failed to import")             # <<<<<<<<<<<<<<
   20044             :  * 
   20045             :  * 
   20046             :  */
   20047             :       __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__10, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 1037, __pyx_L5_except_error)
   20048             :       __Pyx_GOTREF(__pyx_t_8);
   20049             :       __Pyx_Raise(__pyx_t_8, 0, 0, 0);
   20050             :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   20051             :       __PYX_ERR(2, 1037, __pyx_L5_except_error)
   20052             :     }
   20053             :     goto __pyx_L5_except_error;
   20054             : 
   20055             :     /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1034
   20056             :  * 
   20057             :  * cdef inline int import_ufunc() except -1:
   20058             :  *     try:             # <<<<<<<<<<<<<<
   20059             :  *         _import_umath()
   20060             :  *     except Exception:
   20061             :  */
   20062             :     __pyx_L5_except_error:;
   20063             :     __Pyx_XGIVEREF(__pyx_t_1);
   20064             :     __Pyx_XGIVEREF(__pyx_t_2);
   20065             :     __Pyx_XGIVEREF(__pyx_t_3);
   20066             :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   20067             :     goto __pyx_L1_error;
   20068             :     __pyx_L8_try_end:;
   20069             :   }
   20070             : 
   20071             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1033
   20072             :  *         raise ImportError("numpy._core.umath failed to import")
   20073             :  * 
   20074             :  * cdef inline int import_ufunc() except -1:             # <<<<<<<<<<<<<<
   20075             :  *     try:
   20076             :  *         _import_umath()
   20077             :  */
   20078             : 
   20079             :   /* function exit code */
   20080             :   __pyx_r = 0;
   20081             :   goto __pyx_L0;
   20082             :   __pyx_L1_error:;
   20083             :   __Pyx_XDECREF(__pyx_t_5);
   20084             :   __Pyx_XDECREF(__pyx_t_6);
   20085             :   __Pyx_XDECREF(__pyx_t_7);
   20086             :   __Pyx_XDECREF(__pyx_t_8);
   20087             :   __Pyx_AddTraceback("numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
   20088             :   __pyx_r = -1;
   20089             :   __pyx_L0:;
   20090             :   __Pyx_RefNannyFinishContext();
   20091             :   return __pyx_r;
   20092             : }
   20093             : 
   20094             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1040
   20095             :  * 
   20096             :  * 
   20097             :  * cdef inline bint is_timedelta64_object(object obj) noexcept:             # <<<<<<<<<<<<<<
   20098             :  *     """
   20099             :  *     Cython equivalent of `isinstance(obj, np.timedelta64)`
   20100             :  */
   20101             : 
   20102             : static CYTHON_INLINE int __pyx_f_5numpy_is_timedelta64_object(PyObject *__pyx_v_obj) {
   20103             :   int __pyx_r;
   20104             : 
   20105             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1052
   20106             :  *     bool
   20107             :  *     """
   20108             :  *     return PyObject_TypeCheck(obj, &PyTimedeltaArrType_Type)             # <<<<<<<<<<<<<<
   20109             :  * 
   20110             :  * 
   20111             :  */
   20112             :   __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyTimedeltaArrType_Type));
   20113             :   goto __pyx_L0;
   20114             : 
   20115             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1040
   20116             :  * 
   20117             :  * 
   20118             :  * cdef inline bint is_timedelta64_object(object obj) noexcept:             # <<<<<<<<<<<<<<
   20119             :  *     """
   20120             :  *     Cython equivalent of `isinstance(obj, np.timedelta64)`
   20121             :  */
   20122             : 
   20123             :   /* function exit code */
   20124             :   __pyx_L0:;
   20125             :   return __pyx_r;
   20126             : }
   20127             : 
   20128             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1055
   20129             :  * 
   20130             :  * 
   20131             :  * cdef inline bint is_datetime64_object(object obj) noexcept:             # <<<<<<<<<<<<<<
   20132             :  *     """
   20133             :  *     Cython equivalent of `isinstance(obj, np.datetime64)`
   20134             :  */
   20135             : 
   20136             : static CYTHON_INLINE int __pyx_f_5numpy_is_datetime64_object(PyObject *__pyx_v_obj) {
   20137             :   int __pyx_r;
   20138             : 
   20139             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1067
   20140             :  *     bool
   20141             :  *     """
   20142             :  *     return PyObject_TypeCheck(obj, &PyDatetimeArrType_Type)             # <<<<<<<<<<<<<<
   20143             :  * 
   20144             :  * 
   20145             :  */
   20146             :   __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyDatetimeArrType_Type));
   20147             :   goto __pyx_L0;
   20148             : 
   20149             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1055
   20150             :  * 
   20151             :  * 
   20152             :  * cdef inline bint is_datetime64_object(object obj) noexcept:             # <<<<<<<<<<<<<<
   20153             :  *     """
   20154             :  *     Cython equivalent of `isinstance(obj, np.datetime64)`
   20155             :  */
   20156             : 
   20157             :   /* function exit code */
   20158             :   __pyx_L0:;
   20159             :   return __pyx_r;
   20160             : }
   20161             : 
   20162             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1070
   20163             :  * 
   20164             :  * 
   20165             :  * cdef inline npy_datetime get_datetime64_value(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20166             :  *     """
   20167             :  *     returns the int64 value underlying scalar numpy datetime64 object
   20168             :  */
   20169             : 
   20170             : static CYTHON_INLINE npy_datetime __pyx_f_5numpy_get_datetime64_value(PyObject *__pyx_v_obj) {
   20171             :   npy_datetime __pyx_r;
   20172             : 
   20173             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1077
   20174             :  *     also needed.  That can be found using `get_datetime64_unit`.
   20175             :  *     """
   20176             :  *     return (<PyDatetimeScalarObject*>obj).obval             # <<<<<<<<<<<<<<
   20177             :  * 
   20178             :  * 
   20179             :  */
   20180             :   __pyx_r = ((PyDatetimeScalarObject *)__pyx_v_obj)->obval;
   20181             :   goto __pyx_L0;
   20182             : 
   20183             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1070
   20184             :  * 
   20185             :  * 
   20186             :  * cdef inline npy_datetime get_datetime64_value(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20187             :  *     """
   20188             :  *     returns the int64 value underlying scalar numpy datetime64 object
   20189             :  */
   20190             : 
   20191             :   /* function exit code */
   20192             :   __pyx_L0:;
   20193             :   return __pyx_r;
   20194             : }
   20195             : 
   20196             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1080
   20197             :  * 
   20198             :  * 
   20199             :  * cdef inline npy_timedelta get_timedelta64_value(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20200             :  *     """
   20201             :  *     returns the int64 value underlying scalar numpy timedelta64 object
   20202             :  */
   20203             : 
   20204             : static CYTHON_INLINE npy_timedelta __pyx_f_5numpy_get_timedelta64_value(PyObject *__pyx_v_obj) {
   20205             :   npy_timedelta __pyx_r;
   20206             : 
   20207             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1084
   20208             :  *     returns the int64 value underlying scalar numpy timedelta64 object
   20209             :  *     """
   20210             :  *     return (<PyTimedeltaScalarObject*>obj).obval             # <<<<<<<<<<<<<<
   20211             :  * 
   20212             :  * 
   20213             :  */
   20214             :   __pyx_r = ((PyTimedeltaScalarObject *)__pyx_v_obj)->obval;
   20215             :   goto __pyx_L0;
   20216             : 
   20217             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1080
   20218             :  * 
   20219             :  * 
   20220             :  * cdef inline npy_timedelta get_timedelta64_value(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20221             :  *     """
   20222             :  *     returns the int64 value underlying scalar numpy timedelta64 object
   20223             :  */
   20224             : 
   20225             :   /* function exit code */
   20226             :   __pyx_L0:;
   20227             :   return __pyx_r;
   20228             : }
   20229             : 
   20230             : /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1087
   20231             :  * 
   20232             :  * 
   20233             :  * cdef inline NPY_DATETIMEUNIT get_datetime64_unit(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20234             :  *     """
   20235             :  *     returns the unit part of the dtype for a numpy datetime64 object.
   20236             :  */
   20237             : 
   20238             : static CYTHON_INLINE NPY_DATETIMEUNIT __pyx_f_5numpy_get_datetime64_unit(PyObject *__pyx_v_obj) {
   20239             :   NPY_DATETIMEUNIT __pyx_r;
   20240             : 
   20241             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1091
   20242             :  *     returns the unit part of the dtype for a numpy datetime64 object.
   20243             :  *     """
   20244             :  *     return <NPY_DATETIMEUNIT>(<PyDatetimeScalarObject*>obj).obmeta.base             # <<<<<<<<<<<<<<
   20245             :  * 
   20246             :  * 
   20247             :  */
   20248             :   __pyx_r = ((NPY_DATETIMEUNIT)((PyDatetimeScalarObject *)__pyx_v_obj)->obmeta.base);
   20249             :   goto __pyx_L0;
   20250             : 
   20251             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1087
   20252             :  * 
   20253             :  * 
   20254             :  * cdef inline NPY_DATETIMEUNIT get_datetime64_unit(object obj) noexcept nogil:             # <<<<<<<<<<<<<<
   20255             :  *     """
   20256             :  *     returns the unit part of the dtype for a numpy datetime64 object.
   20257             :  */
   20258             : 
   20259             :   /* function exit code */
   20260             :   __pyx_L0:;
   20261             :   return __pyx_r;
   20262             : }
   20263             : 
   20264             : /* "_ni_label.pyx":54
   20265             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20266             :  * ######################################################################
   20267             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20268             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20269             :  *     cdef np.intp_t i
   20270             :  */
   20271             : 
   20272          21 : static void __pyx_fuse_0__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20273          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20274          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20275          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20276          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20277          21 :   int __pyx_t_4;
   20278          21 :   int __pyx_t_5;
   20279             : 
   20280             :   /* "_ni_label.pyx":57
   20281             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20282             :  *     cdef np.intp_t i
   20283             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20284             :  *         line[i] = FOREGROUND if \
   20285             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20286             :  */
   20287          21 :   __pyx_t_1 = __pyx_v_L;
   20288          21 :   __pyx_t_2 = __pyx_t_1;
   20289         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20290         146 :     __pyx_v_i = __pyx_t_3;
   20291             : 
   20292             :     /* "_ni_label.pyx":59
   20293             :  *     for i in range(L):
   20294             :  *         line[i] = FOREGROUND if \
   20295             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20296             :  *             else BACKGROUND
   20297             :  * 
   20298             :  */
   20299         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_int8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20300         146 :     if (__pyx_t_5) {
   20301             : 
   20302             :       /* "_ni_label.pyx":58
   20303             :  *     cdef np.intp_t i
   20304             :  *     for i in range(L):
   20305             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20306             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20307             :  *             else BACKGROUND
   20308             :  */
   20309             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20310             :     } else {
   20311             : 
   20312             :       /* "_ni_label.pyx":60
   20313             :  *         line[i] = FOREGROUND if \
   20314             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20315             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20316             :  * 
   20317             :  * 
   20318             :  */
   20319          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20320             :     }
   20321             : 
   20322             :     /* "_ni_label.pyx":58
   20323             :  *     cdef np.intp_t i
   20324             :  *     for i in range(L):
   20325             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20326             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20327             :  *             else BACKGROUND
   20328             :  */
   20329         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20330             :   }
   20331             : 
   20332             :   /* "_ni_label.pyx":54
   20333             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20334             :  * ######################################################################
   20335             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20336             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20337             :  *     cdef np.intp_t i
   20338             :  */
   20339             : 
   20340             :   /* function exit code */
   20341          21 : }
   20342             : 
   20343          21 : static void __pyx_fuse_1__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20344          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20345          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20346          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20347          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20348          21 :   int __pyx_t_4;
   20349          21 :   int __pyx_t_5;
   20350             : 
   20351             :   /* "_ni_label.pyx":57
   20352             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20353             :  *     cdef np.intp_t i
   20354             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20355             :  *         line[i] = FOREGROUND if \
   20356             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20357             :  */
   20358          21 :   __pyx_t_1 = __pyx_v_L;
   20359          21 :   __pyx_t_2 = __pyx_t_1;
   20360         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20361         146 :     __pyx_v_i = __pyx_t_3;
   20362             : 
   20363             :     /* "_ni_label.pyx":59
   20364             :  *     for i in range(L):
   20365             :  *         line[i] = FOREGROUND if \
   20366             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20367             :  *             else BACKGROUND
   20368             :  * 
   20369             :  */
   20370         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_int16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20371         146 :     if (__pyx_t_5) {
   20372             : 
   20373             :       /* "_ni_label.pyx":58
   20374             :  *     cdef np.intp_t i
   20375             :  *     for i in range(L):
   20376             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20377             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20378             :  *             else BACKGROUND
   20379             :  */
   20380             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20381             :     } else {
   20382             : 
   20383             :       /* "_ni_label.pyx":60
   20384             :  *         line[i] = FOREGROUND if \
   20385             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20386             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20387             :  * 
   20388             :  * 
   20389             :  */
   20390          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20391             :     }
   20392             : 
   20393             :     /* "_ni_label.pyx":58
   20394             :  *     cdef np.intp_t i
   20395             :  *     for i in range(L):
   20396             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20397             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20398             :  *             else BACKGROUND
   20399             :  */
   20400         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20401             :   }
   20402             : 
   20403             :   /* "_ni_label.pyx":54
   20404             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20405             :  * ######################################################################
   20406             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20407             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20408             :  *     cdef np.intp_t i
   20409             :  */
   20410             : 
   20411             :   /* function exit code */
   20412          21 : }
   20413             : 
   20414          21 : static void __pyx_fuse_2__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20415          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20416          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20417          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20418          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20419          21 :   int __pyx_t_4;
   20420          21 :   int __pyx_t_5;
   20421             : 
   20422             :   /* "_ni_label.pyx":57
   20423             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20424             :  *     cdef np.intp_t i
   20425             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20426             :  *         line[i] = FOREGROUND if \
   20427             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20428             :  */
   20429          21 :   __pyx_t_1 = __pyx_v_L;
   20430          21 :   __pyx_t_2 = __pyx_t_1;
   20431         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20432         146 :     __pyx_v_i = __pyx_t_3;
   20433             : 
   20434             :     /* "_ni_label.pyx":59
   20435             :  *     for i in range(L):
   20436             :  *         line[i] = FOREGROUND if \
   20437             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20438             :  *             else BACKGROUND
   20439             :  * 
   20440             :  */
   20441         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_int32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20442         146 :     if (__pyx_t_5) {
   20443             : 
   20444             :       /* "_ni_label.pyx":58
   20445             :  *     cdef np.intp_t i
   20446             :  *     for i in range(L):
   20447             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20448             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20449             :  *             else BACKGROUND
   20450             :  */
   20451             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20452             :     } else {
   20453             : 
   20454             :       /* "_ni_label.pyx":60
   20455             :  *         line[i] = FOREGROUND if \
   20456             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20457             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20458             :  * 
   20459             :  * 
   20460             :  */
   20461          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20462             :     }
   20463             : 
   20464             :     /* "_ni_label.pyx":58
   20465             :  *     cdef np.intp_t i
   20466             :  *     for i in range(L):
   20467             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20468             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20469             :  *             else BACKGROUND
   20470             :  */
   20471         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20472             :   }
   20473             : 
   20474             :   /* "_ni_label.pyx":54
   20475             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20476             :  * ######################################################################
   20477             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20478             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20479             :  *     cdef np.intp_t i
   20480             :  */
   20481             : 
   20482             :   /* function exit code */
   20483          21 : }
   20484             : 
   20485          44 : static void __pyx_fuse_3__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_int64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20486          44 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20487          44 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20488          44 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20489          44 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20490          44 :   int __pyx_t_4;
   20491          44 :   int __pyx_t_5;
   20492             : 
   20493             :   /* "_ni_label.pyx":57
   20494             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20495             :  *     cdef np.intp_t i
   20496             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20497             :  *         line[i] = FOREGROUND if \
   20498             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20499             :  */
   20500          44 :   __pyx_t_1 = __pyx_v_L;
   20501          44 :   __pyx_t_2 = __pyx_t_1;
   20502         328 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20503         284 :     __pyx_v_i = __pyx_t_3;
   20504             : 
   20505             :     /* "_ni_label.pyx":59
   20506             :  *     for i in range(L):
   20507             :  *         line[i] = FOREGROUND if \
   20508             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20509             :  *             else BACKGROUND
   20510             :  * 
   20511             :  */
   20512         284 :     __pyx_t_5 = ((((__pyx_t_5numpy_int64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20513         284 :     if (__pyx_t_5) {
   20514             : 
   20515             :       /* "_ni_label.pyx":58
   20516             :  *     cdef np.intp_t i
   20517             :  *     for i in range(L):
   20518             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20519             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20520             :  *             else BACKGROUND
   20521             :  */
   20522             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20523             :     } else {
   20524             : 
   20525             :       /* "_ni_label.pyx":60
   20526             :  *         line[i] = FOREGROUND if \
   20527             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20528             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20529             :  * 
   20530             :  * 
   20531             :  */
   20532         183 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20533             :     }
   20534             : 
   20535             :     /* "_ni_label.pyx":58
   20536             :  *     cdef np.intp_t i
   20537             :  *     for i in range(L):
   20538             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20539             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20540             :  *             else BACKGROUND
   20541             :  */
   20542         284 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20543             :   }
   20544             : 
   20545             :   /* "_ni_label.pyx":54
   20546             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20547             :  * ######################################################################
   20548             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20549             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20550             :  *     cdef np.intp_t i
   20551             :  */
   20552             : 
   20553             :   /* function exit code */
   20554          44 : }
   20555             : 
   20556        3871 : static void __pyx_fuse_4__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20557        3871 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20558        3871 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20559        3871 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20560        3871 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20561        3871 :   int __pyx_t_4;
   20562        3871 :   int __pyx_t_5;
   20563             : 
   20564             :   /* "_ni_label.pyx":57
   20565             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20566             :  *     cdef np.intp_t i
   20567             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20568             :  *         line[i] = FOREGROUND if \
   20569             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20570             :  */
   20571        3871 :   __pyx_t_1 = __pyx_v_L;
   20572        3871 :   __pyx_t_2 = __pyx_t_1;
   20573     4619317 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20574     4615446 :     __pyx_v_i = __pyx_t_3;
   20575             : 
   20576             :     /* "_ni_label.pyx":59
   20577             :  *     for i in range(L):
   20578             :  *         line[i] = FOREGROUND if \
   20579             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20580             :  *             else BACKGROUND
   20581             :  * 
   20582             :  */
   20583     4615446 :     __pyx_t_5 = ((((__pyx_t_5numpy_uint8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20584     4615446 :     if (__pyx_t_5) {
   20585             : 
   20586             :       /* "_ni_label.pyx":58
   20587             :  *     cdef np.intp_t i
   20588             :  *     for i in range(L):
   20589             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20590             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20591             :  *             else BACKGROUND
   20592             :  */
   20593             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20594             :     } else {
   20595             : 
   20596             :       /* "_ni_label.pyx":60
   20597             :  *         line[i] = FOREGROUND if \
   20598             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20599             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20600             :  * 
   20601             :  * 
   20602             :  */
   20603     3233120 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20604             :     }
   20605             : 
   20606             :     /* "_ni_label.pyx":58
   20607             :  *     cdef np.intp_t i
   20608             :  *     for i in range(L):
   20609             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20610             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20611             :  *             else BACKGROUND
   20612             :  */
   20613     4615446 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20614             :   }
   20615             : 
   20616             :   /* "_ni_label.pyx":54
   20617             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20618             :  * ######################################################################
   20619             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20620             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20621             :  *     cdef np.intp_t i
   20622             :  */
   20623             : 
   20624             :   /* function exit code */
   20625        3871 : }
   20626             : 
   20627          21 : static void __pyx_fuse_5__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20628          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20629          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20630          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20631          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20632          21 :   int __pyx_t_4;
   20633          21 :   int __pyx_t_5;
   20634             : 
   20635             :   /* "_ni_label.pyx":57
   20636             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20637             :  *     cdef np.intp_t i
   20638             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20639             :  *         line[i] = FOREGROUND if \
   20640             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20641             :  */
   20642          21 :   __pyx_t_1 = __pyx_v_L;
   20643          21 :   __pyx_t_2 = __pyx_t_1;
   20644         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20645         146 :     __pyx_v_i = __pyx_t_3;
   20646             : 
   20647             :     /* "_ni_label.pyx":59
   20648             :  *     for i in range(L):
   20649             :  *         line[i] = FOREGROUND if \
   20650             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20651             :  *             else BACKGROUND
   20652             :  * 
   20653             :  */
   20654         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_uint16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20655         146 :     if (__pyx_t_5) {
   20656             : 
   20657             :       /* "_ni_label.pyx":58
   20658             :  *     cdef np.intp_t i
   20659             :  *     for i in range(L):
   20660             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20661             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20662             :  *             else BACKGROUND
   20663             :  */
   20664             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20665             :     } else {
   20666             : 
   20667             :       /* "_ni_label.pyx":60
   20668             :  *         line[i] = FOREGROUND if \
   20669             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20670             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20671             :  * 
   20672             :  * 
   20673             :  */
   20674          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20675             :     }
   20676             : 
   20677             :     /* "_ni_label.pyx":58
   20678             :  *     cdef np.intp_t i
   20679             :  *     for i in range(L):
   20680             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20681             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20682             :  *             else BACKGROUND
   20683             :  */
   20684         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20685             :   }
   20686             : 
   20687             :   /* "_ni_label.pyx":54
   20688             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20689             :  * ######################################################################
   20690             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20691             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20692             :  *     cdef np.intp_t i
   20693             :  */
   20694             : 
   20695             :   /* function exit code */
   20696          21 : }
   20697             : 
   20698          21 : static void __pyx_fuse_6__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20699          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20700          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20701          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20702          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20703          21 :   int __pyx_t_4;
   20704          21 :   int __pyx_t_5;
   20705             : 
   20706             :   /* "_ni_label.pyx":57
   20707             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20708             :  *     cdef np.intp_t i
   20709             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20710             :  *         line[i] = FOREGROUND if \
   20711             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20712             :  */
   20713          21 :   __pyx_t_1 = __pyx_v_L;
   20714          21 :   __pyx_t_2 = __pyx_t_1;
   20715         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20716         146 :     __pyx_v_i = __pyx_t_3;
   20717             : 
   20718             :     /* "_ni_label.pyx":59
   20719             :  *     for i in range(L):
   20720             :  *         line[i] = FOREGROUND if \
   20721             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20722             :  *             else BACKGROUND
   20723             :  * 
   20724             :  */
   20725         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_uint32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20726         146 :     if (__pyx_t_5) {
   20727             : 
   20728             :       /* "_ni_label.pyx":58
   20729             :  *     cdef np.intp_t i
   20730             :  *     for i in range(L):
   20731             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20732             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20733             :  *             else BACKGROUND
   20734             :  */
   20735             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20736             :     } else {
   20737             : 
   20738             :       /* "_ni_label.pyx":60
   20739             :  *         line[i] = FOREGROUND if \
   20740             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20741             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20742             :  * 
   20743             :  * 
   20744             :  */
   20745          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20746             :     }
   20747             : 
   20748             :     /* "_ni_label.pyx":58
   20749             :  *     cdef np.intp_t i
   20750             :  *     for i in range(L):
   20751             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20752             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20753             :  *             else BACKGROUND
   20754             :  */
   20755         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20756             :   }
   20757             : 
   20758             :   /* "_ni_label.pyx":54
   20759             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20760             :  * ######################################################################
   20761             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20762             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20763             :  *     cdef np.intp_t i
   20764             :  */
   20765             : 
   20766             :   /* function exit code */
   20767          21 : }
   20768             : 
   20769          21 : static void __pyx_fuse_7__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_uint64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20770          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20771          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20772          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20773          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20774          21 :   int __pyx_t_4;
   20775          21 :   int __pyx_t_5;
   20776             : 
   20777             :   /* "_ni_label.pyx":57
   20778             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20779             :  *     cdef np.intp_t i
   20780             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20781             :  *         line[i] = FOREGROUND if \
   20782             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20783             :  */
   20784          21 :   __pyx_t_1 = __pyx_v_L;
   20785          21 :   __pyx_t_2 = __pyx_t_1;
   20786         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20787         146 :     __pyx_v_i = __pyx_t_3;
   20788             : 
   20789             :     /* "_ni_label.pyx":59
   20790             :  *     for i in range(L):
   20791             :  *         line[i] = FOREGROUND if \
   20792             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20793             :  *             else BACKGROUND
   20794             :  * 
   20795             :  */
   20796         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_uint64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20797         146 :     if (__pyx_t_5) {
   20798             : 
   20799             :       /* "_ni_label.pyx":58
   20800             :  *     cdef np.intp_t i
   20801             :  *     for i in range(L):
   20802             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20803             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20804             :  *             else BACKGROUND
   20805             :  */
   20806             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20807             :     } else {
   20808             : 
   20809             :       /* "_ni_label.pyx":60
   20810             :  *         line[i] = FOREGROUND if \
   20811             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20812             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20813             :  * 
   20814             :  * 
   20815             :  */
   20816          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20817             :     }
   20818             : 
   20819             :     /* "_ni_label.pyx":58
   20820             :  *     cdef np.intp_t i
   20821             :  *     for i in range(L):
   20822             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20823             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20824             :  *             else BACKGROUND
   20825             :  */
   20826         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20827             :   }
   20828             : 
   20829             :   /* "_ni_label.pyx":54
   20830             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20831             :  * ######################################################################
   20832             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20833             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20834             :  *     cdef np.intp_t i
   20835             :  */
   20836             : 
   20837             :   /* function exit code */
   20838          21 : }
   20839             : 
   20840          21 : static void __pyx_fuse_8__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_float32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20841          21 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20842          21 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20843          21 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20844          21 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20845          21 :   int __pyx_t_4;
   20846          21 :   int __pyx_t_5;
   20847             : 
   20848             :   /* "_ni_label.pyx":57
   20849             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20850             :  *     cdef np.intp_t i
   20851             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20852             :  *         line[i] = FOREGROUND if \
   20853             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20854             :  */
   20855          21 :   __pyx_t_1 = __pyx_v_L;
   20856          21 :   __pyx_t_2 = __pyx_t_1;
   20857         167 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20858         146 :     __pyx_v_i = __pyx_t_3;
   20859             : 
   20860             :     /* "_ni_label.pyx":59
   20861             :  *     for i in range(L):
   20862             :  *         line[i] = FOREGROUND if \
   20863             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20864             :  *             else BACKGROUND
   20865             :  * 
   20866             :  */
   20867         146 :     __pyx_t_5 = ((((__pyx_t_5numpy_float32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20868         146 :     if (__pyx_t_5) {
   20869             : 
   20870             :       /* "_ni_label.pyx":58
   20871             :  *     cdef np.intp_t i
   20872             :  *     for i in range(L):
   20873             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20874             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20875             :  *             else BACKGROUND
   20876             :  */
   20877             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20878             :     } else {
   20879             : 
   20880             :       /* "_ni_label.pyx":60
   20881             :  *         line[i] = FOREGROUND if \
   20882             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20883             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20884             :  * 
   20885             :  * 
   20886             :  */
   20887          80 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20888             :     }
   20889             : 
   20890             :     /* "_ni_label.pyx":58
   20891             :  *     cdef np.intp_t i
   20892             :  *     for i in range(L):
   20893             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20894             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20895             :  *             else BACKGROUND
   20896             :  */
   20897         146 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20898             :   }
   20899             : 
   20900             :   /* "_ni_label.pyx":54
   20901             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20902             :  * ######################################################################
   20903             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20904             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20905             :  *     cdef np.intp_t i
   20906             :  */
   20907             : 
   20908             :   /* function exit code */
   20909          21 : }
   20910             : 
   20911         398 : static void __pyx_fuse_9__pyx_f_9_ni_label_fused_nonzero_line(__pyx_t_5numpy_float64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20912         398 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20913         398 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20914         398 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20915         398 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20916         398 :   int __pyx_t_4;
   20917         398 :   int __pyx_t_5;
   20918             : 
   20919             :   /* "_ni_label.pyx":57
   20920             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20921             :  *     cdef np.intp_t i
   20922             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   20923             :  *         line[i] = FOREGROUND if \
   20924             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20925             :  */
   20926         398 :   __pyx_t_1 = __pyx_v_L;
   20927         398 :   __pyx_t_2 = __pyx_t_1;
   20928       21909 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   20929       21511 :     __pyx_v_i = __pyx_t_3;
   20930             : 
   20931             :     /* "_ni_label.pyx":59
   20932             :  *     for i in range(L):
   20933             :  *         line[i] = FOREGROUND if \
   20934             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \             # <<<<<<<<<<<<<<
   20935             :  *             else BACKGROUND
   20936             :  * 
   20937             :  */
   20938       21511 :     __pyx_t_5 = ((((__pyx_t_5numpy_float64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) != 0);
   20939       21511 :     if (__pyx_t_5) {
   20940             : 
   20941             :       /* "_ni_label.pyx":58
   20942             :  *     cdef np.intp_t i
   20943             :  *     for i in range(L):
   20944             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20945             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20946             :  *             else BACKGROUND
   20947             :  */
   20948             :       __pyx_t_4 = __pyx_e_9_ni_label_FOREGROUND;
   20949             :     } else {
   20950             : 
   20951             :       /* "_ni_label.pyx":60
   20952             :  *         line[i] = FOREGROUND if \
   20953             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20954             :  *             else BACKGROUND             # <<<<<<<<<<<<<<
   20955             :  * 
   20956             :  * 
   20957             :  */
   20958         874 :       __pyx_t_4 = __pyx_e_9_ni_label_BACKGROUND;
   20959             :     }
   20960             : 
   20961             :     /* "_ni_label.pyx":58
   20962             :  *     cdef np.intp_t i
   20963             :  *     for i in range(L):
   20964             :  *         line[i] = FOREGROUND if \             # <<<<<<<<<<<<<<
   20965             :  *             (<data_t *> ((<char *> p) + i * stride))[0] \
   20966             :  *             else BACKGROUND
   20967             :  */
   20968       21511 :     (__pyx_v_line[__pyx_v_i]) = __pyx_t_4;
   20969             :   }
   20970             : 
   20971             :   /* "_ni_label.pyx":54
   20972             :  * # the fused data is nonzero, BACKGROUND elsewhere
   20973             :  * ######################################################################
   20974             :  * cdef void fused_nonzero_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20975             :  *                              np.uintp_t *line, np.intp_t L) noexcept nogil:
   20976             :  *     cdef np.intp_t i
   20977             :  */
   20978             : 
   20979             :   /* function exit code */
   20980         398 : }
   20981             : 
   20982             : /* "_ni_label.pyx":66
   20983             :  * # Load a line from a fused data array to a np.uintp_t array
   20984             :  * ######################################################################
   20985             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   20986             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   20987             :  *     cdef np.intp_t i
   20988             :  */
   20989             : 
   20990           8 : static void __pyx_fuse_0__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   20991           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   20992           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   20993           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   20994           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   20995             : 
   20996             :   /* "_ni_label.pyx":69
   20997             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   20998             :  *     cdef np.intp_t i
   20999             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21000             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21001             :  * 
   21002             :  */
   21003           8 :   __pyx_t_1 = __pyx_v_L;
   21004           8 :   __pyx_t_2 = __pyx_t_1;
   21005          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21006          46 :     __pyx_v_i = __pyx_t_3;
   21007             : 
   21008             :     /* "_ni_label.pyx":70
   21009             :  *     cdef np.intp_t i
   21010             :  *     for i in range(L):
   21011             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21012             :  * 
   21013             :  * 
   21014             :  */
   21015          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_int8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21016             :   }
   21017             : 
   21018             :   /* "_ni_label.pyx":66
   21019             :  * # Load a line from a fused data array to a np.uintp_t array
   21020             :  * ######################################################################
   21021             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21022             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21023             :  *     cdef np.intp_t i
   21024             :  */
   21025             : 
   21026             :   /* function exit code */
   21027           8 : }
   21028             : 
   21029           8 : static void __pyx_fuse_1__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21030           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21031           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21032           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21033           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21034             : 
   21035             :   /* "_ni_label.pyx":69
   21036             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21037             :  *     cdef np.intp_t i
   21038             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21039             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21040             :  * 
   21041             :  */
   21042           8 :   __pyx_t_1 = __pyx_v_L;
   21043           8 :   __pyx_t_2 = __pyx_t_1;
   21044          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21045          46 :     __pyx_v_i = __pyx_t_3;
   21046             : 
   21047             :     /* "_ni_label.pyx":70
   21048             :  *     cdef np.intp_t i
   21049             :  *     for i in range(L):
   21050             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21051             :  * 
   21052             :  * 
   21053             :  */
   21054          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_int16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21055             :   }
   21056             : 
   21057             :   /* "_ni_label.pyx":66
   21058             :  * # Load a line from a fused data array to a np.uintp_t array
   21059             :  * ######################################################################
   21060             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21061             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21062             :  *     cdef np.intp_t i
   21063             :  */
   21064             : 
   21065             :   /* function exit code */
   21066           8 : }
   21067             : 
   21068       15541 : static void __pyx_fuse_2__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21069       15541 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21070       15541 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21071       15541 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21072       15541 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21073             : 
   21074             :   /* "_ni_label.pyx":69
   21075             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21076             :  *     cdef np.intp_t i
   21077             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21078             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21079             :  * 
   21080             :  */
   21081       15541 :   __pyx_t_1 = __pyx_v_L;
   21082       15541 :   __pyx_t_2 = __pyx_t_1;
   21083    18483110 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21084    18467569 :     __pyx_v_i = __pyx_t_3;
   21085             : 
   21086             :     /* "_ni_label.pyx":70
   21087             :  *     cdef np.intp_t i
   21088             :  *     for i in range(L):
   21089             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21090             :  * 
   21091             :  * 
   21092             :  */
   21093    18467569 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_int32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21094             :   }
   21095             : 
   21096             :   /* "_ni_label.pyx":66
   21097             :  * # Load a line from a fused data array to a np.uintp_t array
   21098             :  * ######################################################################
   21099             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21100             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21101             :  *     cdef np.intp_t i
   21102             :  */
   21103             : 
   21104             :   /* function exit code */
   21105       15541 : }
   21106             : 
   21107           8 : static void __pyx_fuse_3__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_int64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21108           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21109           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21110           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21111           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21112             : 
   21113             :   /* "_ni_label.pyx":69
   21114             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21115             :  *     cdef np.intp_t i
   21116             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21117             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21118             :  * 
   21119             :  */
   21120           8 :   __pyx_t_1 = __pyx_v_L;
   21121           8 :   __pyx_t_2 = __pyx_t_1;
   21122          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21123          46 :     __pyx_v_i = __pyx_t_3;
   21124             : 
   21125             :     /* "_ni_label.pyx":70
   21126             :  *     cdef np.intp_t i
   21127             :  *     for i in range(L):
   21128             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21129             :  * 
   21130             :  * 
   21131             :  */
   21132          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_int64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21133             :   }
   21134             : 
   21135             :   /* "_ni_label.pyx":66
   21136             :  * # Load a line from a fused data array to a np.uintp_t array
   21137             :  * ######################################################################
   21138             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21139             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21140             :  *     cdef np.intp_t i
   21141             :  */
   21142             : 
   21143             :   /* function exit code */
   21144           8 : }
   21145             : 
   21146           8 : static void __pyx_fuse_4__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21147           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21148           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21149           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21150           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21151             : 
   21152             :   /* "_ni_label.pyx":69
   21153             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21154             :  *     cdef np.intp_t i
   21155             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21156             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21157             :  * 
   21158             :  */
   21159           8 :   __pyx_t_1 = __pyx_v_L;
   21160           8 :   __pyx_t_2 = __pyx_t_1;
   21161          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21162          46 :     __pyx_v_i = __pyx_t_3;
   21163             : 
   21164             :     /* "_ni_label.pyx":70
   21165             :  *     cdef np.intp_t i
   21166             :  *     for i in range(L):
   21167             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21168             :  * 
   21169             :  * 
   21170             :  */
   21171          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_uint8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21172             :   }
   21173             : 
   21174             :   /* "_ni_label.pyx":66
   21175             :  * # Load a line from a fused data array to a np.uintp_t array
   21176             :  * ######################################################################
   21177             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21178             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21179             :  *     cdef np.intp_t i
   21180             :  */
   21181             : 
   21182             :   /* function exit code */
   21183           8 : }
   21184             : 
   21185           8 : static void __pyx_fuse_5__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21186           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21187           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21188           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21189           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21190             : 
   21191             :   /* "_ni_label.pyx":69
   21192             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21193             :  *     cdef np.intp_t i
   21194             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21195             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21196             :  * 
   21197             :  */
   21198           8 :   __pyx_t_1 = __pyx_v_L;
   21199           8 :   __pyx_t_2 = __pyx_t_1;
   21200          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21201          46 :     __pyx_v_i = __pyx_t_3;
   21202             : 
   21203             :     /* "_ni_label.pyx":70
   21204             :  *     cdef np.intp_t i
   21205             :  *     for i in range(L):
   21206             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21207             :  * 
   21208             :  * 
   21209             :  */
   21210          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_uint16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21211             :   }
   21212             : 
   21213             :   /* "_ni_label.pyx":66
   21214             :  * # Load a line from a fused data array to a np.uintp_t array
   21215             :  * ######################################################################
   21216             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21217             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21218             :  *     cdef np.intp_t i
   21219             :  */
   21220             : 
   21221             :   /* function exit code */
   21222           8 : }
   21223             : 
   21224           8 : static void __pyx_fuse_6__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21225           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21226           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21227           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21228           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21229             : 
   21230             :   /* "_ni_label.pyx":69
   21231             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21232             :  *     cdef np.intp_t i
   21233             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21234             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21235             :  * 
   21236             :  */
   21237           8 :   __pyx_t_1 = __pyx_v_L;
   21238           8 :   __pyx_t_2 = __pyx_t_1;
   21239          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21240          46 :     __pyx_v_i = __pyx_t_3;
   21241             : 
   21242             :     /* "_ni_label.pyx":70
   21243             :  *     cdef np.intp_t i
   21244             :  *     for i in range(L):
   21245             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21246             :  * 
   21247             :  * 
   21248             :  */
   21249          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_uint32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21250             :   }
   21251             : 
   21252             :   /* "_ni_label.pyx":66
   21253             :  * # Load a line from a fused data array to a np.uintp_t array
   21254             :  * ######################################################################
   21255             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21256             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21257             :  *     cdef np.intp_t i
   21258             :  */
   21259             : 
   21260             :   /* function exit code */
   21261           8 : }
   21262             : 
   21263           8 : static void __pyx_fuse_7__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_uint64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21264           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21265           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21266           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21267           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21268             : 
   21269             :   /* "_ni_label.pyx":69
   21270             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21271             :  *     cdef np.intp_t i
   21272             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21273             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21274             :  * 
   21275             :  */
   21276           8 :   __pyx_t_1 = __pyx_v_L;
   21277           8 :   __pyx_t_2 = __pyx_t_1;
   21278          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21279          46 :     __pyx_v_i = __pyx_t_3;
   21280             : 
   21281             :     /* "_ni_label.pyx":70
   21282             :  *     cdef np.intp_t i
   21283             :  *     for i in range(L):
   21284             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21285             :  * 
   21286             :  * 
   21287             :  */
   21288          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_uint64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21289             :   }
   21290             : 
   21291             :   /* "_ni_label.pyx":66
   21292             :  * # Load a line from a fused data array to a np.uintp_t array
   21293             :  * ######################################################################
   21294             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21295             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21296             :  *     cdef np.intp_t i
   21297             :  */
   21298             : 
   21299             :   /* function exit code */
   21300           8 : }
   21301             : 
   21302           8 : static void __pyx_fuse_8__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_float32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21303           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21304           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21305           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21306           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21307             : 
   21308             :   /* "_ni_label.pyx":69
   21309             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21310             :  *     cdef np.intp_t i
   21311             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21312             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21313             :  * 
   21314             :  */
   21315           8 :   __pyx_t_1 = __pyx_v_L;
   21316           8 :   __pyx_t_2 = __pyx_t_1;
   21317          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21318          46 :     __pyx_v_i = __pyx_t_3;
   21319             : 
   21320             :     /* "_ni_label.pyx":70
   21321             :  *     cdef np.intp_t i
   21322             :  *     for i in range(L):
   21323             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21324             :  * 
   21325             :  * 
   21326             :  */
   21327          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_float32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21328             :   }
   21329             : 
   21330             :   /* "_ni_label.pyx":66
   21331             :  * # Load a line from a fused data array to a np.uintp_t array
   21332             :  * ######################################################################
   21333             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21334             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21335             :  *     cdef np.intp_t i
   21336             :  */
   21337             : 
   21338             :   /* function exit code */
   21339           8 : }
   21340             : 
   21341           8 : static void __pyx_fuse_9__pyx_f_9_ni_label_fused_read_line(__pyx_t_5numpy_float64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21342           8 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21343           8 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21344           8 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21345           8 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21346             : 
   21347             :   /* "_ni_label.pyx":69
   21348             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21349             :  *     cdef np.intp_t i
   21350             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21351             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]
   21352             :  * 
   21353             :  */
   21354           8 :   __pyx_t_1 = __pyx_v_L;
   21355           8 :   __pyx_t_2 = __pyx_t_1;
   21356          54 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21357          46 :     __pyx_v_i = __pyx_t_3;
   21358             : 
   21359             :     /* "_ni_label.pyx":70
   21360             :  *     cdef np.intp_t i
   21361             :  *     for i in range(L):
   21362             :  *         line[i] = <np.uintp_t> (<data_t *> ((<char *> p) + i * stride))[0]             # <<<<<<<<<<<<<<
   21363             :  * 
   21364             :  * 
   21365             :  */
   21366          46 :     (__pyx_v_line[__pyx_v_i]) = ((__pyx_t_5numpy_uintp_t)(((__pyx_t_5numpy_float64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]));
   21367             :   }
   21368             : 
   21369             :   /* "_ni_label.pyx":66
   21370             :  * # Load a line from a fused data array to a np.uintp_t array
   21371             :  * ######################################################################
   21372             :  * cdef void fused_read_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21373             :  *                           np.uintp_t *line, np.intp_t L) noexcept nogil:
   21374             :  *     cdef np.intp_t i
   21375             :  */
   21376             : 
   21377             :   /* function exit code */
   21378           8 : }
   21379             : 
   21380             : /* "_ni_label.pyx":77
   21381             :  * # returning True if overflowed
   21382             :  * ######################################################################
   21383             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21384             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21385             :  *     cdef np.intp_t i
   21386             :  */
   21387             : 
   21388          16 : static int __pyx_fuse_0__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21389          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21390          16 :   int __pyx_r;
   21391          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21392          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21393          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21394          16 :   int __pyx_t_4;
   21395             : 
   21396             :   /* "_ni_label.pyx":80
   21397             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21398             :  *     cdef np.intp_t i
   21399             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21400             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21401             :  *         # in the foreground, which allows us to retry even when operating
   21402             :  */
   21403          16 :   __pyx_t_1 = __pyx_v_L;
   21404          16 :   __pyx_t_2 = __pyx_t_1;
   21405         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21406          92 :     __pyx_v_i = __pyx_t_3;
   21407             : 
   21408             :     /* "_ni_label.pyx":84
   21409             :  *         # in the foreground, which allows us to retry even when operating
   21410             :  *         # in-place.
   21411             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21412             :  *             return True
   21413             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21414             :  */
   21415          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_int8_t)(__pyx_v_line[__pyx_v_i]))));
   21416          92 :     if (__pyx_t_4) {
   21417             : 
   21418             :       /* "_ni_label.pyx":85
   21419             :  *         # in-place.
   21420             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21421             :  *             return True             # <<<<<<<<<<<<<<
   21422             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21423             :  *     return False
   21424             :  */
   21425           0 :       __pyx_r = 1;
   21426           0 :       goto __pyx_L0;
   21427             : 
   21428             :       /* "_ni_label.pyx":84
   21429             :  *         # in the foreground, which allows us to retry even when operating
   21430             :  *         # in-place.
   21431             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21432             :  *             return True
   21433             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21434             :  */
   21435             :     }
   21436             : 
   21437             :     /* "_ni_label.pyx":86
   21438             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21439             :  *             return True
   21440             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21441             :  *     return False
   21442             :  * 
   21443             :  */
   21444          92 :     (((__pyx_t_5numpy_int8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_int8_t)(__pyx_v_line[__pyx_v_i]));
   21445             :   }
   21446             : 
   21447             :   /* "_ni_label.pyx":87
   21448             :  *             return True
   21449             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21450             :  *     return False             # <<<<<<<<<<<<<<
   21451             :  * 
   21452             :  * 
   21453             :  */
   21454          16 :   __pyx_r = 0;
   21455          16 :   goto __pyx_L0;
   21456             : 
   21457             :   /* "_ni_label.pyx":77
   21458             :  * # returning True if overflowed
   21459             :  * ######################################################################
   21460             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21461             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21462             :  *     cdef np.intp_t i
   21463             :  */
   21464             : 
   21465             :   /* function exit code */
   21466          16 :   __pyx_L0:;
   21467          16 :   return __pyx_r;
   21468             : }
   21469             : 
   21470          16 : static int __pyx_fuse_1__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21471          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21472          16 :   int __pyx_r;
   21473          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21474          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21475          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21476          16 :   int __pyx_t_4;
   21477             : 
   21478             :   /* "_ni_label.pyx":80
   21479             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21480             :  *     cdef np.intp_t i
   21481             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21482             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21483             :  *         # in the foreground, which allows us to retry even when operating
   21484             :  */
   21485          16 :   __pyx_t_1 = __pyx_v_L;
   21486          16 :   __pyx_t_2 = __pyx_t_1;
   21487         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21488          92 :     __pyx_v_i = __pyx_t_3;
   21489             : 
   21490             :     /* "_ni_label.pyx":84
   21491             :  *         # in the foreground, which allows us to retry even when operating
   21492             :  *         # in-place.
   21493             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21494             :  *             return True
   21495             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21496             :  */
   21497          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_int16_t)(__pyx_v_line[__pyx_v_i]))));
   21498          92 :     if (__pyx_t_4) {
   21499             : 
   21500             :       /* "_ni_label.pyx":85
   21501             :  *         # in-place.
   21502             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21503             :  *             return True             # <<<<<<<<<<<<<<
   21504             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21505             :  *     return False
   21506             :  */
   21507           0 :       __pyx_r = 1;
   21508           0 :       goto __pyx_L0;
   21509             : 
   21510             :       /* "_ni_label.pyx":84
   21511             :  *         # in the foreground, which allows us to retry even when operating
   21512             :  *         # in-place.
   21513             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21514             :  *             return True
   21515             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21516             :  */
   21517             :     }
   21518             : 
   21519             :     /* "_ni_label.pyx":86
   21520             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21521             :  *             return True
   21522             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21523             :  *     return False
   21524             :  * 
   21525             :  */
   21526          92 :     (((__pyx_t_5numpy_int16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_int16_t)(__pyx_v_line[__pyx_v_i]));
   21527             :   }
   21528             : 
   21529             :   /* "_ni_label.pyx":87
   21530             :  *             return True
   21531             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21532             :  *     return False             # <<<<<<<<<<<<<<
   21533             :  * 
   21534             :  * 
   21535             :  */
   21536          16 :   __pyx_r = 0;
   21537          16 :   goto __pyx_L0;
   21538             : 
   21539             :   /* "_ni_label.pyx":77
   21540             :  * # returning True if overflowed
   21541             :  * ######################################################################
   21542             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21543             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21544             :  *     cdef np.intp_t i
   21545             :  */
   21546             : 
   21547             :   /* function exit code */
   21548          16 :   __pyx_L0:;
   21549          16 :   return __pyx_r;
   21550             : }
   21551             : 
   21552        8776 : static int __pyx_fuse_2__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21553        8776 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21554        8776 :   int __pyx_r;
   21555        8776 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21556        8776 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21557        8776 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21558        8776 :   int __pyx_t_4;
   21559             : 
   21560             :   /* "_ni_label.pyx":80
   21561             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21562             :  *     cdef np.intp_t i
   21563             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21564             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21565             :  *         # in the foreground, which allows us to retry even when operating
   21566             :  */
   21567        8776 :   __pyx_t_1 = __pyx_v_L;
   21568        8776 :   __pyx_t_2 = __pyx_t_1;
   21569     9284474 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21570     9275698 :     __pyx_v_i = __pyx_t_3;
   21571             : 
   21572             :     /* "_ni_label.pyx":84
   21573             :  *         # in the foreground, which allows us to retry even when operating
   21574             :  *         # in-place.
   21575             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21576             :  *             return True
   21577             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21578             :  */
   21579     9275698 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_int32_t)(__pyx_v_line[__pyx_v_i]))));
   21580     9275698 :     if (__pyx_t_4) {
   21581             : 
   21582             :       /* "_ni_label.pyx":85
   21583             :  *         # in-place.
   21584             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21585             :  *             return True             # <<<<<<<<<<<<<<
   21586             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21587             :  *     return False
   21588             :  */
   21589           0 :       __pyx_r = 1;
   21590           0 :       goto __pyx_L0;
   21591             : 
   21592             :       /* "_ni_label.pyx":84
   21593             :  *         # in the foreground, which allows us to retry even when operating
   21594             :  *         # in-place.
   21595             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21596             :  *             return True
   21597             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21598             :  */
   21599             :     }
   21600             : 
   21601             :     /* "_ni_label.pyx":86
   21602             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21603             :  *             return True
   21604             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21605             :  *     return False
   21606             :  * 
   21607             :  */
   21608     9275698 :     (((__pyx_t_5numpy_int32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_int32_t)(__pyx_v_line[__pyx_v_i]));
   21609             :   }
   21610             : 
   21611             :   /* "_ni_label.pyx":87
   21612             :  *             return True
   21613             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21614             :  *     return False             # <<<<<<<<<<<<<<
   21615             :  * 
   21616             :  * 
   21617             :  */
   21618        8776 :   __pyx_r = 0;
   21619        8776 :   goto __pyx_L0;
   21620             : 
   21621             :   /* "_ni_label.pyx":77
   21622             :  * # returning True if overflowed
   21623             :  * ######################################################################
   21624             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21625             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21626             :  *     cdef np.intp_t i
   21627             :  */
   21628             : 
   21629             :   /* function exit code */
   21630        8776 :   __pyx_L0:;
   21631        8776 :   return __pyx_r;
   21632             : }
   21633             : 
   21634          16 : static int __pyx_fuse_3__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_int64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21635          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21636          16 :   int __pyx_r;
   21637          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21638          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21639          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21640          16 :   int __pyx_t_4;
   21641             : 
   21642             :   /* "_ni_label.pyx":80
   21643             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21644             :  *     cdef np.intp_t i
   21645             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21646             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21647             :  *         # in the foreground, which allows us to retry even when operating
   21648             :  */
   21649          16 :   __pyx_t_1 = __pyx_v_L;
   21650          16 :   __pyx_t_2 = __pyx_t_1;
   21651         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21652          92 :     __pyx_v_i = __pyx_t_3;
   21653             : 
   21654             :     /* "_ni_label.pyx":84
   21655             :  *         # in the foreground, which allows us to retry even when operating
   21656             :  *         # in-place.
   21657             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21658             :  *             return True
   21659             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21660             :  */
   21661          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_int64_t)(__pyx_v_line[__pyx_v_i]))));
   21662          92 :     if (__pyx_t_4) {
   21663             : 
   21664             :       /* "_ni_label.pyx":85
   21665             :  *         # in-place.
   21666             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21667             :  *             return True             # <<<<<<<<<<<<<<
   21668             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21669             :  *     return False
   21670             :  */
   21671             :       __pyx_r = 1;
   21672             :       goto __pyx_L0;
   21673             : 
   21674             :       /* "_ni_label.pyx":84
   21675             :  *         # in the foreground, which allows us to retry even when operating
   21676             :  *         # in-place.
   21677             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21678             :  *             return True
   21679             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21680             :  */
   21681             :     }
   21682             : 
   21683             :     /* "_ni_label.pyx":86
   21684             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21685             :  *             return True
   21686             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21687             :  *     return False
   21688             :  * 
   21689             :  */
   21690          92 :     (((__pyx_t_5numpy_int64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_int64_t)(__pyx_v_line[__pyx_v_i]));
   21691             :   }
   21692             : 
   21693             :   /* "_ni_label.pyx":87
   21694             :  *             return True
   21695             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21696             :  *     return False             # <<<<<<<<<<<<<<
   21697             :  * 
   21698             :  * 
   21699             :  */
   21700          16 :   __pyx_r = 0;
   21701          16 :   goto __pyx_L0;
   21702             : 
   21703             :   /* "_ni_label.pyx":77
   21704             :  * # returning True if overflowed
   21705             :  * ######################################################################
   21706             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21707             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21708             :  *     cdef np.intp_t i
   21709             :  */
   21710             : 
   21711             :   /* function exit code */
   21712          16 :   __pyx_L0:;
   21713          16 :   return __pyx_r;
   21714             : }
   21715             : 
   21716          16 : static int __pyx_fuse_4__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint8_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21717          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21718          16 :   int __pyx_r;
   21719          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21720          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21721          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21722          16 :   int __pyx_t_4;
   21723             : 
   21724             :   /* "_ni_label.pyx":80
   21725             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21726             :  *     cdef np.intp_t i
   21727             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21728             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21729             :  *         # in the foreground, which allows us to retry even when operating
   21730             :  */
   21731          16 :   __pyx_t_1 = __pyx_v_L;
   21732          16 :   __pyx_t_2 = __pyx_t_1;
   21733         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21734          92 :     __pyx_v_i = __pyx_t_3;
   21735             : 
   21736             :     /* "_ni_label.pyx":84
   21737             :  *         # in the foreground, which allows us to retry even when operating
   21738             :  *         # in-place.
   21739             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21740             :  *             return True
   21741             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21742             :  */
   21743          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_uint8_t)(__pyx_v_line[__pyx_v_i]))));
   21744          92 :     if (__pyx_t_4) {
   21745             : 
   21746             :       /* "_ni_label.pyx":85
   21747             :  *         # in-place.
   21748             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21749             :  *             return True             # <<<<<<<<<<<<<<
   21750             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21751             :  *     return False
   21752             :  */
   21753           0 :       __pyx_r = 1;
   21754           0 :       goto __pyx_L0;
   21755             : 
   21756             :       /* "_ni_label.pyx":84
   21757             :  *         # in the foreground, which allows us to retry even when operating
   21758             :  *         # in-place.
   21759             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21760             :  *             return True
   21761             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21762             :  */
   21763             :     }
   21764             : 
   21765             :     /* "_ni_label.pyx":86
   21766             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21767             :  *             return True
   21768             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21769             :  *     return False
   21770             :  * 
   21771             :  */
   21772          92 :     (((__pyx_t_5numpy_uint8_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_uint8_t)(__pyx_v_line[__pyx_v_i]));
   21773             :   }
   21774             : 
   21775             :   /* "_ni_label.pyx":87
   21776             :  *             return True
   21777             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21778             :  *     return False             # <<<<<<<<<<<<<<
   21779             :  * 
   21780             :  * 
   21781             :  */
   21782          16 :   __pyx_r = 0;
   21783          16 :   goto __pyx_L0;
   21784             : 
   21785             :   /* "_ni_label.pyx":77
   21786             :  * # returning True if overflowed
   21787             :  * ######################################################################
   21788             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21789             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21790             :  *     cdef np.intp_t i
   21791             :  */
   21792             : 
   21793             :   /* function exit code */
   21794          16 :   __pyx_L0:;
   21795          16 :   return __pyx_r;
   21796             : }
   21797             : 
   21798          16 : static int __pyx_fuse_5__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint16_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21799          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21800          16 :   int __pyx_r;
   21801          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21802          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21803          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21804          16 :   int __pyx_t_4;
   21805             : 
   21806             :   /* "_ni_label.pyx":80
   21807             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21808             :  *     cdef np.intp_t i
   21809             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21810             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21811             :  *         # in the foreground, which allows us to retry even when operating
   21812             :  */
   21813          16 :   __pyx_t_1 = __pyx_v_L;
   21814          16 :   __pyx_t_2 = __pyx_t_1;
   21815         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21816          92 :     __pyx_v_i = __pyx_t_3;
   21817             : 
   21818             :     /* "_ni_label.pyx":84
   21819             :  *         # in the foreground, which allows us to retry even when operating
   21820             :  *         # in-place.
   21821             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21822             :  *             return True
   21823             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21824             :  */
   21825          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_uint16_t)(__pyx_v_line[__pyx_v_i]))));
   21826          92 :     if (__pyx_t_4) {
   21827             : 
   21828             :       /* "_ni_label.pyx":85
   21829             :  *         # in-place.
   21830             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21831             :  *             return True             # <<<<<<<<<<<<<<
   21832             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21833             :  *     return False
   21834             :  */
   21835           0 :       __pyx_r = 1;
   21836           0 :       goto __pyx_L0;
   21837             : 
   21838             :       /* "_ni_label.pyx":84
   21839             :  *         # in the foreground, which allows us to retry even when operating
   21840             :  *         # in-place.
   21841             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21842             :  *             return True
   21843             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21844             :  */
   21845             :     }
   21846             : 
   21847             :     /* "_ni_label.pyx":86
   21848             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21849             :  *             return True
   21850             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21851             :  *     return False
   21852             :  * 
   21853             :  */
   21854          92 :     (((__pyx_t_5numpy_uint16_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_uint16_t)(__pyx_v_line[__pyx_v_i]));
   21855             :   }
   21856             : 
   21857             :   /* "_ni_label.pyx":87
   21858             :  *             return True
   21859             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21860             :  *     return False             # <<<<<<<<<<<<<<
   21861             :  * 
   21862             :  * 
   21863             :  */
   21864          16 :   __pyx_r = 0;
   21865          16 :   goto __pyx_L0;
   21866             : 
   21867             :   /* "_ni_label.pyx":77
   21868             :  * # returning True if overflowed
   21869             :  * ######################################################################
   21870             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21871             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21872             :  *     cdef np.intp_t i
   21873             :  */
   21874             : 
   21875             :   /* function exit code */
   21876          16 :   __pyx_L0:;
   21877          16 :   return __pyx_r;
   21878             : }
   21879             : 
   21880          16 : static int __pyx_fuse_6__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21881          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21882          16 :   int __pyx_r;
   21883          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21884          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21885          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21886          16 :   int __pyx_t_4;
   21887             : 
   21888             :   /* "_ni_label.pyx":80
   21889             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21890             :  *     cdef np.intp_t i
   21891             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21892             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21893             :  *         # in the foreground, which allows us to retry even when operating
   21894             :  */
   21895          16 :   __pyx_t_1 = __pyx_v_L;
   21896          16 :   __pyx_t_2 = __pyx_t_1;
   21897         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21898          92 :     __pyx_v_i = __pyx_t_3;
   21899             : 
   21900             :     /* "_ni_label.pyx":84
   21901             :  *         # in the foreground, which allows us to retry even when operating
   21902             :  *         # in-place.
   21903             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21904             :  *             return True
   21905             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21906             :  */
   21907          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_uint32_t)(__pyx_v_line[__pyx_v_i]))));
   21908          92 :     if (__pyx_t_4) {
   21909             : 
   21910             :       /* "_ni_label.pyx":85
   21911             :  *         # in-place.
   21912             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21913             :  *             return True             # <<<<<<<<<<<<<<
   21914             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21915             :  *     return False
   21916             :  */
   21917           0 :       __pyx_r = 1;
   21918           0 :       goto __pyx_L0;
   21919             : 
   21920             :       /* "_ni_label.pyx":84
   21921             :  *         # in the foreground, which allows us to retry even when operating
   21922             :  *         # in-place.
   21923             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21924             :  *             return True
   21925             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21926             :  */
   21927             :     }
   21928             : 
   21929             :     /* "_ni_label.pyx":86
   21930             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21931             :  *             return True
   21932             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   21933             :  *     return False
   21934             :  * 
   21935             :  */
   21936          92 :     (((__pyx_t_5numpy_uint32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_uint32_t)(__pyx_v_line[__pyx_v_i]));
   21937             :   }
   21938             : 
   21939             :   /* "_ni_label.pyx":87
   21940             :  *             return True
   21941             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21942             :  *     return False             # <<<<<<<<<<<<<<
   21943             :  * 
   21944             :  * 
   21945             :  */
   21946          16 :   __pyx_r = 0;
   21947          16 :   goto __pyx_L0;
   21948             : 
   21949             :   /* "_ni_label.pyx":77
   21950             :  * # returning True if overflowed
   21951             :  * ######################################################################
   21952             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   21953             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21954             :  *     cdef np.intp_t i
   21955             :  */
   21956             : 
   21957             :   /* function exit code */
   21958          16 :   __pyx_L0:;
   21959          16 :   return __pyx_r;
   21960             : }
   21961             : 
   21962          16 : static int __pyx_fuse_7__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_uint64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   21963          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   21964          16 :   int __pyx_r;
   21965          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   21966          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   21967          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   21968          16 :   int __pyx_t_4;
   21969             : 
   21970             :   /* "_ni_label.pyx":80
   21971             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   21972             :  *     cdef np.intp_t i
   21973             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   21974             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   21975             :  *         # in the foreground, which allows us to retry even when operating
   21976             :  */
   21977          16 :   __pyx_t_1 = __pyx_v_L;
   21978          16 :   __pyx_t_2 = __pyx_t_1;
   21979         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   21980          92 :     __pyx_v_i = __pyx_t_3;
   21981             : 
   21982             :     /* "_ni_label.pyx":84
   21983             :  *         # in the foreground, which allows us to retry even when operating
   21984             :  *         # in-place.
   21985             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   21986             :  *             return True
   21987             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21988             :  */
   21989          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_uint64_t)(__pyx_v_line[__pyx_v_i]))));
   21990          92 :     if (__pyx_t_4) {
   21991             : 
   21992             :       /* "_ni_label.pyx":85
   21993             :  *         # in-place.
   21994             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   21995             :  *             return True             # <<<<<<<<<<<<<<
   21996             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   21997             :  *     return False
   21998             :  */
   21999             :       __pyx_r = 1;
   22000             :       goto __pyx_L0;
   22001             : 
   22002             :       /* "_ni_label.pyx":84
   22003             :  *         # in the foreground, which allows us to retry even when operating
   22004             :  *         # in-place.
   22005             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   22006             :  *             return True
   22007             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22008             :  */
   22009             :     }
   22010             : 
   22011             :     /* "_ni_label.pyx":86
   22012             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   22013             :  *             return True
   22014             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   22015             :  *     return False
   22016             :  * 
   22017             :  */
   22018          92 :     (((__pyx_t_5numpy_uint64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_uint64_t)(__pyx_v_line[__pyx_v_i]));
   22019             :   }
   22020             : 
   22021             :   /* "_ni_label.pyx":87
   22022             :  *             return True
   22023             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22024             :  *     return False             # <<<<<<<<<<<<<<
   22025             :  * 
   22026             :  * 
   22027             :  */
   22028          16 :   __pyx_r = 0;
   22029          16 :   goto __pyx_L0;
   22030             : 
   22031             :   /* "_ni_label.pyx":77
   22032             :  * # returning True if overflowed
   22033             :  * ######################################################################
   22034             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   22035             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   22036             :  *     cdef np.intp_t i
   22037             :  */
   22038             : 
   22039             :   /* function exit code */
   22040          16 :   __pyx_L0:;
   22041          16 :   return __pyx_r;
   22042             : }
   22043             : 
   22044          16 : static int __pyx_fuse_8__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_float32_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   22045          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   22046          16 :   int __pyx_r;
   22047          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   22048          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   22049          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   22050          16 :   int __pyx_t_4;
   22051             : 
   22052             :   /* "_ni_label.pyx":80
   22053             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   22054             :  *     cdef np.intp_t i
   22055             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   22056             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   22057             :  *         # in the foreground, which allows us to retry even when operating
   22058             :  */
   22059          16 :   __pyx_t_1 = __pyx_v_L;
   22060          16 :   __pyx_t_2 = __pyx_t_1;
   22061         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   22062          92 :     __pyx_v_i = __pyx_t_3;
   22063             : 
   22064             :     /* "_ni_label.pyx":84
   22065             :  *         # in the foreground, which allows us to retry even when operating
   22066             :  *         # in-place.
   22067             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   22068             :  *             return True
   22069             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22070             :  */
   22071          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_float32_t)(__pyx_v_line[__pyx_v_i]))));
   22072          92 :     if (__pyx_t_4) {
   22073             : 
   22074             :       /* "_ni_label.pyx":85
   22075             :  *         # in-place.
   22076             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   22077             :  *             return True             # <<<<<<<<<<<<<<
   22078             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22079             :  *     return False
   22080             :  */
   22081           0 :       __pyx_r = 1;
   22082           0 :       goto __pyx_L0;
   22083             : 
   22084             :       /* "_ni_label.pyx":84
   22085             :  *         # in the foreground, which allows us to retry even when operating
   22086             :  *         # in-place.
   22087             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   22088             :  *             return True
   22089             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22090             :  */
   22091             :     }
   22092             : 
   22093             :     /* "_ni_label.pyx":86
   22094             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   22095             :  *             return True
   22096             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   22097             :  *     return False
   22098             :  * 
   22099             :  */
   22100          92 :     (((__pyx_t_5numpy_float32_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_float32_t)(__pyx_v_line[__pyx_v_i]));
   22101             :   }
   22102             : 
   22103             :   /* "_ni_label.pyx":87
   22104             :  *             return True
   22105             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22106             :  *     return False             # <<<<<<<<<<<<<<
   22107             :  * 
   22108             :  * 
   22109             :  */
   22110          16 :   __pyx_r = 0;
   22111          16 :   goto __pyx_L0;
   22112             : 
   22113             :   /* "_ni_label.pyx":77
   22114             :  * # returning True if overflowed
   22115             :  * ######################################################################
   22116             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   22117             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   22118             :  *     cdef np.intp_t i
   22119             :  */
   22120             : 
   22121             :   /* function exit code */
   22122          16 :   __pyx_L0:;
   22123          16 :   return __pyx_r;
   22124             : }
   22125             : 
   22126          16 : static int __pyx_fuse_9__pyx_f_9_ni_label_fused_write_line(__pyx_t_5numpy_float64_t *__pyx_v_p, __pyx_t_5numpy_intp_t __pyx_v_stride, __pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_intp_t __pyx_v_L) {
   22127          16 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   22128          16 :   int __pyx_r;
   22129          16 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   22130          16 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   22131          16 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   22132          16 :   int __pyx_t_4;
   22133             : 
   22134             :   /* "_ni_label.pyx":80
   22135             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   22136             :  *     cdef np.intp_t i
   22137             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   22138             :  *         # Check before overwrite, as this prevents us accidentally writing a 0
   22139             :  *         # in the foreground, which allows us to retry even when operating
   22140             :  */
   22141          16 :   __pyx_t_1 = __pyx_v_L;
   22142          16 :   __pyx_t_2 = __pyx_t_1;
   22143         108 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   22144          92 :     __pyx_v_i = __pyx_t_3;
   22145             : 
   22146             :     /* "_ni_label.pyx":84
   22147             :  *         # in the foreground, which allows us to retry even when operating
   22148             :  *         # in-place.
   22149             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   22150             :  *             return True
   22151             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22152             :  */
   22153          92 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != ((__pyx_t_5numpy_uintp_t)((__pyx_t_5numpy_float64_t)(__pyx_v_line[__pyx_v_i]))));
   22154          92 :     if (__pyx_t_4) {
   22155             : 
   22156             :       /* "_ni_label.pyx":85
   22157             :  *         # in-place.
   22158             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   22159             :  *             return True             # <<<<<<<<<<<<<<
   22160             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22161             :  *     return False
   22162             :  */
   22163           0 :       __pyx_r = 1;
   22164           0 :       goto __pyx_L0;
   22165             : 
   22166             :       /* "_ni_label.pyx":84
   22167             :  *         # in the foreground, which allows us to retry even when operating
   22168             :  *         # in-place.
   22169             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:             # <<<<<<<<<<<<<<
   22170             :  *             return True
   22171             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22172             :  */
   22173             :     }
   22174             : 
   22175             :     /* "_ni_label.pyx":86
   22176             :  *         if line[i] != <np.uintp_t> <data_t> line[i]:
   22177             :  *             return True
   22178             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]             # <<<<<<<<<<<<<<
   22179             :  *     return False
   22180             :  * 
   22181             :  */
   22182          92 :     (((__pyx_t_5numpy_float64_t *)(((char *)__pyx_v_p) + (__pyx_v_i * __pyx_v_stride)))[0]) = ((__pyx_t_5numpy_float64_t)(__pyx_v_line[__pyx_v_i]));
   22183             :   }
   22184             : 
   22185             :   /* "_ni_label.pyx":87
   22186             :  *             return True
   22187             :  *         (<data_t *> ((<char *> p) + i * stride))[0] = <data_t> line[i]
   22188             :  *     return False             # <<<<<<<<<<<<<<
   22189             :  * 
   22190             :  * 
   22191             :  */
   22192          16 :   __pyx_r = 0;
   22193          16 :   goto __pyx_L0;
   22194             : 
   22195             :   /* "_ni_label.pyx":77
   22196             :  * # returning True if overflowed
   22197             :  * ######################################################################
   22198             :  * cdef bint fused_write_line(data_t *p, np.intp_t stride,             # <<<<<<<<<<<<<<
   22199             :  *                            np.uintp_t *line, np.intp_t L) noexcept nogil:
   22200             :  *     cdef np.intp_t i
   22201             :  */
   22202             : 
   22203             :   /* function exit code */
   22204          16 :   __pyx_L0:;
   22205          16 :   return __pyx_r;
   22206             : }
   22207             : 
   22208             : /* "_ni_label.pyx":93
   22209             :  * # Function specializers
   22210             :  * ######################################################################
   22211             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   22212             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   22213             :  * 
   22214             :  */
   22215             : 
   22216             : /* Python wrapper */
   22217             : static PyObject *__pyx_pw_9_ni_label_1get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   22218             : static PyMethodDef __pyx_mdef_9_ni_label_1get_nonzero_line = {"get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_9_ni_label_1get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   22219         119 : static PyObject *__pyx_pw_9_ni_label_1get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   22220         119 :   PyObject *__pyx_v_signatures = 0;
   22221         119 :   PyObject *__pyx_v_args = 0;
   22222         119 :   PyObject *__pyx_v_kwargs = 0;
   22223         119 :   CYTHON_UNUSED PyObject *__pyx_v_defaults = 0;
   22224         119 :   PyObject *__pyx_v__fused_sigindex = 0;
   22225         119 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   22226         119 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   22227         119 :   PyObject* values[5] = {0,0,0,0,0};
   22228         119 :   int __pyx_lineno = 0;
   22229         119 :   const char *__pyx_filename = NULL;
   22230         119 :   int __pyx_clineno = 0;
   22231         119 :   PyObject *__pyx_r = 0;
   22232             :   __Pyx_RefNannyDeclarations
   22233         119 :   __Pyx_RefNannySetupContext("__pyx_fused_cpdef (wrapper)", 0);
   22234             :   #if CYTHON_ASSUME_SAFE_MACROS
   22235         119 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   22236             :   #else
   22237             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   22238             :   #endif
   22239         119 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   22240             :   {
   22241         119 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_signatures,&__pyx_n_s_args,&__pyx_n_s_kwargs,&__pyx_n_s_defaults,&__pyx_n_s_fused_sigindex,0};
   22242         119 :     __pyx_defaults *__pyx_dynamic_args = __Pyx_CyFunction_Defaults(__pyx_defaults, __pyx_self);
   22243         119 :     values[4] = __Pyx_Arg_NewRef_VARARGS(__pyx_dynamic_args->__pyx_arg__fused_sigindex);
   22244         119 :     if (__pyx_kwds) {
   22245           0 :       Py_ssize_t kw_args;
   22246           0 :       switch (__pyx_nargs) {
   22247           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   22248           0 :         CYTHON_FALLTHROUGH;
   22249           0 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   22250           0 :         CYTHON_FALLTHROUGH;
   22251           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   22252           0 :         CYTHON_FALLTHROUGH;
   22253           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   22254           0 :         CYTHON_FALLTHROUGH;
   22255           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   22256           0 :         CYTHON_FALLTHROUGH;
   22257           0 :         case  0: break;
   22258           0 :         default: goto __pyx_L5_argtuple_error;
   22259             :       }
   22260           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   22261           0 :       switch (__pyx_nargs) {
   22262           0 :         case  0:
   22263           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_signatures)) != 0)) {
   22264           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   22265           0 :           kw_args--;
   22266             :         }
   22267           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   22268           0 :         else goto __pyx_L5_argtuple_error;
   22269           0 :         CYTHON_FALLTHROUGH;
   22270             :         case  1:
   22271           0 :         if (likely((values[1] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_args)) != 0)) {
   22272           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[1]);
   22273           0 :           kw_args--;
   22274             :         }
   22275           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   22276             :         else {
   22277           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 1); __PYX_ERR(0, 93, __pyx_L3_error)
   22278             :         }
   22279           0 :         CYTHON_FALLTHROUGH;
   22280             :         case  2:
   22281           0 :         if (likely((values[2] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_kwargs)) != 0)) {
   22282           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[2]);
   22283           0 :           kw_args--;
   22284             :         }
   22285           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   22286             :         else {
   22287           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 2); __PYX_ERR(0, 93, __pyx_L3_error)
   22288             :         }
   22289           0 :         CYTHON_FALLTHROUGH;
   22290             :         case  3:
   22291           0 :         if (likely((values[3] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_defaults)) != 0)) {
   22292           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[3]);
   22293           0 :           kw_args--;
   22294             :         }
   22295           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   22296             :         else {
   22297           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 3); __PYX_ERR(0, 93, __pyx_L3_error)
   22298             :         }
   22299           0 :         CYTHON_FALLTHROUGH;
   22300             :         case  4:
   22301           0 :         if (kw_args > 0) {
   22302           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_fused_sigindex);
   22303           0 :           if (value) { values[4] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
   22304           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   22305             :         }
   22306             :       }
   22307           0 :       if (unlikely(kw_args > 0)) {
   22308           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   22309           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__pyx_fused_cpdef") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   22310             :       }
   22311             :     } else {
   22312         119 :       switch (__pyx_nargs) {
   22313           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   22314         119 :         CYTHON_FALLTHROUGH;
   22315         119 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   22316         119 :         values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   22317         119 :         values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   22318         119 :         values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   22319         119 :         break;
   22320           0 :         default: goto __pyx_L5_argtuple_error;
   22321             :       }
   22322             :     }
   22323         119 :     __pyx_v_signatures = values[0];
   22324         119 :     __pyx_v_args = values[1];
   22325         119 :     __pyx_v_kwargs = values[2];
   22326         119 :     __pyx_v_defaults = values[3];
   22327         119 :     __pyx_v__fused_sigindex = values[4];
   22328             :   }
   22329         119 :   goto __pyx_L6_skip;
   22330           0 :   __pyx_L5_argtuple_error:;
   22331           0 :   __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   22332         119 :   __pyx_L6_skip:;
   22333         119 :   goto __pyx_L4_argument_unpacking_done;
   22334           0 :   __pyx_L3_error:;
   22335             :   {
   22336           0 :     Py_ssize_t __pyx_temp;
   22337           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   22338             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   22339             :     }
   22340             :   }
   22341           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   22342           0 :   __Pyx_RefNannyFinishContext();
   22343           0 :   return NULL;
   22344         119 :   __pyx_L4_argument_unpacking_done:;
   22345         119 :   __pyx_r = __pyx_pf_9_ni_label_get_nonzero_line(__pyx_self, __pyx_v_signatures, __pyx_v_args, __pyx_v_kwargs, __pyx_v_defaults, __pyx_v__fused_sigindex);
   22346             : 
   22347             :   /* function exit code */
   22348             :   {
   22349         119 :     Py_ssize_t __pyx_temp;
   22350         119 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   22351             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   22352             :     }
   22353             :   }
   22354             :   __Pyx_RefNannyFinishContext();
   22355             :   return __pyx_r;
   22356             : }
   22357             : 
   22358         119 : static PyObject *__pyx_pf_9_ni_label_get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex) {
   22359         119 :   PyObject *__pyx_v_search_list = 0;
   22360         119 :   PyObject *__pyx_v_sigindex_node = 0;
   22361         119 :   PyObject *__pyx_v_dest_sig = NULL;
   22362         119 :   PyTypeObject *__pyx_v_ndarray = 0;
   22363         119 :   PyObject *__pyx_v_arg_as_memoryview = 0;
   22364         119 :   __Pyx_memviewslice __pyx_v_memslice;
   22365         119 :   Py_ssize_t __pyx_v_itemsize;
   22366         119 :   int __pyx_v_dtype_signed;
   22367         119 :   Py_UCS4 __pyx_v_kind;
   22368         119 :   int __pyx_v___pyx_fused_dtype_int8__t_is_signed;
   22369         119 :   int __pyx_v___pyx_fused_dtype_int16__t_is_signed;
   22370         119 :   int __pyx_v___pyx_fused_dtype_int32__t_is_signed;
   22371         119 :   int __pyx_v___pyx_fused_dtype_int64__t_is_signed;
   22372         119 :   int __pyx_v___pyx_fused_dtype_uint8__t_is_signed;
   22373         119 :   int __pyx_v___pyx_fused_dtype_uint16__t_is_signed;
   22374         119 :   int __pyx_v___pyx_fused_dtype_uint32__t_is_signed;
   22375         119 :   int __pyx_v___pyx_fused_dtype_uint64__t_is_signed;
   22376         119 :   PyObject *__pyx_v_arg = NULL;
   22377         119 :   PyObject *__pyx_v_dtype = NULL;
   22378         119 :   PyObject *__pyx_v_arg_base = NULL;
   22379         119 :   PyObject *__pyx_v_sig = NULL;
   22380         119 :   PyObject *__pyx_v_sig_series = NULL;
   22381         119 :   PyObject *__pyx_v_last_type = NULL;
   22382         119 :   PyObject *__pyx_v_sig_type = NULL;
   22383         119 :   PyObject *__pyx_v_sigindex_matches = NULL;
   22384         119 :   PyObject *__pyx_v_sigindex_candidates = NULL;
   22385         119 :   PyObject *__pyx_v_dst_type = NULL;
   22386         119 :   PyObject *__pyx_v_found_matches = NULL;
   22387         119 :   PyObject *__pyx_v_found_candidates = NULL;
   22388         119 :   PyObject *__pyx_v_sn = NULL;
   22389         119 :   PyObject *__pyx_v_type_match = NULL;
   22390         119 :   PyObject *__pyx_v_candidates = NULL;
   22391         119 :   PyObject *__pyx_r = NULL;
   22392             :   __Pyx_RefNannyDeclarations
   22393         119 :   PyObject *__pyx_t_1 = NULL;
   22394         119 :   int __pyx_t_2;
   22395         119 :   int __pyx_t_3;
   22396         119 :   int __pyx_t_4;
   22397         119 :   Py_ssize_t __pyx_t_5;
   22398         119 :   PyObject *__pyx_t_6 = NULL;
   22399         119 :   long __pyx_t_7;
   22400         119 :   PyObject *__pyx_t_8 = NULL;
   22401         119 :   PyObject *__pyx_t_9 = NULL;
   22402         119 :   PyObject *__pyx_t_10 = NULL;
   22403         119 :   int __pyx_t_11;
   22404         119 :   __Pyx_memviewslice __pyx_t_12;
   22405         119 :   PyObject *__pyx_t_13 = NULL;
   22406         119 :   Py_ssize_t __pyx_t_14;
   22407         119 :   int __pyx_t_15;
   22408         119 :   PyObject *__pyx_t_16 = NULL;
   22409         119 :   PyObject *__pyx_t_17 = NULL;
   22410         119 :   unsigned int __pyx_t_18;
   22411         119 :   Py_ssize_t __pyx_t_19;
   22412         119 :   int __pyx_t_20;
   22413         119 :   int __pyx_lineno = 0;
   22414         119 :   const char *__pyx_filename = NULL;
   22415         119 :   int __pyx_clineno = 0;
   22416         119 :   __Pyx_RefNannySetupContext("get_nonzero_line", 0);
   22417         119 :   __Pyx_INCREF(__pyx_v_kwargs);
   22418         119 :   __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22419         119 :   __Pyx_GOTREF(__pyx_t_1);
   22420         119 :   __Pyx_INCREF(Py_None);
   22421         119 :   __Pyx_GIVEREF(Py_None);
   22422         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_1, 0, Py_None)) __PYX_ERR(0, 93, __pyx_L1_error);
   22423         119 :   __pyx_v_dest_sig = ((PyObject*)__pyx_t_1);
   22424         119 :   __pyx_t_1 = 0;
   22425         119 :   __pyx_t_3 = (__pyx_v_kwargs != Py_None);
   22426         119 :   if (__pyx_t_3) {
   22427           0 :   } else {
   22428         119 :     __pyx_t_2 = __pyx_t_3;
   22429         119 :     goto __pyx_L4_bool_binop_done;
   22430             :   }
   22431           0 :   __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_kwargs); if (unlikely((__pyx_t_3 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22432           0 :   __pyx_t_4 = (!__pyx_t_3);
   22433           0 :   __pyx_t_2 = __pyx_t_4;
   22434         119 :   __pyx_L4_bool_binop_done:;
   22435         119 :   if (__pyx_t_2) {
   22436           0 :     __Pyx_INCREF(Py_None);
   22437           0 :     __Pyx_DECREF_SET(__pyx_v_kwargs, Py_None);
   22438             :   }
   22439         119 :   __pyx_t_1 = ((PyObject *)__Pyx_ImportNumPyArrayTypeIfAvailable()); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22440         119 :   __Pyx_GOTREF(__pyx_t_1);
   22441         119 :   __pyx_v_ndarray = ((PyTypeObject*)__pyx_t_1);
   22442         119 :   __pyx_t_1 = 0;
   22443         119 :   __pyx_v_itemsize = -1L;
   22444         119 :   __pyx_v___pyx_fused_dtype_int8__t_is_signed = (!(((__pyx_t_5numpy_int8_t)-1L) > 0));
   22445         119 :   __pyx_v___pyx_fused_dtype_int16__t_is_signed = (!(((__pyx_t_5numpy_int16_t)-1L) > 0));
   22446         119 :   __pyx_v___pyx_fused_dtype_int32__t_is_signed = (!(((__pyx_t_5numpy_int32_t)-1L) > 0));
   22447         119 :   __pyx_v___pyx_fused_dtype_int64__t_is_signed = (!(((__pyx_t_5numpy_int64_t)-1L) > 0));
   22448         119 :   __pyx_v___pyx_fused_dtype_uint8__t_is_signed = (!(((__pyx_t_5numpy_uint8_t)-1L) > 0));
   22449         119 :   __pyx_v___pyx_fused_dtype_uint16__t_is_signed = (!(((__pyx_t_5numpy_uint16_t)-1L) > 0));
   22450         119 :   __pyx_v___pyx_fused_dtype_uint32__t_is_signed = (!(((__pyx_t_5numpy_uint32_t)-1L) > 0));
   22451         119 :   __pyx_v___pyx_fused_dtype_uint64__t_is_signed = (!(((__pyx_t_5numpy_uint64_t)-1L) > 0));
   22452         119 :   if (unlikely(__pyx_v_args == Py_None)) {
   22453           0 :     PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   22454           0 :     __PYX_ERR(0, 93, __pyx_L1_error)
   22455             :   }
   22456         119 :   __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   22457         119 :   __pyx_t_2 = (0 < __pyx_t_5);
   22458         119 :   if (__pyx_t_2) {
   22459         119 :     if (unlikely(__pyx_v_args == Py_None)) {
   22460             :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   22461             :       __PYX_ERR(0, 93, __pyx_L1_error)
   22462             :     }
   22463         119 :     __pyx_t_1 = __Pyx_GetItemInt_Tuple(((PyObject*)__pyx_v_args), 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22464         119 :     __Pyx_GOTREF(__pyx_t_1);
   22465         119 :     __pyx_v_arg = __pyx_t_1;
   22466         119 :     __pyx_t_1 = 0;
   22467         119 :     goto __pyx_L6;
   22468             :   }
   22469           0 :   __pyx_t_4 = (__pyx_v_kwargs != Py_None);
   22470           0 :   if (__pyx_t_4) {
   22471           0 :   } else {
   22472           0 :     __pyx_t_2 = __pyx_t_4;
   22473           0 :     goto __pyx_L7_bool_binop_done;
   22474             :   }
   22475           0 :   if (unlikely(__pyx_v_kwargs == Py_None)) {
   22476             :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   22477             :     __PYX_ERR(0, 93, __pyx_L1_error)
   22478             :   }
   22479           0 :   __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_n_s_a, ((PyObject*)__pyx_v_kwargs), Py_EQ)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22480             :   __pyx_t_2 = __pyx_t_4;
   22481           0 :   __pyx_L7_bool_binop_done:;
   22482           0 :   if (likely(__pyx_t_2)) {
   22483           0 :     if (unlikely(__pyx_v_kwargs == Py_None)) {
   22484           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   22485           0 :       __PYX_ERR(0, 93, __pyx_L1_error)
   22486             :     }
   22487           0 :     __pyx_t_1 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_kwargs), __pyx_n_s_a); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22488           0 :     __Pyx_GOTREF(__pyx_t_1);
   22489           0 :     __pyx_v_arg = __pyx_t_1;
   22490           0 :     __pyx_t_1 = 0;
   22491           0 :     goto __pyx_L6;
   22492             :   }
   22493             :   /*else*/ {
   22494           0 :     if (unlikely(__pyx_v_args == Py_None)) {
   22495             :       PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   22496             :       __PYX_ERR(0, 93, __pyx_L1_error)
   22497             :     }
   22498           0 :     __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   22499           0 :     __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22500           0 :     __Pyx_GOTREF(__pyx_t_1);
   22501           0 :     __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22502           0 :     __Pyx_GOTREF(__pyx_t_6);
   22503           0 :     __Pyx_INCREF(__pyx_int_1);
   22504           0 :     __Pyx_GIVEREF(__pyx_int_1);
   22505           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_int_1)) __PYX_ERR(0, 93, __pyx_L1_error);
   22506           0 :     __Pyx_INCREF(__pyx_kp_s__11);
   22507           0 :     __Pyx_GIVEREF(__pyx_kp_s__11);
   22508           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_kp_s__11)) __PYX_ERR(0, 93, __pyx_L1_error);
   22509           0 :     __Pyx_GIVEREF(__pyx_t_1);
   22510           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error);
   22511           0 :     __pyx_t_1 = 0;
   22512           0 :     __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_Expected_at_least_d_argument_s_g, __pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   22513           0 :     __Pyx_GOTREF(__pyx_t_1);
   22514           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22515           0 :     __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22516           0 :     __Pyx_GOTREF(__pyx_t_6);
   22517           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   22518           0 :     __Pyx_Raise(__pyx_t_6, 0, 0, 0);
   22519           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22520           0 :     __PYX_ERR(0, 93, __pyx_L1_error)
   22521             :   }
   22522         119 :   __pyx_L6:;
   22523         119 :   while (1) {
   22524         119 :     __pyx_t_2 = (__pyx_v_ndarray != ((PyTypeObject*)Py_None));
   22525         119 :     if (__pyx_t_2) {
   22526         119 :       __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg, __pyx_v_ndarray); 
   22527         119 :       if (__pyx_t_2) {
   22528         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22529         119 :         __Pyx_GOTREF(__pyx_t_6);
   22530         119 :         __pyx_v_dtype = __pyx_t_6;
   22531         119 :         __pyx_t_6 = 0;
   22532         119 :         goto __pyx_L12;
   22533             :       }
   22534           0 :       __pyx_t_2 = __pyx_memoryview_check(__pyx_v_arg); 
   22535           0 :       if (__pyx_t_2) {
   22536           0 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_base); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22537           0 :         __Pyx_GOTREF(__pyx_t_6);
   22538           0 :         __pyx_v_arg_base = __pyx_t_6;
   22539           0 :         __pyx_t_6 = 0;
   22540           0 :         __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg_base, __pyx_v_ndarray); 
   22541           0 :         if (__pyx_t_2) {
   22542           0 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg_base, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22543           0 :           __Pyx_GOTREF(__pyx_t_6);
   22544           0 :           __pyx_v_dtype = __pyx_t_6;
   22545           0 :           __pyx_t_6 = 0;
   22546           0 :           goto __pyx_L13;
   22547             :         }
   22548             :         /*else*/ {
   22549           0 :           __Pyx_INCREF(Py_None);
   22550             :           __pyx_v_dtype = Py_None;
   22551             :         }
   22552           0 :         __pyx_L13:;
   22553           0 :         goto __pyx_L12;
   22554             :       }
   22555             :       /*else*/ {
   22556           0 :         __Pyx_INCREF(Py_None);
   22557             :         __pyx_v_dtype = Py_None;
   22558             :       }
   22559         119 :       __pyx_L12:;
   22560         119 :       __pyx_v_itemsize = -1L;
   22561         119 :       __pyx_t_2 = (__pyx_v_dtype != Py_None);
   22562         119 :       if (__pyx_t_2) {
   22563         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_itemsize); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22564         119 :         __Pyx_GOTREF(__pyx_t_6);
   22565         119 :         __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22566         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22567         119 :         __pyx_v_itemsize = __pyx_t_5;
   22568         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_kind); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22569         119 :         __Pyx_GOTREF(__pyx_t_6);
   22570         119 :         __pyx_t_7 = __Pyx_PyObject_Ord(__pyx_t_6); if (unlikely(__pyx_t_7 == ((long)(long)(Py_UCS4)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   22571         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22572         119 :         __pyx_v_kind = __pyx_t_7;
   22573         119 :         __pyx_v_dtype_signed = (__pyx_v_kind == 0x69);
   22574         119 :         switch (__pyx_v_kind) {
   22575          45 :           case 0x69:
   22576             :           case 0x75:
   22577          45 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int8_t)) == __pyx_v_itemsize);
   22578          45 :           if (__pyx_t_4) {
   22579          16 :           } else {
   22580          29 :             __pyx_t_2 = __pyx_t_4;
   22581          29 :             goto __pyx_L16_bool_binop_done;
   22582             :           }
   22583          16 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22584          16 :           __Pyx_GOTREF(__pyx_t_6);
   22585          16 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22586          16 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22587          16 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22588          16 :           if (__pyx_t_4) {
   22589          16 :           } else {
   22590           0 :             __pyx_t_2 = __pyx_t_4;
   22591           0 :             goto __pyx_L16_bool_binop_done;
   22592             :           }
   22593          16 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int8__t_is_signed ^ __pyx_v_dtype_signed));
   22594          16 :           __pyx_t_2 = __pyx_t_4;
   22595          45 :           __pyx_L16_bool_binop_done:;
   22596          45 :           if (__pyx_t_2) {
   22597           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22598           4 :             goto __pyx_L10_break;
   22599             :           }
   22600          41 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int16_t)) == __pyx_v_itemsize);
   22601          41 :           if (__pyx_t_4) {
   22602           8 :           } else {
   22603          33 :             __pyx_t_2 = __pyx_t_4;
   22604          33 :             goto __pyx_L20_bool_binop_done;
   22605             :           }
   22606           8 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22607           8 :           __Pyx_GOTREF(__pyx_t_6);
   22608           8 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22609           8 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22610           8 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22611           8 :           if (__pyx_t_4) {
   22612           8 :           } else {
   22613           0 :             __pyx_t_2 = __pyx_t_4;
   22614           0 :             goto __pyx_L20_bool_binop_done;
   22615             :           }
   22616           8 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int16__t_is_signed ^ __pyx_v_dtype_signed));
   22617           8 :           __pyx_t_2 = __pyx_t_4;
   22618          41 :           __pyx_L20_bool_binop_done:;
   22619          41 :           if (__pyx_t_2) {
   22620           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22621           4 :             goto __pyx_L10_break;
   22622             :           }
   22623          37 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int32_t)) == __pyx_v_itemsize);
   22624          37 :           if (__pyx_t_4) {
   22625           8 :           } else {
   22626          29 :             __pyx_t_2 = __pyx_t_4;
   22627          29 :             goto __pyx_L24_bool_binop_done;
   22628             :           }
   22629           8 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22630           8 :           __Pyx_GOTREF(__pyx_t_6);
   22631           8 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22632           8 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22633           8 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22634           8 :           if (__pyx_t_4) {
   22635           8 :           } else {
   22636           0 :             __pyx_t_2 = __pyx_t_4;
   22637           0 :             goto __pyx_L24_bool_binop_done;
   22638             :           }
   22639           8 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int32__t_is_signed ^ __pyx_v_dtype_signed));
   22640           8 :           __pyx_t_2 = __pyx_t_4;
   22641          37 :           __pyx_L24_bool_binop_done:;
   22642          37 :           if (__pyx_t_2) {
   22643           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22644           4 :             goto __pyx_L10_break;
   22645             :           }
   22646          33 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int64_t)) == __pyx_v_itemsize);
   22647          33 :           if (__pyx_t_4) {
   22648          13 :           } else {
   22649          20 :             __pyx_t_2 = __pyx_t_4;
   22650          20 :             goto __pyx_L28_bool_binop_done;
   22651             :           }
   22652          13 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22653          13 :           __Pyx_GOTREF(__pyx_t_6);
   22654          13 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22655          13 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22656          13 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22657          13 :           if (__pyx_t_4) {
   22658          13 :           } else {
   22659           0 :             __pyx_t_2 = __pyx_t_4;
   22660           0 :             goto __pyx_L28_bool_binop_done;
   22661             :           }
   22662          13 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int64__t_is_signed ^ __pyx_v_dtype_signed));
   22663          13 :           __pyx_t_2 = __pyx_t_4;
   22664          33 :           __pyx_L28_bool_binop_done:;
   22665          33 :           if (__pyx_t_2) {
   22666           9 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22667           9 :             goto __pyx_L10_break;
   22668             :           }
   22669          24 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint8_t)) == __pyx_v_itemsize);
   22670          24 :           if (__pyx_t_4) {
   22671          12 :           } else {
   22672          12 :             __pyx_t_2 = __pyx_t_4;
   22673          12 :             goto __pyx_L32_bool_binop_done;
   22674             :           }
   22675          12 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22676          12 :           __Pyx_GOTREF(__pyx_t_6);
   22677          12 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22678          12 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22679          12 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22680          12 :           if (__pyx_t_4) {
   22681          12 :           } else {
   22682           0 :             __pyx_t_2 = __pyx_t_4;
   22683           0 :             goto __pyx_L32_bool_binop_done;
   22684             :           }
   22685          12 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint8__t_is_signed ^ __pyx_v_dtype_signed));
   22686          12 :           __pyx_t_2 = __pyx_t_4;
   22687          24 :           __pyx_L32_bool_binop_done:;
   22688          24 :           if (__pyx_t_2) {
   22689          12 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22690          12 :             goto __pyx_L10_break;
   22691             :           }
   22692          12 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint16_t)) == __pyx_v_itemsize);
   22693          12 :           if (__pyx_t_4) {
   22694           4 :           } else {
   22695           8 :             __pyx_t_2 = __pyx_t_4;
   22696           8 :             goto __pyx_L36_bool_binop_done;
   22697             :           }
   22698           4 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22699           4 :           __Pyx_GOTREF(__pyx_t_6);
   22700           4 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22701           4 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22702           4 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22703           4 :           if (__pyx_t_4) {
   22704           4 :           } else {
   22705           0 :             __pyx_t_2 = __pyx_t_4;
   22706           0 :             goto __pyx_L36_bool_binop_done;
   22707             :           }
   22708           4 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint16__t_is_signed ^ __pyx_v_dtype_signed));
   22709           4 :           __pyx_t_2 = __pyx_t_4;
   22710          12 :           __pyx_L36_bool_binop_done:;
   22711          12 :           if (__pyx_t_2) {
   22712           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22713           4 :             goto __pyx_L10_break;
   22714             :           }
   22715           8 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint32_t)) == __pyx_v_itemsize);
   22716           8 :           if (__pyx_t_4) {
   22717           4 :           } else {
   22718           4 :             __pyx_t_2 = __pyx_t_4;
   22719           4 :             goto __pyx_L40_bool_binop_done;
   22720             :           }
   22721           4 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22722           4 :           __Pyx_GOTREF(__pyx_t_6);
   22723           4 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22724           4 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22725           4 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22726           4 :           if (__pyx_t_4) {
   22727           4 :           } else {
   22728           0 :             __pyx_t_2 = __pyx_t_4;
   22729           0 :             goto __pyx_L40_bool_binop_done;
   22730             :           }
   22731           4 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint32__t_is_signed ^ __pyx_v_dtype_signed));
   22732           4 :           __pyx_t_2 = __pyx_t_4;
   22733           8 :           __pyx_L40_bool_binop_done:;
   22734           8 :           if (__pyx_t_2) {
   22735           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22736           4 :             goto __pyx_L10_break;
   22737             :           }
   22738           4 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint64_t)) == __pyx_v_itemsize);
   22739           4 :           if (__pyx_t_4) {
   22740           4 :           } else {
   22741           0 :             __pyx_t_2 = __pyx_t_4;
   22742           0 :             goto __pyx_L44_bool_binop_done;
   22743             :           }
   22744           4 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22745           4 :           __Pyx_GOTREF(__pyx_t_6);
   22746           4 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22747           4 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22748           4 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22749           4 :           if (__pyx_t_4) {
   22750           4 :           } else {
   22751           0 :             __pyx_t_2 = __pyx_t_4;
   22752           0 :             goto __pyx_L44_bool_binop_done;
   22753             :           }
   22754           4 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint64__t_is_signed ^ __pyx_v_dtype_signed));
   22755           4 :           __pyx_t_2 = __pyx_t_4;
   22756           4 :           __pyx_L44_bool_binop_done:;
   22757           4 :           if (__pyx_t_2) {
   22758           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22759           4 :             goto __pyx_L10_break;
   22760             :           }
   22761             :           break;
   22762          74 :           case 0x66:
   22763          74 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float32_t)) == __pyx_v_itemsize);
   22764          74 :           if (__pyx_t_4) {
   22765           4 :           } else {
   22766          70 :             __pyx_t_2 = __pyx_t_4;
   22767          70 :             goto __pyx_L48_bool_binop_done;
   22768             :           }
   22769           4 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22770           4 :           __Pyx_GOTREF(__pyx_t_6);
   22771           4 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22772           4 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22773           4 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22774           4 :           __pyx_t_2 = __pyx_t_4;
   22775          74 :           __pyx_L48_bool_binop_done:;
   22776          74 :           if (__pyx_t_2) {
   22777           4 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22778           4 :             goto __pyx_L10_break;
   22779             :           }
   22780          70 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float64_t)) == __pyx_v_itemsize);
   22781          70 :           if (__pyx_t_4) {
   22782          70 :           } else {
   22783           0 :             __pyx_t_2 = __pyx_t_4;
   22784           0 :             goto __pyx_L51_bool_binop_done;
   22785             :           }
   22786          70 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   22787          70 :           __Pyx_GOTREF(__pyx_t_6);
   22788          70 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L1_error)
   22789          70 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   22790          70 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   22791          70 :           __pyx_t_2 = __pyx_t_4;
   22792          70 :           __pyx_L51_bool_binop_done:;
   22793          70 :           if (__pyx_t_2) {
   22794          70 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22795          70 :             goto __pyx_L10_break;
   22796             :           }
   22797             :           break;
   22798             :           case 99:
   22799             :           break;
   22800             :           case 79:
   22801             :           break;
   22802             :           default: break;
   22803             :         }
   22804             :       }
   22805             :     }
   22806           0 :     __pyx_t_2 = (__pyx_v_arg == Py_None);
   22807           0 :     if (__pyx_t_2) {
   22808           0 :       if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   22809           0 :       goto __pyx_L10_break;
   22810             :     }
   22811             :     {
   22812           0 :       __Pyx_PyThreadState_declare
   22813           0 :       __Pyx_PyThreadState_assign
   22814           0 :       __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10);
   22815           0 :       __Pyx_XGOTREF(__pyx_t_8);
   22816           0 :       __Pyx_XGOTREF(__pyx_t_9);
   22817           0 :       __Pyx_XGOTREF(__pyx_t_10);
   22818             :       /*try:*/ {
   22819           0 :         __pyx_t_6 = PyMemoryView_FromObject(__pyx_v_arg); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L54_error)
   22820           0 :         __Pyx_GOTREF(__pyx_t_6);
   22821           0 :         __pyx_v_arg_as_memoryview = ((PyObject*)__pyx_t_6);
   22822           0 :         __pyx_t_6 = 0;
   22823             :       }
   22824             :       /*else:*/ {
   22825           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   22826           0 :         if (!__pyx_t_4) {
   22827           0 :           goto __pyx_L65_next_or;
   22828             :         } else {
   22829           0 :         }
   22830           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22831           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int8_t)));
   22832           0 :         if (!__pyx_t_4) {
   22833             :         } else {
   22834           0 :           goto __pyx_L64_next_and;
   22835             :         }
   22836           0 :         __pyx_L65_next_or:;
   22837           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int8_t)));
   22838           0 :         if (__pyx_t_4) {
   22839             :         } else {
   22840           0 :           __pyx_t_2 = __pyx_t_4;
   22841           0 :           goto __pyx_L63_bool_binop_done;
   22842             :         }
   22843           0 :         __pyx_L64_next_and:;
   22844           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22845           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   22846           0 :         __pyx_t_2 = __pyx_t_4;
   22847           0 :         __pyx_L63_bool_binop_done:;
   22848           0 :         if (__pyx_t_2) {
   22849           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int8_t(__pyx_v_arg_as_memoryview, 0); 
   22850           0 :           __pyx_v_memslice = __pyx_t_12;
   22851           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   22852           0 :           if (__pyx_t_2) {
   22853           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   22854           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22855           0 :             goto __pyx_L59_try_break;
   22856             :           }
   22857             :           /*else*/ {
   22858           0 :             PyErr_Clear(); 
   22859             :           }
   22860             :         }
   22861           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   22862           0 :         if (!__pyx_t_4) {
   22863           0 :           goto __pyx_L71_next_or;
   22864             :         } else {
   22865           0 :         }
   22866           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22867           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int16_t)));
   22868           0 :         if (!__pyx_t_4) {
   22869             :         } else {
   22870           0 :           goto __pyx_L70_next_and;
   22871             :         }
   22872           0 :         __pyx_L71_next_or:;
   22873           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int16_t)));
   22874           0 :         if (__pyx_t_4) {
   22875             :         } else {
   22876           0 :           __pyx_t_2 = __pyx_t_4;
   22877           0 :           goto __pyx_L69_bool_binop_done;
   22878             :         }
   22879           0 :         __pyx_L70_next_and:;
   22880           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22881           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   22882           0 :         __pyx_t_2 = __pyx_t_4;
   22883           0 :         __pyx_L69_bool_binop_done:;
   22884           0 :         if (__pyx_t_2) {
   22885           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int16_t(__pyx_v_arg_as_memoryview, 0); 
   22886           0 :           __pyx_v_memslice = __pyx_t_12;
   22887           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   22888           0 :           if (__pyx_t_2) {
   22889           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   22890           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22891           0 :             goto __pyx_L59_try_break;
   22892             :           }
   22893             :           /*else*/ {
   22894           0 :             PyErr_Clear(); 
   22895             :           }
   22896             :         }
   22897           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   22898           0 :         if (!__pyx_t_4) {
   22899           0 :           goto __pyx_L77_next_or;
   22900             :         } else {
   22901           0 :         }
   22902           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22903           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int32_t)));
   22904           0 :         if (!__pyx_t_4) {
   22905             :         } else {
   22906           0 :           goto __pyx_L76_next_and;
   22907             :         }
   22908           0 :         __pyx_L77_next_or:;
   22909           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int32_t)));
   22910           0 :         if (__pyx_t_4) {
   22911             :         } else {
   22912           0 :           __pyx_t_2 = __pyx_t_4;
   22913           0 :           goto __pyx_L75_bool_binop_done;
   22914             :         }
   22915           0 :         __pyx_L76_next_and:;
   22916           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22917           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   22918           0 :         __pyx_t_2 = __pyx_t_4;
   22919           0 :         __pyx_L75_bool_binop_done:;
   22920           0 :         if (__pyx_t_2) {
   22921           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int32_t(__pyx_v_arg_as_memoryview, 0); 
   22922           0 :           __pyx_v_memslice = __pyx_t_12;
   22923           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   22924           0 :           if (__pyx_t_2) {
   22925           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   22926           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22927           0 :             goto __pyx_L59_try_break;
   22928             :           }
   22929             :           /*else*/ {
   22930           0 :             PyErr_Clear(); 
   22931             :           }
   22932             :         }
   22933           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   22934           0 :         if (!__pyx_t_4) {
   22935           0 :           goto __pyx_L83_next_or;
   22936             :         } else {
   22937           0 :         }
   22938           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22939           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int64_t)));
   22940           0 :         if (!__pyx_t_4) {
   22941             :         } else {
   22942           0 :           goto __pyx_L82_next_and;
   22943             :         }
   22944           0 :         __pyx_L83_next_or:;
   22945           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int64_t)));
   22946           0 :         if (__pyx_t_4) {
   22947             :         } else {
   22948           0 :           __pyx_t_2 = __pyx_t_4;
   22949           0 :           goto __pyx_L81_bool_binop_done;
   22950             :         }
   22951           0 :         __pyx_L82_next_and:;
   22952           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22953           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   22954           0 :         __pyx_t_2 = __pyx_t_4;
   22955           0 :         __pyx_L81_bool_binop_done:;
   22956           0 :         if (__pyx_t_2) {
   22957           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int64_t(__pyx_v_arg_as_memoryview, 0); 
   22958           0 :           __pyx_v_memslice = __pyx_t_12;
   22959           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   22960           0 :           if (__pyx_t_2) {
   22961           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   22962           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22963           0 :             goto __pyx_L59_try_break;
   22964             :           }
   22965             :           /*else*/ {
   22966           0 :             PyErr_Clear(); 
   22967             :           }
   22968             :         }
   22969           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   22970           0 :         if (!__pyx_t_4) {
   22971           0 :           goto __pyx_L89_next_or;
   22972             :         } else {
   22973           0 :         }
   22974           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22975           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint8_t)));
   22976           0 :         if (!__pyx_t_4) {
   22977             :         } else {
   22978           0 :           goto __pyx_L88_next_and;
   22979             :         }
   22980           0 :         __pyx_L89_next_or:;
   22981           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint8_t)));
   22982           0 :         if (__pyx_t_4) {
   22983             :         } else {
   22984           0 :           __pyx_t_2 = __pyx_t_4;
   22985           0 :           goto __pyx_L87_bool_binop_done;
   22986             :         }
   22987           0 :         __pyx_L88_next_and:;
   22988           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22989           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   22990           0 :         __pyx_t_2 = __pyx_t_4;
   22991           0 :         __pyx_L87_bool_binop_done:;
   22992           0 :         if (__pyx_t_2) {
   22993           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint8_t(__pyx_v_arg_as_memoryview, 0); 
   22994           0 :           __pyx_v_memslice = __pyx_t_12;
   22995           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   22996           0 :           if (__pyx_t_2) {
   22997           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   22998           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   22999           0 :             goto __pyx_L59_try_break;
   23000             :           }
   23001             :           /*else*/ {
   23002           0 :             PyErr_Clear(); 
   23003             :           }
   23004             :         }
   23005           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   23006           0 :         if (!__pyx_t_4) {
   23007           0 :           goto __pyx_L95_next_or;
   23008             :         } else {
   23009           0 :         }
   23010           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23011           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint16_t)));
   23012           0 :         if (!__pyx_t_4) {
   23013             :         } else {
   23014           0 :           goto __pyx_L94_next_and;
   23015             :         }
   23016           0 :         __pyx_L95_next_or:;
   23017           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint16_t)));
   23018           0 :         if (__pyx_t_4) {
   23019             :         } else {
   23020           0 :           __pyx_t_2 = __pyx_t_4;
   23021           0 :           goto __pyx_L93_bool_binop_done;
   23022             :         }
   23023           0 :         __pyx_L94_next_and:;
   23024           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23025           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   23026           0 :         __pyx_t_2 = __pyx_t_4;
   23027           0 :         __pyx_L93_bool_binop_done:;
   23028           0 :         if (__pyx_t_2) {
   23029           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint16_t(__pyx_v_arg_as_memoryview, 0); 
   23030           0 :           __pyx_v_memslice = __pyx_t_12;
   23031           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   23032           0 :           if (__pyx_t_2) {
   23033           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   23034           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23035           0 :             goto __pyx_L59_try_break;
   23036             :           }
   23037             :           /*else*/ {
   23038           0 :             PyErr_Clear(); 
   23039             :           }
   23040             :         }
   23041           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   23042           0 :         if (!__pyx_t_4) {
   23043           0 :           goto __pyx_L101_next_or;
   23044             :         } else {
   23045           0 :         }
   23046           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23047           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint32_t)));
   23048           0 :         if (!__pyx_t_4) {
   23049             :         } else {
   23050           0 :           goto __pyx_L100_next_and;
   23051             :         }
   23052           0 :         __pyx_L101_next_or:;
   23053           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint32_t)));
   23054           0 :         if (__pyx_t_4) {
   23055             :         } else {
   23056           0 :           __pyx_t_2 = __pyx_t_4;
   23057           0 :           goto __pyx_L99_bool_binop_done;
   23058             :         }
   23059           0 :         __pyx_L100_next_and:;
   23060           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23061           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   23062           0 :         __pyx_t_2 = __pyx_t_4;
   23063           0 :         __pyx_L99_bool_binop_done:;
   23064           0 :         if (__pyx_t_2) {
   23065           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint32_t(__pyx_v_arg_as_memoryview, 0); 
   23066           0 :           __pyx_v_memslice = __pyx_t_12;
   23067           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   23068           0 :           if (__pyx_t_2) {
   23069           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   23070           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23071           0 :             goto __pyx_L59_try_break;
   23072             :           }
   23073             :           /*else*/ {
   23074           0 :             PyErr_Clear(); 
   23075             :           }
   23076             :         }
   23077           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   23078           0 :         if (!__pyx_t_4) {
   23079           0 :           goto __pyx_L107_next_or;
   23080             :         } else {
   23081           0 :         }
   23082           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23083           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint64_t)));
   23084           0 :         if (!__pyx_t_4) {
   23085             :         } else {
   23086           0 :           goto __pyx_L106_next_and;
   23087             :         }
   23088           0 :         __pyx_L107_next_or:;
   23089           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint64_t)));
   23090           0 :         if (__pyx_t_4) {
   23091             :         } else {
   23092           0 :           __pyx_t_2 = __pyx_t_4;
   23093           0 :           goto __pyx_L105_bool_binop_done;
   23094             :         }
   23095           0 :         __pyx_L106_next_and:;
   23096           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23097           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   23098           0 :         __pyx_t_2 = __pyx_t_4;
   23099           0 :         __pyx_L105_bool_binop_done:;
   23100           0 :         if (__pyx_t_2) {
   23101           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint64_t(__pyx_v_arg_as_memoryview, 0); 
   23102           0 :           __pyx_v_memslice = __pyx_t_12;
   23103           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   23104           0 :           if (__pyx_t_2) {
   23105           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   23106           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23107           0 :             goto __pyx_L59_try_break;
   23108             :           }
   23109             :           /*else*/ {
   23110           0 :             PyErr_Clear(); 
   23111             :           }
   23112             :         }
   23113           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   23114           0 :         if (!__pyx_t_4) {
   23115           0 :           goto __pyx_L113_next_or;
   23116             :         } else {
   23117           0 :         }
   23118           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23119           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float32_t)));
   23120           0 :         if (!__pyx_t_4) {
   23121             :         } else {
   23122           0 :           goto __pyx_L112_next_and;
   23123             :         }
   23124           0 :         __pyx_L113_next_or:;
   23125           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float32_t)));
   23126           0 :         if (__pyx_t_4) {
   23127             :         } else {
   23128           0 :           __pyx_t_2 = __pyx_t_4;
   23129           0 :           goto __pyx_L111_bool_binop_done;
   23130             :         }
   23131           0 :         __pyx_L112_next_and:;
   23132           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23133           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   23134           0 :         __pyx_t_2 = __pyx_t_4;
   23135           0 :         __pyx_L111_bool_binop_done:;
   23136           0 :         if (__pyx_t_2) {
   23137           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float32_t(__pyx_v_arg_as_memoryview, 0); 
   23138           0 :           __pyx_v_memslice = __pyx_t_12;
   23139           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   23140           0 :           if (__pyx_t_2) {
   23141           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   23142           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23143           0 :             goto __pyx_L59_try_break;
   23144             :           }
   23145             :           /*else*/ {
   23146           0 :             PyErr_Clear(); 
   23147             :           }
   23148             :         }
   23149           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   23150           0 :         if (!__pyx_t_4) {
   23151           0 :           goto __pyx_L119_next_or;
   23152             :         } else {
   23153           0 :         }
   23154           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23155           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float64_t)));
   23156           0 :         if (!__pyx_t_4) {
   23157             :         } else {
   23158           0 :           goto __pyx_L118_next_and;
   23159             :         }
   23160           0 :         __pyx_L119_next_or:;
   23161           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float64_t)));
   23162           0 :         if (__pyx_t_4) {
   23163             :         } else {
   23164           0 :           __pyx_t_2 = __pyx_t_4;
   23165           0 :           goto __pyx_L117_bool_binop_done;
   23166             :         }
   23167           0 :         __pyx_L118_next_and:;
   23168           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23169           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   23170           0 :         __pyx_t_2 = __pyx_t_4;
   23171           0 :         __pyx_L117_bool_binop_done:;
   23172           0 :         if (__pyx_t_2) {
   23173           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float64_t(__pyx_v_arg_as_memoryview, 0); 
   23174           0 :           __pyx_v_memslice = __pyx_t_12;
   23175           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   23176           0 :           if (__pyx_t_2) {
   23177           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   23178           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23179           0 :             goto __pyx_L59_try_break;
   23180             :           }
   23181             :           /*else*/ {
   23182           0 :             PyErr_Clear(); 
   23183             :           }
   23184             :         }
   23185             :       }
   23186           0 :       __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   23187           0 :       __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
   23188           0 :       __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
   23189           0 :       goto __pyx_L61_try_end;
   23190           0 :       __pyx_L54_error:;
   23191           0 :       __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   23192           0 :       __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   23193           0 :       __pyx_t_11 = __Pyx_PyErr_ExceptionMatches2(__pyx_builtin_ValueError, __pyx_builtin_TypeError);
   23194           0 :       if (__pyx_t_11) {
   23195           0 :         __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23196           0 :         if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_1, &__pyx_t_13) < 0) __PYX_ERR(0, 93, __pyx_L56_except_error)
   23197           0 :         __Pyx_XGOTREF(__pyx_t_6);
   23198           0 :         __Pyx_XGOTREF(__pyx_t_1);
   23199           0 :         __Pyx_XGOTREF(__pyx_t_13);
   23200           0 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   23201           0 :         __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   23202           0 :         __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0;
   23203           0 :         goto __pyx_L55_exception_handled;
   23204             :       }
   23205           0 :       goto __pyx_L56_except_error;
   23206           0 :       __pyx_L56_except_error:;
   23207           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   23208           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   23209           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   23210           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   23211           0 :       goto __pyx_L1_error;
   23212           0 :       __pyx_L59_try_break:;
   23213           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   23214           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   23215           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   23216           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   23217           0 :       goto __pyx_L10_break;
   23218           0 :       __pyx_L55_exception_handled:;
   23219           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   23220           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   23221           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   23222           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   23223           0 :       __pyx_L61_try_end:;
   23224             :     }
   23225           0 :     if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, Py_None, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23226           0 :     goto __pyx_L10_break;
   23227             :   }
   23228         119 :   __pyx_L10_break:;
   23229         119 :   __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v__fused_sigindex); if (unlikely((__pyx_t_2 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23230         119 :   __pyx_t_4 = (!__pyx_t_2);
   23231         119 :   if (__pyx_t_4) {
   23232           1 :     __pyx_t_5 = 0;
   23233           1 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   23234           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   23235           0 :       __PYX_ERR(0, 93, __pyx_L1_error)
   23236             :     }
   23237           2 :     __pyx_t_1 = __Pyx_dict_iterator(((PyObject*)__pyx_v_signatures), 1, ((PyObject *)NULL), (&__pyx_t_14), (&__pyx_t_11)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23238           1 :     __Pyx_GOTREF(__pyx_t_1);
   23239           1 :     __Pyx_XDECREF(__pyx_t_13);
   23240           1 :     __pyx_t_13 = __pyx_t_1;
   23241           1 :     __pyx_t_1 = 0;
   23242          11 :     while (1) {
   23243          11 :       __pyx_t_15 = __Pyx_dict_iter_next(__pyx_t_13, __pyx_t_14, &__pyx_t_5, &__pyx_t_1, NULL, NULL, __pyx_t_11);
   23244          11 :       if (unlikely(__pyx_t_15 == 0)) break;
   23245          10 :       if (unlikely(__pyx_t_15 == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23246          10 :       __Pyx_GOTREF(__pyx_t_1);
   23247          10 :       __Pyx_XDECREF_SET(__pyx_v_sig, __pyx_t_1);
   23248          10 :       __pyx_t_1 = 0;
   23249          10 :       __pyx_t_1 = __pyx_v__fused_sigindex;
   23250          10 :       __Pyx_INCREF(__pyx_t_1);
   23251          10 :       __Pyx_XDECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_1));
   23252          10 :       __pyx_t_1 = 0;
   23253          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_sig, __pyx_n_s_strip); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23254          10 :       __Pyx_GOTREF(__pyx_t_16);
   23255          10 :       __pyx_t_17 = NULL;
   23256          10 :       __pyx_t_18 = 0;
   23257             :       #if CYTHON_UNPACK_METHODS
   23258          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   23259           0 :         __pyx_t_17 = PyMethod_GET_SELF(__pyx_t_16);
   23260           0 :         if (likely(__pyx_t_17)) {
   23261           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   23262           0 :           __Pyx_INCREF(__pyx_t_17);
   23263           0 :           __Pyx_INCREF(function);
   23264           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   23265             :           __pyx_t_18 = 1;
   23266             :         }
   23267             :       }
   23268             :       #endif
   23269             :       {
   23270          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_17, __pyx_kp_s__12};
   23271          10 :         __pyx_t_6 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   23272          10 :         __Pyx_XDECREF(__pyx_t_17); __pyx_t_17 = 0;
   23273          10 :         if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23274          10 :         __Pyx_GOTREF(__pyx_t_6);
   23275          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   23276             :       }
   23277          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_split); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23278          10 :       __Pyx_GOTREF(__pyx_t_16);
   23279          10 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   23280          10 :       __pyx_t_6 = NULL;
   23281          10 :       __pyx_t_18 = 0;
   23282             :       #if CYTHON_UNPACK_METHODS
   23283          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   23284           0 :         __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_16);
   23285           0 :         if (likely(__pyx_t_6)) {
   23286           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   23287           0 :           __Pyx_INCREF(__pyx_t_6);
   23288           0 :           __Pyx_INCREF(function);
   23289           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   23290             :           __pyx_t_18 = 1;
   23291             :         }
   23292             :       }
   23293             :       #endif
   23294             :       {
   23295          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_kp_s__13};
   23296          10 :         __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   23297          10 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   23298          10 :         if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23299          10 :         __Pyx_GOTREF(__pyx_t_1);
   23300          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   23301             :       }
   23302          20 :       __pyx_t_16 = __Pyx_PySequence_ListKeepNew(__pyx_t_1); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23303          10 :       __Pyx_GOTREF(__pyx_t_16);
   23304          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23305          10 :       __pyx_t_19 = PyList_GET_SIZE(__pyx_t_16);
   23306          10 :       if (unlikely(__pyx_t_19 < 1)) {
   23307           0 :         __Pyx_RaiseNeedMoreValuesError(0+__pyx_t_19); __PYX_ERR(0, 93, __pyx_L1_error)
   23308             :       }
   23309             :       #if CYTHON_COMPILING_IN_CPYTHON
   23310          10 :       __pyx_t_6 = PyList_GET_ITEM(__pyx_t_16, __pyx_t_19-1); 
   23311          10 :       ((PyVarObject*)__pyx_t_16)->ob_size--;
   23312             :       #else
   23313             :       __pyx_t_6 = PySequence_ITEM(__pyx_t_16, __pyx_t_19-1); 
   23314             :       #endif
   23315          10 :       __Pyx_GOTREF(__pyx_t_6);
   23316             :       #if !CYTHON_COMPILING_IN_CPYTHON
   23317             :       __pyx_t_17 = PySequence_GetSlice(__pyx_t_16, 0, __pyx_t_19-1); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 93, __pyx_L1_error)
   23318             :       __Pyx_GOTREF(__pyx_t_17);
   23319             :       __Pyx_DECREF(__pyx_t_16);
   23320             :       __pyx_t_16 = __pyx_t_17; __pyx_t_17 = NULL;
   23321             :       #else
   23322          10 :       CYTHON_UNUSED_VAR(__pyx_t_17);
   23323             :       #endif
   23324          10 :       __Pyx_XDECREF_SET(__pyx_v_sig_series, ((PyObject*)__pyx_t_16));
   23325          10 :       __pyx_t_16 = 0;
   23326          10 :       __Pyx_XDECREF_SET(__pyx_v_last_type, __pyx_t_6);
   23327          10 :       __pyx_t_6 = 0;
   23328          10 :       __pyx_t_1 = __pyx_v_sig_series; __Pyx_INCREF(__pyx_t_1);
   23329             :       __pyx_t_19 = 0;
   23330          10 :       for (;;) {
   23331             :         {
   23332          10 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   23333             :           #if !CYTHON_ASSUME_SAFE_MACROS
   23334             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23335             :           #endif
   23336          10 :           if (__pyx_t_19 >= __pyx_temp) break;
   23337             :         }
   23338             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23339           0 :         __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23340             :         #else
   23341             :         __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23342             :         __Pyx_GOTREF(__pyx_t_6);
   23343             :         #endif
   23344           0 :         __Pyx_XDECREF_SET(__pyx_v_sig_type, __pyx_t_6);
   23345           0 :         __pyx_t_6 = 0;
   23346           0 :         if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   23347           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   23348           0 :           __PYX_ERR(0, 93, __pyx_L1_error)
   23349             :         }
   23350           0 :         __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_v_sig_type, __pyx_v_sigindex_node, Py_NE)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23351           0 :         if (__pyx_t_4) {
   23352           0 :           __pyx_t_6 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23353           0 :           __Pyx_GOTREF(__pyx_t_6);
   23354           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   23355             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   23356             :             __PYX_ERR(0, 93, __pyx_L1_error)
   23357             :           }
   23358           0 :           if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_sig_type, __pyx_t_6) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23359           0 :           __Pyx_INCREF(__pyx_t_6);
   23360           0 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, __pyx_t_6);
   23361           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   23362           0 :           goto __pyx_L129;
   23363             :         }
   23364             :         /*else*/ {
   23365           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   23366             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   23367             :             __PYX_ERR(0, 93, __pyx_L1_error)
   23368             :           }
   23369           0 :           __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_sigindex_node, __pyx_v_sig_type); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23370           0 :           __Pyx_GOTREF(__pyx_t_6);
   23371           0 :           __pyx_t_16 = __pyx_t_6;
   23372           0 :           __Pyx_INCREF(__pyx_t_16);
   23373           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   23374          10 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_16));
   23375             :           __pyx_t_16 = 0;
   23376             :         }
   23377             :         __pyx_L129:;
   23378             :       }
   23379          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23380          10 :       if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   23381           0 :         PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   23382           0 :         __PYX_ERR(0, 93, __pyx_L1_error)
   23383             :       }
   23384          10 :       if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_last_type, __pyx_v_sig) < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23385             :     }
   23386           2 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23387             :   }
   23388         119 :   __pyx_t_13 = PyList_New(0); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 93, __pyx_L1_error)
   23389         119 :   __Pyx_GOTREF(__pyx_t_13);
   23390         119 :   __pyx_v_sigindex_matches = ((PyObject*)__pyx_t_13);
   23391         119 :   __pyx_t_13 = 0;
   23392         119 :   __pyx_t_13 = PyList_New(1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 93, __pyx_L1_error)
   23393         119 :   __Pyx_GOTREF(__pyx_t_13);
   23394         119 :   __Pyx_INCREF(__pyx_v__fused_sigindex);
   23395         119 :   __Pyx_GIVEREF(__pyx_v__fused_sigindex);
   23396         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_13, 0, __pyx_v__fused_sigindex)) __PYX_ERR(0, 93, __pyx_L1_error);
   23397         119 :   __pyx_v_sigindex_candidates = ((PyObject*)__pyx_t_13);
   23398         119 :   __pyx_t_13 = 0;
   23399         119 :   __pyx_t_13 = __pyx_v_dest_sig; __Pyx_INCREF(__pyx_t_13);
   23400             :   __pyx_t_14 = 0;
   23401         238 :   for (;;) {
   23402             :     {
   23403         238 :       Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_13);
   23404             :       #if !CYTHON_ASSUME_SAFE_MACROS
   23405             :       if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23406             :       #endif
   23407         238 :       if (__pyx_t_14 >= __pyx_temp) break;
   23408             :     }
   23409             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23410         119 :     __pyx_t_1 = PyList_GET_ITEM(__pyx_t_13, __pyx_t_14); __Pyx_INCREF(__pyx_t_1); __pyx_t_14++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23411             :     #else
   23412             :     __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_13, __pyx_t_14); __pyx_t_14++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23413             :     __Pyx_GOTREF(__pyx_t_1);
   23414             :     #endif
   23415         119 :     __Pyx_XDECREF_SET(__pyx_v_dst_type, __pyx_t_1);
   23416         119 :     __pyx_t_1 = 0;
   23417         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23418         119 :     __Pyx_GOTREF(__pyx_t_1);
   23419         119 :     __Pyx_XDECREF_SET(__pyx_v_found_matches, ((PyObject*)__pyx_t_1));
   23420         119 :     __pyx_t_1 = 0;
   23421         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23422         119 :     __Pyx_GOTREF(__pyx_t_1);
   23423         119 :     __Pyx_XDECREF_SET(__pyx_v_found_candidates, ((PyObject*)__pyx_t_1));
   23424         119 :     __pyx_t_1 = 0;
   23425         119 :     __pyx_t_4 = (__pyx_v_dst_type == Py_None);
   23426         119 :     if (__pyx_t_4) {
   23427           0 :       __pyx_t_1 = __pyx_v_sigindex_matches; __Pyx_INCREF(__pyx_t_1);
   23428           0 :       __pyx_t_5 = 0;
   23429           0 :       for (;;) {
   23430             :         {
   23431           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   23432             :           #if !CYTHON_ASSUME_SAFE_MACROS
   23433             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23434             :           #endif
   23435           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   23436             :         }
   23437             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23438           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23439             :         #else
   23440             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23441             :         __Pyx_GOTREF(__pyx_t_16);
   23442             :         #endif
   23443           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   23444           0 :         __pyx_t_16 = 0;
   23445           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   23446           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   23447           0 :           __PYX_ERR(0, 93, __pyx_L1_error)
   23448             :         }
   23449           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23450           0 :         __Pyx_GOTREF(__pyx_t_16);
   23451           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_matches, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   23452           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   23453             :       }
   23454           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23455           0 :       __pyx_t_1 = __pyx_v_sigindex_candidates; __Pyx_INCREF(__pyx_t_1);
   23456           0 :       __pyx_t_5 = 0;
   23457           0 :       for (;;) {
   23458             :         {
   23459           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   23460             :           #if !CYTHON_ASSUME_SAFE_MACROS
   23461             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23462             :           #endif
   23463           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   23464             :         }
   23465             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23466           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23467             :         #else
   23468             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23469             :         __Pyx_GOTREF(__pyx_t_16);
   23470             :         #endif
   23471           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   23472           0 :         __pyx_t_16 = 0;
   23473           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   23474           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   23475           0 :           __PYX_ERR(0, 93, __pyx_L1_error)
   23476             :         }
   23477           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23478           0 :         __Pyx_GOTREF(__pyx_t_16);
   23479           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_candidates, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   23480           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   23481             :       }
   23482           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23483           0 :       goto __pyx_L133;
   23484             :     }
   23485             :     /*else*/ {
   23486         119 :       __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23487         119 :       __Pyx_GOTREF(__pyx_t_1);
   23488         119 :       __Pyx_INCREF(__pyx_v_sigindex_matches);
   23489         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_matches);
   23490         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_sigindex_matches)) __PYX_ERR(0, 93, __pyx_L1_error);
   23491         119 :       __Pyx_INCREF(__pyx_v_sigindex_candidates);
   23492         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_candidates);
   23493         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_sigindex_candidates)) __PYX_ERR(0, 93, __pyx_L1_error);
   23494         119 :       __pyx_t_16 = __pyx_t_1; __Pyx_INCREF(__pyx_t_16);
   23495         119 :       __pyx_t_5 = 0;
   23496         238 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23497         595 :       for (;;) {
   23498         357 :         if (__pyx_t_5 >= 2) break;
   23499             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23500         238 :         __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_16, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23501             :         #else
   23502             :         __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_16, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23503             :         __Pyx_GOTREF(__pyx_t_1);
   23504             :         #endif
   23505         238 :         __Pyx_XDECREF_SET(__pyx_v_search_list, ((PyObject*)__pyx_t_1));
   23506         238 :         __pyx_t_1 = 0;
   23507         238 :         if (unlikely(__pyx_v_search_list == Py_None)) {
   23508           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   23509           0 :           __PYX_ERR(0, 93, __pyx_L1_error)
   23510             :         }
   23511         238 :         __pyx_t_1 = __pyx_v_search_list; __Pyx_INCREF(__pyx_t_1);
   23512             :         __pyx_t_19 = 0;
   23513         357 :         for (;;) {
   23514             :           {
   23515         357 :             Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   23516             :             #if !CYTHON_ASSUME_SAFE_MACROS
   23517             :             if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23518             :             #endif
   23519         357 :             if (__pyx_t_19 >= __pyx_temp) break;
   23520             :           }
   23521             :           #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   23522         119 :           __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23523             :           #else
   23524             :           __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23525             :           __Pyx_GOTREF(__pyx_t_6);
   23526             :           #endif
   23527         119 :           __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_6);
   23528         119 :           __pyx_t_6 = 0;
   23529         119 :           if (unlikely(__pyx_v_sn == Py_None)) {
   23530           0 :             PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get");
   23531           0 :             __PYX_ERR(0, 93, __pyx_L1_error)
   23532             :           }
   23533         119 :           __pyx_t_6 = __Pyx_PyDict_GetItemDefault(((PyObject*)__pyx_v_sn), __pyx_v_dst_type, Py_None); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 93, __pyx_L1_error)
   23534         119 :           __Pyx_GOTREF(__pyx_t_6);
   23535         119 :           __Pyx_XDECREF_SET(__pyx_v_type_match, __pyx_t_6);
   23536         119 :           __pyx_t_6 = 0;
   23537         119 :           __pyx_t_4 = (__pyx_v_type_match != Py_None);
   23538         119 :           if (__pyx_t_4) {
   23539         119 :             __pyx_t_20 = __Pyx_PyList_Append(__pyx_v_found_matches, __pyx_v_type_match); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   23540             :           }
   23541             :         }
   23542         476 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   23543             :       }
   23544         119 :       __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   23545             :     }
   23546         119 :     __pyx_L133:;
   23547         119 :     __Pyx_INCREF(__pyx_v_found_matches);
   23548         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_matches, __pyx_v_found_matches);
   23549         119 :     __Pyx_INCREF(__pyx_v_found_candidates);
   23550         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_candidates, __pyx_v_found_candidates);
   23551         119 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_matches) != 0);
   23552         119 :     if (!__pyx_t_2) {
   23553           0 :     } else {
   23554         119 :       __pyx_t_4 = __pyx_t_2;
   23555         119 :       goto __pyx_L148_bool_binop_done;
   23556             :     }
   23557           0 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_candidates) != 0);
   23558           0 :     __pyx_t_4 = __pyx_t_2;
   23559         119 :     __pyx_L148_bool_binop_done:;
   23560         119 :     __pyx_t_2 = (!__pyx_t_4);
   23561         119 :     if (__pyx_t_2) {
   23562           0 :       goto __pyx_L132_break;
   23563             :     }
   23564             :   }
   23565         119 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23566         119 :   goto __pyx_L150_for_end;
   23567           0 :   __pyx_L132_break:;
   23568           0 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23569           0 :   goto __pyx_L150_for_end;
   23570         119 :   __pyx_L150_for_end:;
   23571         119 :   __Pyx_INCREF(__pyx_v_sigindex_matches);
   23572         119 :   __pyx_v_candidates = __pyx_v_sigindex_matches;
   23573         119 :   __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_candidates) != 0);
   23574         119 :   __pyx_t_4 = (!__pyx_t_2);
   23575         119 :   if (unlikely(__pyx_t_4)) {
   23576           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__14, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 93, __pyx_L1_error)
   23577           0 :     __Pyx_GOTREF(__pyx_t_13);
   23578           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   23579           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23580           0 :     __PYX_ERR(0, 93, __pyx_L1_error)
   23581             :   }
   23582         119 :   __pyx_t_14 = __Pyx_PyList_GET_SIZE(__pyx_v_candidates); if (unlikely(__pyx_t_14 == ((Py_ssize_t)-1))) __PYX_ERR(0, 93, __pyx_L1_error)
   23583         119 :   __pyx_t_4 = (__pyx_t_14 > 1);
   23584         119 :   if (unlikely(__pyx_t_4)) {
   23585           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__15, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 93, __pyx_L1_error)
   23586           0 :     __Pyx_GOTREF(__pyx_t_13);
   23587           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   23588           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23589           0 :     __PYX_ERR(0, 93, __pyx_L1_error)
   23590             :   }
   23591             :   /*else*/ {
   23592         119 :     __Pyx_XDECREF(__pyx_r);
   23593         119 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   23594           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   23595           0 :       __PYX_ERR(0, 93, __pyx_L1_error)
   23596             :     }
   23597         119 :     __pyx_t_13 = __Pyx_GetItemInt_List(__pyx_v_candidates, 0, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 93, __pyx_L1_error)
   23598         119 :     __Pyx_GOTREF(__pyx_t_13);
   23599         119 :     __pyx_t_16 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_signatures), __pyx_t_13); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 93, __pyx_L1_error)
   23600         119 :     __Pyx_GOTREF(__pyx_t_16);
   23601         119 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   23602         119 :     __pyx_r = __pyx_t_16;
   23603         119 :     __pyx_t_16 = 0;
   23604         119 :     goto __pyx_L0;
   23605             :   }
   23606             : 
   23607             :   /* function exit code */
   23608           0 :   __pyx_L1_error:;
   23609           0 :   __Pyx_XDECREF(__pyx_t_1);
   23610           0 :   __Pyx_XDECREF(__pyx_t_6);
   23611           0 :   __Pyx_XDECREF(__pyx_t_13);
   23612           0 :   __Pyx_XDECREF(__pyx_t_16);
   23613           0 :   __Pyx_XDECREF(__pyx_t_17);
   23614           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23615           0 :   __pyx_r = NULL;
   23616         119 :   __pyx_L0:;
   23617         119 :   __Pyx_XDECREF(__pyx_v_search_list);
   23618         119 :   __Pyx_XDECREF(__pyx_v_sigindex_node);
   23619         119 :   __Pyx_XDECREF(__pyx_v_dest_sig);
   23620         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_ndarray);
   23621         119 :   __Pyx_XDECREF(__pyx_v_arg_as_memoryview);
   23622         119 :   __Pyx_XDECREF(__pyx_v_arg);
   23623         119 :   __Pyx_XDECREF(__pyx_v_dtype);
   23624         119 :   __Pyx_XDECREF(__pyx_v_arg_base);
   23625         119 :   __Pyx_XDECREF(__pyx_v_sig);
   23626         119 :   __Pyx_XDECREF(__pyx_v_sig_series);
   23627         119 :   __Pyx_XDECREF(__pyx_v_last_type);
   23628         119 :   __Pyx_XDECREF(__pyx_v_sig_type);
   23629         119 :   __Pyx_XDECREF(__pyx_v_sigindex_matches);
   23630         119 :   __Pyx_XDECREF(__pyx_v_sigindex_candidates);
   23631         119 :   __Pyx_XDECREF(__pyx_v_dst_type);
   23632         119 :   __Pyx_XDECREF(__pyx_v_found_matches);
   23633         119 :   __Pyx_XDECREF(__pyx_v_found_candidates);
   23634         119 :   __Pyx_XDECREF(__pyx_v_sn);
   23635         119 :   __Pyx_XDECREF(__pyx_v_type_match);
   23636         119 :   __Pyx_XDECREF(__pyx_v_candidates);
   23637         119 :   __Pyx_XDECREF(__pyx_v_kwargs);
   23638         119 :   __Pyx_XGIVEREF(__pyx_r);
   23639         119 :   __Pyx_RefNannyFinishContext();
   23640         119 :   return __pyx_r;
   23641             : }
   23642             : 
   23643             : /* Python wrapper */
   23644             : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_9get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   23645             : static PyMethodDef __pyx_fuse_0__pyx_mdef_9_ni_label_9get_nonzero_line = {"__pyx_fuse_0get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_0__pyx_pw_9_ni_label_9get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   23646           4 : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_9get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   23647           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   23648           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   23649           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   23650           4 :   PyObject* values[1] = {0};
   23651           4 :   int __pyx_lineno = 0;
   23652           4 :   const char *__pyx_filename = NULL;
   23653           4 :   int __pyx_clineno = 0;
   23654           4 :   PyObject *__pyx_r = 0;
   23655             :   __Pyx_RefNannyDeclarations
   23656           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   23657             :   #if CYTHON_ASSUME_SAFE_MACROS
   23658           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   23659             :   #else
   23660             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   23661             :   #endif
   23662           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   23663             :   {
   23664           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   23665           4 :     if (__pyx_kwds) {
   23666           0 :       Py_ssize_t kw_args;
   23667           0 :       switch (__pyx_nargs) {
   23668           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23669           0 :         CYTHON_FALLTHROUGH;
   23670           0 :         case  0: break;
   23671           0 :         default: goto __pyx_L5_argtuple_error;
   23672             :       }
   23673           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   23674           0 :       switch (__pyx_nargs) {
   23675           0 :         case  0:
   23676           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   23677           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   23678           0 :           kw_args--;
   23679             :         }
   23680           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   23681           0 :         else goto __pyx_L5_argtuple_error;
   23682             :       }
   23683           0 :       if (unlikely(kw_args > 0)) {
   23684           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   23685           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   23686             :       }
   23687           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   23688           0 :       goto __pyx_L5_argtuple_error;
   23689             :     } else {
   23690           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23691             :     }
   23692           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   23693             :   }
   23694           4 :   goto __pyx_L6_skip;
   23695           0 :   __pyx_L5_argtuple_error:;
   23696           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   23697           4 :   __pyx_L6_skip:;
   23698           4 :   goto __pyx_L4_argument_unpacking_done;
   23699           0 :   __pyx_L3_error:;
   23700             :   {
   23701           0 :     Py_ssize_t __pyx_temp;
   23702           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   23703             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   23704             :     }
   23705             :   }
   23706           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23707           0 :   __Pyx_RefNannyFinishContext();
   23708           0 :   return NULL;
   23709           4 :   __pyx_L4_argument_unpacking_done:;
   23710           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23711           4 :   __pyx_r = __pyx_pf_9_ni_label_8get_nonzero_line(__pyx_self, __pyx_v_a);
   23712             : 
   23713             :   /* function exit code */
   23714           4 :   goto __pyx_L0;
   23715           0 :   __pyx_L1_error:;
   23716           0 :   __pyx_r = NULL;
   23717           4 :   __pyx_L0:;
   23718             :   {
   23719           4 :     Py_ssize_t __pyx_temp;
   23720           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   23721             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   23722             :     }
   23723             :   }
   23724             :   __Pyx_RefNannyFinishContext();
   23725             :   return __pyx_r;
   23726             : }
   23727             : 
   23728           4 : static PyObject *__pyx_pf_9_ni_label_8get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   23729           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   23730           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   23731           4 :   PyObject *__pyx_r = NULL;
   23732             :   __Pyx_RefNannyDeclarations
   23733           4 :   PyObject *__pyx_t_1 = NULL;
   23734           4 :   int __pyx_lineno = 0;
   23735           4 :   const char *__pyx_filename = NULL;
   23736           4 :   int __pyx_clineno = 0;
   23737           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_0get_nonzero_line", 1);
   23738           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   23739           4 :   __pyx_pybuffer_a.refcount = 0;
   23740           4 :   __pyx_pybuffernd_a.data = NULL;
   23741           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   23742             :   {
   23743           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   23744           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23745             :   }
   23746           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   23747             : 
   23748             :   /* "_ni_label.pyx":94
   23749             :  * ######################################################################
   23750             :  * def get_nonzero_line(np.ndarray[data_t] a):
   23751             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   23752             :  * 
   23753             :  * def get_read_line(np.ndarray[data_t] a):
   23754             :  */
   23755           4 :   __Pyx_XDECREF(__pyx_r);
   23756           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_0__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   23757           4 :   __Pyx_GOTREF(__pyx_t_1);
   23758           4 :   __pyx_r = __pyx_t_1;
   23759           4 :   __pyx_t_1 = 0;
   23760           4 :   goto __pyx_L0;
   23761             : 
   23762             :   /* "_ni_label.pyx":93
   23763             :  * # Function specializers
   23764             :  * ######################################################################
   23765             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   23766             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   23767             :  * 
   23768             :  */
   23769             : 
   23770             :   /* function exit code */
   23771           0 :   __pyx_L1_error:;
   23772           0 :   __Pyx_XDECREF(__pyx_t_1);
   23773           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   23774           0 :     __Pyx_PyThreadState_declare
   23775           0 :     __Pyx_PyThreadState_assign
   23776           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   23777           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   23778           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   23779           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23780           0 :   __pyx_r = NULL;
   23781           0 :   goto __pyx_L2;
   23782           4 :   __pyx_L0:;
   23783           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   23784           4 :   __pyx_L2:;
   23785           4 :   __Pyx_XGIVEREF(__pyx_r);
   23786           4 :   __Pyx_RefNannyFinishContext();
   23787           4 :   return __pyx_r;
   23788             : }
   23789             : 
   23790             : /* Python wrapper */
   23791             : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_11get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   23792             : static PyMethodDef __pyx_fuse_1__pyx_mdef_9_ni_label_11get_nonzero_line = {"__pyx_fuse_1get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_1__pyx_pw_9_ni_label_11get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   23793           4 : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_11get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   23794           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   23795           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   23796           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   23797           4 :   PyObject* values[1] = {0};
   23798           4 :   int __pyx_lineno = 0;
   23799           4 :   const char *__pyx_filename = NULL;
   23800           4 :   int __pyx_clineno = 0;
   23801           4 :   PyObject *__pyx_r = 0;
   23802             :   __Pyx_RefNannyDeclarations
   23803           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   23804             :   #if CYTHON_ASSUME_SAFE_MACROS
   23805           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   23806             :   #else
   23807             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   23808             :   #endif
   23809           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   23810             :   {
   23811           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   23812           4 :     if (__pyx_kwds) {
   23813           0 :       Py_ssize_t kw_args;
   23814           0 :       switch (__pyx_nargs) {
   23815           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23816           0 :         CYTHON_FALLTHROUGH;
   23817           0 :         case  0: break;
   23818           0 :         default: goto __pyx_L5_argtuple_error;
   23819             :       }
   23820           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   23821           0 :       switch (__pyx_nargs) {
   23822           0 :         case  0:
   23823           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   23824           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   23825           0 :           kw_args--;
   23826             :         }
   23827           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   23828           0 :         else goto __pyx_L5_argtuple_error;
   23829             :       }
   23830           0 :       if (unlikely(kw_args > 0)) {
   23831           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   23832           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   23833             :       }
   23834           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   23835           0 :       goto __pyx_L5_argtuple_error;
   23836             :     } else {
   23837           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23838             :     }
   23839           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   23840             :   }
   23841           4 :   goto __pyx_L6_skip;
   23842           0 :   __pyx_L5_argtuple_error:;
   23843           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   23844           4 :   __pyx_L6_skip:;
   23845           4 :   goto __pyx_L4_argument_unpacking_done;
   23846           0 :   __pyx_L3_error:;
   23847             :   {
   23848           0 :     Py_ssize_t __pyx_temp;
   23849           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   23850             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   23851             :     }
   23852             :   }
   23853           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23854           0 :   __Pyx_RefNannyFinishContext();
   23855           0 :   return NULL;
   23856           4 :   __pyx_L4_argument_unpacking_done:;
   23857           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   23858           4 :   __pyx_r = __pyx_pf_9_ni_label_10get_nonzero_line(__pyx_self, __pyx_v_a);
   23859             : 
   23860             :   /* function exit code */
   23861           4 :   goto __pyx_L0;
   23862           0 :   __pyx_L1_error:;
   23863           0 :   __pyx_r = NULL;
   23864           4 :   __pyx_L0:;
   23865             :   {
   23866           4 :     Py_ssize_t __pyx_temp;
   23867           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   23868             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   23869             :     }
   23870             :   }
   23871             :   __Pyx_RefNannyFinishContext();
   23872             :   return __pyx_r;
   23873             : }
   23874             : 
   23875           4 : static PyObject *__pyx_pf_9_ni_label_10get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   23876           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   23877           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   23878           4 :   PyObject *__pyx_r = NULL;
   23879             :   __Pyx_RefNannyDeclarations
   23880           4 :   PyObject *__pyx_t_1 = NULL;
   23881           4 :   int __pyx_lineno = 0;
   23882           4 :   const char *__pyx_filename = NULL;
   23883           4 :   int __pyx_clineno = 0;
   23884           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_1get_nonzero_line", 1);
   23885           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   23886           4 :   __pyx_pybuffer_a.refcount = 0;
   23887           4 :   __pyx_pybuffernd_a.data = NULL;
   23888           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   23889             :   {
   23890           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   23891           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   23892             :   }
   23893           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   23894             : 
   23895             :   /* "_ni_label.pyx":94
   23896             :  * ######################################################################
   23897             :  * def get_nonzero_line(np.ndarray[data_t] a):
   23898             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   23899             :  * 
   23900             :  * def get_read_line(np.ndarray[data_t] a):
   23901             :  */
   23902           4 :   __Pyx_XDECREF(__pyx_r);
   23903           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_1__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   23904           4 :   __Pyx_GOTREF(__pyx_t_1);
   23905           4 :   __pyx_r = __pyx_t_1;
   23906           4 :   __pyx_t_1 = 0;
   23907           4 :   goto __pyx_L0;
   23908             : 
   23909             :   /* "_ni_label.pyx":93
   23910             :  * # Function specializers
   23911             :  * ######################################################################
   23912             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   23913             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   23914             :  * 
   23915             :  */
   23916             : 
   23917             :   /* function exit code */
   23918           0 :   __pyx_L1_error:;
   23919           0 :   __Pyx_XDECREF(__pyx_t_1);
   23920           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   23921           0 :     __Pyx_PyThreadState_declare
   23922           0 :     __Pyx_PyThreadState_assign
   23923           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   23924           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   23925           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   23926           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   23927           0 :   __pyx_r = NULL;
   23928           0 :   goto __pyx_L2;
   23929           4 :   __pyx_L0:;
   23930           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   23931           4 :   __pyx_L2:;
   23932           4 :   __Pyx_XGIVEREF(__pyx_r);
   23933           4 :   __Pyx_RefNannyFinishContext();
   23934           4 :   return __pyx_r;
   23935             : }
   23936             : 
   23937             : /* Python wrapper */
   23938             : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_13get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   23939             : static PyMethodDef __pyx_fuse_2__pyx_mdef_9_ni_label_13get_nonzero_line = {"__pyx_fuse_2get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_2__pyx_pw_9_ni_label_13get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   23940           4 : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_13get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   23941           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   23942           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   23943           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   23944           4 :   PyObject* values[1] = {0};
   23945           4 :   int __pyx_lineno = 0;
   23946           4 :   const char *__pyx_filename = NULL;
   23947           4 :   int __pyx_clineno = 0;
   23948           4 :   PyObject *__pyx_r = 0;
   23949             :   __Pyx_RefNannyDeclarations
   23950           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   23951             :   #if CYTHON_ASSUME_SAFE_MACROS
   23952           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   23953             :   #else
   23954             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   23955             :   #endif
   23956           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   23957             :   {
   23958           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   23959           4 :     if (__pyx_kwds) {
   23960           0 :       Py_ssize_t kw_args;
   23961           0 :       switch (__pyx_nargs) {
   23962           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23963           0 :         CYTHON_FALLTHROUGH;
   23964           0 :         case  0: break;
   23965           0 :         default: goto __pyx_L5_argtuple_error;
   23966             :       }
   23967           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   23968           0 :       switch (__pyx_nargs) {
   23969           0 :         case  0:
   23970           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   23971           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   23972           0 :           kw_args--;
   23973             :         }
   23974           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   23975           0 :         else goto __pyx_L5_argtuple_error;
   23976             :       }
   23977           0 :       if (unlikely(kw_args > 0)) {
   23978           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   23979           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   23980             :       }
   23981           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   23982           0 :       goto __pyx_L5_argtuple_error;
   23983             :     } else {
   23984           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   23985             :     }
   23986           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   23987             :   }
   23988           4 :   goto __pyx_L6_skip;
   23989           0 :   __pyx_L5_argtuple_error:;
   23990           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   23991           4 :   __pyx_L6_skip:;
   23992           4 :   goto __pyx_L4_argument_unpacking_done;
   23993           0 :   __pyx_L3_error:;
   23994             :   {
   23995           0 :     Py_ssize_t __pyx_temp;
   23996           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   23997             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   23998             :     }
   23999             :   }
   24000           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24001           0 :   __Pyx_RefNannyFinishContext();
   24002           0 :   return NULL;
   24003           4 :   __pyx_L4_argument_unpacking_done:;
   24004           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24005           4 :   __pyx_r = __pyx_pf_9_ni_label_12get_nonzero_line(__pyx_self, __pyx_v_a);
   24006             : 
   24007             :   /* function exit code */
   24008           4 :   goto __pyx_L0;
   24009           0 :   __pyx_L1_error:;
   24010           0 :   __pyx_r = NULL;
   24011           4 :   __pyx_L0:;
   24012             :   {
   24013           4 :     Py_ssize_t __pyx_temp;
   24014           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24015             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24016             :     }
   24017             :   }
   24018             :   __Pyx_RefNannyFinishContext();
   24019             :   return __pyx_r;
   24020             : }
   24021             : 
   24022           4 : static PyObject *__pyx_pf_9_ni_label_12get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24023           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24024           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   24025           4 :   PyObject *__pyx_r = NULL;
   24026             :   __Pyx_RefNannyDeclarations
   24027           4 :   PyObject *__pyx_t_1 = NULL;
   24028           4 :   int __pyx_lineno = 0;
   24029           4 :   const char *__pyx_filename = NULL;
   24030           4 :   int __pyx_clineno = 0;
   24031           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_2get_nonzero_line", 1);
   24032           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24033           4 :   __pyx_pybuffer_a.refcount = 0;
   24034           4 :   __pyx_pybuffernd_a.data = NULL;
   24035           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24036             :   {
   24037           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24038           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24039             :   }
   24040           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24041             : 
   24042             :   /* "_ni_label.pyx":94
   24043             :  * ######################################################################
   24044             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24045             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24046             :  * 
   24047             :  * def get_read_line(np.ndarray[data_t] a):
   24048             :  */
   24049           4 :   __Pyx_XDECREF(__pyx_r);
   24050           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_2__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24051           4 :   __Pyx_GOTREF(__pyx_t_1);
   24052           4 :   __pyx_r = __pyx_t_1;
   24053           4 :   __pyx_t_1 = 0;
   24054           4 :   goto __pyx_L0;
   24055             : 
   24056             :   /* "_ni_label.pyx":93
   24057             :  * # Function specializers
   24058             :  * ######################################################################
   24059             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24060             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24061             :  * 
   24062             :  */
   24063             : 
   24064             :   /* function exit code */
   24065           0 :   __pyx_L1_error:;
   24066           0 :   __Pyx_XDECREF(__pyx_t_1);
   24067           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24068           0 :     __Pyx_PyThreadState_declare
   24069           0 :     __Pyx_PyThreadState_assign
   24070           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24071           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24072           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24073           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24074           0 :   __pyx_r = NULL;
   24075           0 :   goto __pyx_L2;
   24076           4 :   __pyx_L0:;
   24077           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24078           4 :   __pyx_L2:;
   24079           4 :   __Pyx_XGIVEREF(__pyx_r);
   24080           4 :   __Pyx_RefNannyFinishContext();
   24081           4 :   return __pyx_r;
   24082             : }
   24083             : 
   24084             : /* Python wrapper */
   24085             : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_15get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24086             : static PyMethodDef __pyx_fuse_3__pyx_mdef_9_ni_label_15get_nonzero_line = {"__pyx_fuse_3get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_3__pyx_pw_9_ni_label_15get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24087           9 : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_15get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24088           9 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24089           9 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24090           9 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24091           9 :   PyObject* values[1] = {0};
   24092           9 :   int __pyx_lineno = 0;
   24093           9 :   const char *__pyx_filename = NULL;
   24094           9 :   int __pyx_clineno = 0;
   24095           9 :   PyObject *__pyx_r = 0;
   24096             :   __Pyx_RefNannyDeclarations
   24097           9 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24098             :   #if CYTHON_ASSUME_SAFE_MACROS
   24099           9 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24100             :   #else
   24101             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24102             :   #endif
   24103           9 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24104             :   {
   24105           9 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24106           9 :     if (__pyx_kwds) {
   24107           0 :       Py_ssize_t kw_args;
   24108           0 :       switch (__pyx_nargs) {
   24109           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24110           0 :         CYTHON_FALLTHROUGH;
   24111           0 :         case  0: break;
   24112           0 :         default: goto __pyx_L5_argtuple_error;
   24113             :       }
   24114           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24115           0 :       switch (__pyx_nargs) {
   24116           0 :         case  0:
   24117           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24118           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24119           0 :           kw_args--;
   24120             :         }
   24121           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24122           0 :         else goto __pyx_L5_argtuple_error;
   24123             :       }
   24124           0 :       if (unlikely(kw_args > 0)) {
   24125           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24126           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24127             :       }
   24128           9 :     } else if (unlikely(__pyx_nargs != 1)) {
   24129           0 :       goto __pyx_L5_argtuple_error;
   24130             :     } else {
   24131           9 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24132             :     }
   24133           9 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24134             :   }
   24135           9 :   goto __pyx_L6_skip;
   24136           0 :   __pyx_L5_argtuple_error:;
   24137           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24138           9 :   __pyx_L6_skip:;
   24139           9 :   goto __pyx_L4_argument_unpacking_done;
   24140           0 :   __pyx_L3_error:;
   24141             :   {
   24142           0 :     Py_ssize_t __pyx_temp;
   24143           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24144             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24145             :     }
   24146             :   }
   24147           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24148           0 :   __Pyx_RefNannyFinishContext();
   24149           0 :   return NULL;
   24150           9 :   __pyx_L4_argument_unpacking_done:;
   24151           9 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24152           9 :   __pyx_r = __pyx_pf_9_ni_label_14get_nonzero_line(__pyx_self, __pyx_v_a);
   24153             : 
   24154             :   /* function exit code */
   24155           9 :   goto __pyx_L0;
   24156           0 :   __pyx_L1_error:;
   24157           0 :   __pyx_r = NULL;
   24158           9 :   __pyx_L0:;
   24159             :   {
   24160           9 :     Py_ssize_t __pyx_temp;
   24161           9 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24162             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24163             :     }
   24164             :   }
   24165             :   __Pyx_RefNannyFinishContext();
   24166             :   return __pyx_r;
   24167             : }
   24168             : 
   24169           9 : static PyObject *__pyx_pf_9_ni_label_14get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24170           9 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24171           9 :   __Pyx_Buffer __pyx_pybuffer_a;
   24172           9 :   PyObject *__pyx_r = NULL;
   24173             :   __Pyx_RefNannyDeclarations
   24174           9 :   PyObject *__pyx_t_1 = NULL;
   24175           9 :   int __pyx_lineno = 0;
   24176           9 :   const char *__pyx_filename = NULL;
   24177           9 :   int __pyx_clineno = 0;
   24178           9 :   __Pyx_RefNannySetupContext("__pyx_fuse_3get_nonzero_line", 1);
   24179           9 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24180           9 :   __pyx_pybuffer_a.refcount = 0;
   24181           9 :   __pyx_pybuffernd_a.data = NULL;
   24182           9 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24183             :   {
   24184           9 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24185           9 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24186             :   }
   24187           9 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24188             : 
   24189             :   /* "_ni_label.pyx":94
   24190             :  * ######################################################################
   24191             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24192             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24193             :  * 
   24194             :  * def get_read_line(np.ndarray[data_t] a):
   24195             :  */
   24196           9 :   __Pyx_XDECREF(__pyx_r);
   24197           9 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_3__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24198           9 :   __Pyx_GOTREF(__pyx_t_1);
   24199           9 :   __pyx_r = __pyx_t_1;
   24200           9 :   __pyx_t_1 = 0;
   24201           9 :   goto __pyx_L0;
   24202             : 
   24203             :   /* "_ni_label.pyx":93
   24204             :  * # Function specializers
   24205             :  * ######################################################################
   24206             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24207             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24208             :  * 
   24209             :  */
   24210             : 
   24211             :   /* function exit code */
   24212           0 :   __pyx_L1_error:;
   24213           0 :   __Pyx_XDECREF(__pyx_t_1);
   24214           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24215           0 :     __Pyx_PyThreadState_declare
   24216           0 :     __Pyx_PyThreadState_assign
   24217           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24218           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24219           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24220           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24221           0 :   __pyx_r = NULL;
   24222           0 :   goto __pyx_L2;
   24223           9 :   __pyx_L0:;
   24224           9 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24225           9 :   __pyx_L2:;
   24226           9 :   __Pyx_XGIVEREF(__pyx_r);
   24227           9 :   __Pyx_RefNannyFinishContext();
   24228           9 :   return __pyx_r;
   24229             : }
   24230             : 
   24231             : /* Python wrapper */
   24232             : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_17get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24233             : static PyMethodDef __pyx_fuse_4__pyx_mdef_9_ni_label_17get_nonzero_line = {"__pyx_fuse_4get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_4__pyx_pw_9_ni_label_17get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24234          12 : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_17get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24235          12 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24236          12 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24237          12 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24238          12 :   PyObject* values[1] = {0};
   24239          12 :   int __pyx_lineno = 0;
   24240          12 :   const char *__pyx_filename = NULL;
   24241          12 :   int __pyx_clineno = 0;
   24242          12 :   PyObject *__pyx_r = 0;
   24243             :   __Pyx_RefNannyDeclarations
   24244          12 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24245             :   #if CYTHON_ASSUME_SAFE_MACROS
   24246          12 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24247             :   #else
   24248             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24249             :   #endif
   24250          12 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24251             :   {
   24252          12 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24253          12 :     if (__pyx_kwds) {
   24254           0 :       Py_ssize_t kw_args;
   24255           0 :       switch (__pyx_nargs) {
   24256           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24257           0 :         CYTHON_FALLTHROUGH;
   24258           0 :         case  0: break;
   24259           0 :         default: goto __pyx_L5_argtuple_error;
   24260             :       }
   24261           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24262           0 :       switch (__pyx_nargs) {
   24263           0 :         case  0:
   24264           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24265           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24266           0 :           kw_args--;
   24267             :         }
   24268           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24269           0 :         else goto __pyx_L5_argtuple_error;
   24270             :       }
   24271           0 :       if (unlikely(kw_args > 0)) {
   24272           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24273           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24274             :       }
   24275          12 :     } else if (unlikely(__pyx_nargs != 1)) {
   24276           0 :       goto __pyx_L5_argtuple_error;
   24277             :     } else {
   24278          12 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24279             :     }
   24280          12 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24281             :   }
   24282          12 :   goto __pyx_L6_skip;
   24283           0 :   __pyx_L5_argtuple_error:;
   24284           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24285          12 :   __pyx_L6_skip:;
   24286          12 :   goto __pyx_L4_argument_unpacking_done;
   24287           0 :   __pyx_L3_error:;
   24288             :   {
   24289           0 :     Py_ssize_t __pyx_temp;
   24290           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24291             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24292             :     }
   24293             :   }
   24294           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24295           0 :   __Pyx_RefNannyFinishContext();
   24296           0 :   return NULL;
   24297          12 :   __pyx_L4_argument_unpacking_done:;
   24298          12 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24299          12 :   __pyx_r = __pyx_pf_9_ni_label_16get_nonzero_line(__pyx_self, __pyx_v_a);
   24300             : 
   24301             :   /* function exit code */
   24302          12 :   goto __pyx_L0;
   24303           0 :   __pyx_L1_error:;
   24304           0 :   __pyx_r = NULL;
   24305          12 :   __pyx_L0:;
   24306             :   {
   24307          12 :     Py_ssize_t __pyx_temp;
   24308          12 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24309             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24310             :     }
   24311             :   }
   24312             :   __Pyx_RefNannyFinishContext();
   24313             :   return __pyx_r;
   24314             : }
   24315             : 
   24316          12 : static PyObject *__pyx_pf_9_ni_label_16get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24317          12 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24318          12 :   __Pyx_Buffer __pyx_pybuffer_a;
   24319          12 :   PyObject *__pyx_r = NULL;
   24320             :   __Pyx_RefNannyDeclarations
   24321          12 :   PyObject *__pyx_t_1 = NULL;
   24322          12 :   int __pyx_lineno = 0;
   24323          12 :   const char *__pyx_filename = NULL;
   24324          12 :   int __pyx_clineno = 0;
   24325          12 :   __Pyx_RefNannySetupContext("__pyx_fuse_4get_nonzero_line", 1);
   24326          12 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24327          12 :   __pyx_pybuffer_a.refcount = 0;
   24328          12 :   __pyx_pybuffernd_a.data = NULL;
   24329          12 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24330             :   {
   24331          12 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24332          12 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24333             :   }
   24334          12 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24335             : 
   24336             :   /* "_ni_label.pyx":94
   24337             :  * ######################################################################
   24338             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24339             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24340             :  * 
   24341             :  * def get_read_line(np.ndarray[data_t] a):
   24342             :  */
   24343          12 :   __Pyx_XDECREF(__pyx_r);
   24344          12 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_4__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24345          12 :   __Pyx_GOTREF(__pyx_t_1);
   24346          12 :   __pyx_r = __pyx_t_1;
   24347          12 :   __pyx_t_1 = 0;
   24348          12 :   goto __pyx_L0;
   24349             : 
   24350             :   /* "_ni_label.pyx":93
   24351             :  * # Function specializers
   24352             :  * ######################################################################
   24353             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24354             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24355             :  * 
   24356             :  */
   24357             : 
   24358             :   /* function exit code */
   24359           0 :   __pyx_L1_error:;
   24360           0 :   __Pyx_XDECREF(__pyx_t_1);
   24361           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24362           0 :     __Pyx_PyThreadState_declare
   24363           0 :     __Pyx_PyThreadState_assign
   24364           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24365           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24366           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24367           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24368           0 :   __pyx_r = NULL;
   24369           0 :   goto __pyx_L2;
   24370          12 :   __pyx_L0:;
   24371          12 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24372          12 :   __pyx_L2:;
   24373          12 :   __Pyx_XGIVEREF(__pyx_r);
   24374          12 :   __Pyx_RefNannyFinishContext();
   24375          12 :   return __pyx_r;
   24376             : }
   24377             : 
   24378             : /* Python wrapper */
   24379             : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_19get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24380             : static PyMethodDef __pyx_fuse_5__pyx_mdef_9_ni_label_19get_nonzero_line = {"__pyx_fuse_5get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_5__pyx_pw_9_ni_label_19get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24381           4 : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_19get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24382           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24383           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24384           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24385           4 :   PyObject* values[1] = {0};
   24386           4 :   int __pyx_lineno = 0;
   24387           4 :   const char *__pyx_filename = NULL;
   24388           4 :   int __pyx_clineno = 0;
   24389           4 :   PyObject *__pyx_r = 0;
   24390             :   __Pyx_RefNannyDeclarations
   24391           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24392             :   #if CYTHON_ASSUME_SAFE_MACROS
   24393           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24394             :   #else
   24395             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24396             :   #endif
   24397           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24398             :   {
   24399           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24400           4 :     if (__pyx_kwds) {
   24401           0 :       Py_ssize_t kw_args;
   24402           0 :       switch (__pyx_nargs) {
   24403           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24404           0 :         CYTHON_FALLTHROUGH;
   24405           0 :         case  0: break;
   24406           0 :         default: goto __pyx_L5_argtuple_error;
   24407             :       }
   24408           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24409           0 :       switch (__pyx_nargs) {
   24410           0 :         case  0:
   24411           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24412           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24413           0 :           kw_args--;
   24414             :         }
   24415           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24416           0 :         else goto __pyx_L5_argtuple_error;
   24417             :       }
   24418           0 :       if (unlikely(kw_args > 0)) {
   24419           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24420           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24421             :       }
   24422           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   24423           0 :       goto __pyx_L5_argtuple_error;
   24424             :     } else {
   24425           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24426             :     }
   24427           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24428             :   }
   24429           4 :   goto __pyx_L6_skip;
   24430           0 :   __pyx_L5_argtuple_error:;
   24431           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24432           4 :   __pyx_L6_skip:;
   24433           4 :   goto __pyx_L4_argument_unpacking_done;
   24434           0 :   __pyx_L3_error:;
   24435             :   {
   24436           0 :     Py_ssize_t __pyx_temp;
   24437           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24438             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24439             :     }
   24440             :   }
   24441           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24442           0 :   __Pyx_RefNannyFinishContext();
   24443           0 :   return NULL;
   24444           4 :   __pyx_L4_argument_unpacking_done:;
   24445           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24446           4 :   __pyx_r = __pyx_pf_9_ni_label_18get_nonzero_line(__pyx_self, __pyx_v_a);
   24447             : 
   24448             :   /* function exit code */
   24449           4 :   goto __pyx_L0;
   24450           0 :   __pyx_L1_error:;
   24451           0 :   __pyx_r = NULL;
   24452           4 :   __pyx_L0:;
   24453             :   {
   24454           4 :     Py_ssize_t __pyx_temp;
   24455           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24456             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24457             :     }
   24458             :   }
   24459             :   __Pyx_RefNannyFinishContext();
   24460             :   return __pyx_r;
   24461             : }
   24462             : 
   24463           4 : static PyObject *__pyx_pf_9_ni_label_18get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24464           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24465           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   24466           4 :   PyObject *__pyx_r = NULL;
   24467             :   __Pyx_RefNannyDeclarations
   24468           4 :   PyObject *__pyx_t_1 = NULL;
   24469           4 :   int __pyx_lineno = 0;
   24470           4 :   const char *__pyx_filename = NULL;
   24471           4 :   int __pyx_clineno = 0;
   24472           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_5get_nonzero_line", 1);
   24473           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24474           4 :   __pyx_pybuffer_a.refcount = 0;
   24475           4 :   __pyx_pybuffernd_a.data = NULL;
   24476           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24477             :   {
   24478           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24479           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24480             :   }
   24481           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24482             : 
   24483             :   /* "_ni_label.pyx":94
   24484             :  * ######################################################################
   24485             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24486             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24487             :  * 
   24488             :  * def get_read_line(np.ndarray[data_t] a):
   24489             :  */
   24490           4 :   __Pyx_XDECREF(__pyx_r);
   24491           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_5__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24492           4 :   __Pyx_GOTREF(__pyx_t_1);
   24493           4 :   __pyx_r = __pyx_t_1;
   24494           4 :   __pyx_t_1 = 0;
   24495           4 :   goto __pyx_L0;
   24496             : 
   24497             :   /* "_ni_label.pyx":93
   24498             :  * # Function specializers
   24499             :  * ######################################################################
   24500             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24501             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24502             :  * 
   24503             :  */
   24504             : 
   24505             :   /* function exit code */
   24506           0 :   __pyx_L1_error:;
   24507           0 :   __Pyx_XDECREF(__pyx_t_1);
   24508           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24509           0 :     __Pyx_PyThreadState_declare
   24510           0 :     __Pyx_PyThreadState_assign
   24511           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24512           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24513           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24514           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24515           0 :   __pyx_r = NULL;
   24516           0 :   goto __pyx_L2;
   24517           4 :   __pyx_L0:;
   24518           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24519           4 :   __pyx_L2:;
   24520           4 :   __Pyx_XGIVEREF(__pyx_r);
   24521           4 :   __Pyx_RefNannyFinishContext();
   24522           4 :   return __pyx_r;
   24523             : }
   24524             : 
   24525             : /* Python wrapper */
   24526             : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_21get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24527             : static PyMethodDef __pyx_fuse_6__pyx_mdef_9_ni_label_21get_nonzero_line = {"__pyx_fuse_6get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_6__pyx_pw_9_ni_label_21get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24528           4 : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_21get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24529           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24530           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24531           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24532           4 :   PyObject* values[1] = {0};
   24533           4 :   int __pyx_lineno = 0;
   24534           4 :   const char *__pyx_filename = NULL;
   24535           4 :   int __pyx_clineno = 0;
   24536           4 :   PyObject *__pyx_r = 0;
   24537             :   __Pyx_RefNannyDeclarations
   24538           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24539             :   #if CYTHON_ASSUME_SAFE_MACROS
   24540           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24541             :   #else
   24542             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24543             :   #endif
   24544           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24545             :   {
   24546           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24547           4 :     if (__pyx_kwds) {
   24548           0 :       Py_ssize_t kw_args;
   24549           0 :       switch (__pyx_nargs) {
   24550           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24551           0 :         CYTHON_FALLTHROUGH;
   24552           0 :         case  0: break;
   24553           0 :         default: goto __pyx_L5_argtuple_error;
   24554             :       }
   24555           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24556           0 :       switch (__pyx_nargs) {
   24557           0 :         case  0:
   24558           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24559           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24560           0 :           kw_args--;
   24561             :         }
   24562           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24563           0 :         else goto __pyx_L5_argtuple_error;
   24564             :       }
   24565           0 :       if (unlikely(kw_args > 0)) {
   24566           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24567           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24568             :       }
   24569           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   24570           0 :       goto __pyx_L5_argtuple_error;
   24571             :     } else {
   24572           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24573             :     }
   24574           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24575             :   }
   24576           4 :   goto __pyx_L6_skip;
   24577           0 :   __pyx_L5_argtuple_error:;
   24578           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24579           4 :   __pyx_L6_skip:;
   24580           4 :   goto __pyx_L4_argument_unpacking_done;
   24581           0 :   __pyx_L3_error:;
   24582             :   {
   24583           0 :     Py_ssize_t __pyx_temp;
   24584           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24585             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24586             :     }
   24587             :   }
   24588           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24589           0 :   __Pyx_RefNannyFinishContext();
   24590           0 :   return NULL;
   24591           4 :   __pyx_L4_argument_unpacking_done:;
   24592           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24593           4 :   __pyx_r = __pyx_pf_9_ni_label_20get_nonzero_line(__pyx_self, __pyx_v_a);
   24594             : 
   24595             :   /* function exit code */
   24596           4 :   goto __pyx_L0;
   24597           0 :   __pyx_L1_error:;
   24598           0 :   __pyx_r = NULL;
   24599           4 :   __pyx_L0:;
   24600             :   {
   24601           4 :     Py_ssize_t __pyx_temp;
   24602           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24603             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24604             :     }
   24605             :   }
   24606             :   __Pyx_RefNannyFinishContext();
   24607             :   return __pyx_r;
   24608             : }
   24609             : 
   24610           4 : static PyObject *__pyx_pf_9_ni_label_20get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24611           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24612           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   24613           4 :   PyObject *__pyx_r = NULL;
   24614             :   __Pyx_RefNannyDeclarations
   24615           4 :   PyObject *__pyx_t_1 = NULL;
   24616           4 :   int __pyx_lineno = 0;
   24617           4 :   const char *__pyx_filename = NULL;
   24618           4 :   int __pyx_clineno = 0;
   24619           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_6get_nonzero_line", 1);
   24620           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24621           4 :   __pyx_pybuffer_a.refcount = 0;
   24622           4 :   __pyx_pybuffernd_a.data = NULL;
   24623           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24624             :   {
   24625           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24626           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24627             :   }
   24628           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24629             : 
   24630             :   /* "_ni_label.pyx":94
   24631             :  * ######################################################################
   24632             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24633             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24634             :  * 
   24635             :  * def get_read_line(np.ndarray[data_t] a):
   24636             :  */
   24637           4 :   __Pyx_XDECREF(__pyx_r);
   24638           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_6__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24639           4 :   __Pyx_GOTREF(__pyx_t_1);
   24640           4 :   __pyx_r = __pyx_t_1;
   24641           4 :   __pyx_t_1 = 0;
   24642           4 :   goto __pyx_L0;
   24643             : 
   24644             :   /* "_ni_label.pyx":93
   24645             :  * # Function specializers
   24646             :  * ######################################################################
   24647             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24648             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24649             :  * 
   24650             :  */
   24651             : 
   24652             :   /* function exit code */
   24653           0 :   __pyx_L1_error:;
   24654           0 :   __Pyx_XDECREF(__pyx_t_1);
   24655           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24656           0 :     __Pyx_PyThreadState_declare
   24657           0 :     __Pyx_PyThreadState_assign
   24658           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24659           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24660           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24661           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24662           0 :   __pyx_r = NULL;
   24663           0 :   goto __pyx_L2;
   24664           4 :   __pyx_L0:;
   24665           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24666           4 :   __pyx_L2:;
   24667           4 :   __Pyx_XGIVEREF(__pyx_r);
   24668           4 :   __Pyx_RefNannyFinishContext();
   24669           4 :   return __pyx_r;
   24670             : }
   24671             : 
   24672             : /* Python wrapper */
   24673             : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_23get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24674             : static PyMethodDef __pyx_fuse_7__pyx_mdef_9_ni_label_23get_nonzero_line = {"__pyx_fuse_7get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_7__pyx_pw_9_ni_label_23get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24675           4 : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_23get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24676           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24677           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24678           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24679           4 :   PyObject* values[1] = {0};
   24680           4 :   int __pyx_lineno = 0;
   24681           4 :   const char *__pyx_filename = NULL;
   24682           4 :   int __pyx_clineno = 0;
   24683           4 :   PyObject *__pyx_r = 0;
   24684             :   __Pyx_RefNannyDeclarations
   24685           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24686             :   #if CYTHON_ASSUME_SAFE_MACROS
   24687           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24688             :   #else
   24689             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24690             :   #endif
   24691           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24692             :   {
   24693           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24694           4 :     if (__pyx_kwds) {
   24695           0 :       Py_ssize_t kw_args;
   24696           0 :       switch (__pyx_nargs) {
   24697           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24698           0 :         CYTHON_FALLTHROUGH;
   24699           0 :         case  0: break;
   24700           0 :         default: goto __pyx_L5_argtuple_error;
   24701             :       }
   24702           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24703           0 :       switch (__pyx_nargs) {
   24704           0 :         case  0:
   24705           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24706           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24707           0 :           kw_args--;
   24708             :         }
   24709           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24710           0 :         else goto __pyx_L5_argtuple_error;
   24711             :       }
   24712           0 :       if (unlikely(kw_args > 0)) {
   24713           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24714           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24715             :       }
   24716           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   24717           0 :       goto __pyx_L5_argtuple_error;
   24718             :     } else {
   24719           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24720             :     }
   24721           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24722             :   }
   24723           4 :   goto __pyx_L6_skip;
   24724           0 :   __pyx_L5_argtuple_error:;
   24725           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24726           4 :   __pyx_L6_skip:;
   24727           4 :   goto __pyx_L4_argument_unpacking_done;
   24728           0 :   __pyx_L3_error:;
   24729             :   {
   24730           0 :     Py_ssize_t __pyx_temp;
   24731           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24732             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24733             :     }
   24734             :   }
   24735           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24736           0 :   __Pyx_RefNannyFinishContext();
   24737           0 :   return NULL;
   24738           4 :   __pyx_L4_argument_unpacking_done:;
   24739           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24740           4 :   __pyx_r = __pyx_pf_9_ni_label_22get_nonzero_line(__pyx_self, __pyx_v_a);
   24741             : 
   24742             :   /* function exit code */
   24743           4 :   goto __pyx_L0;
   24744           0 :   __pyx_L1_error:;
   24745           0 :   __pyx_r = NULL;
   24746           4 :   __pyx_L0:;
   24747             :   {
   24748           4 :     Py_ssize_t __pyx_temp;
   24749           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24750             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24751             :     }
   24752             :   }
   24753             :   __Pyx_RefNannyFinishContext();
   24754             :   return __pyx_r;
   24755             : }
   24756             : 
   24757           4 : static PyObject *__pyx_pf_9_ni_label_22get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24758           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24759           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   24760           4 :   PyObject *__pyx_r = NULL;
   24761             :   __Pyx_RefNannyDeclarations
   24762           4 :   PyObject *__pyx_t_1 = NULL;
   24763           4 :   int __pyx_lineno = 0;
   24764           4 :   const char *__pyx_filename = NULL;
   24765           4 :   int __pyx_clineno = 0;
   24766           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_7get_nonzero_line", 1);
   24767           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24768           4 :   __pyx_pybuffer_a.refcount = 0;
   24769           4 :   __pyx_pybuffernd_a.data = NULL;
   24770           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24771             :   {
   24772           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24773           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24774             :   }
   24775           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24776             : 
   24777             :   /* "_ni_label.pyx":94
   24778             :  * ######################################################################
   24779             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24780             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24781             :  * 
   24782             :  * def get_read_line(np.ndarray[data_t] a):
   24783             :  */
   24784           4 :   __Pyx_XDECREF(__pyx_r);
   24785           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_7__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24786           4 :   __Pyx_GOTREF(__pyx_t_1);
   24787           4 :   __pyx_r = __pyx_t_1;
   24788           4 :   __pyx_t_1 = 0;
   24789           4 :   goto __pyx_L0;
   24790             : 
   24791             :   /* "_ni_label.pyx":93
   24792             :  * # Function specializers
   24793             :  * ######################################################################
   24794             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24795             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24796             :  * 
   24797             :  */
   24798             : 
   24799             :   /* function exit code */
   24800           0 :   __pyx_L1_error:;
   24801           0 :   __Pyx_XDECREF(__pyx_t_1);
   24802           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24803           0 :     __Pyx_PyThreadState_declare
   24804           0 :     __Pyx_PyThreadState_assign
   24805           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24806           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24807           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24808           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24809           0 :   __pyx_r = NULL;
   24810           0 :   goto __pyx_L2;
   24811           4 :   __pyx_L0:;
   24812           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24813           4 :   __pyx_L2:;
   24814           4 :   __Pyx_XGIVEREF(__pyx_r);
   24815           4 :   __Pyx_RefNannyFinishContext();
   24816           4 :   return __pyx_r;
   24817             : }
   24818             : 
   24819             : /* Python wrapper */
   24820             : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_25get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24821             : static PyMethodDef __pyx_fuse_8__pyx_mdef_9_ni_label_25get_nonzero_line = {"__pyx_fuse_8get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_8__pyx_pw_9_ni_label_25get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24822           4 : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_25get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24823           4 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24824           4 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24825           4 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24826           4 :   PyObject* values[1] = {0};
   24827           4 :   int __pyx_lineno = 0;
   24828           4 :   const char *__pyx_filename = NULL;
   24829           4 :   int __pyx_clineno = 0;
   24830           4 :   PyObject *__pyx_r = 0;
   24831             :   __Pyx_RefNannyDeclarations
   24832           4 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24833             :   #if CYTHON_ASSUME_SAFE_MACROS
   24834           4 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24835             :   #else
   24836             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24837             :   #endif
   24838           4 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24839             :   {
   24840           4 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24841           4 :     if (__pyx_kwds) {
   24842           0 :       Py_ssize_t kw_args;
   24843           0 :       switch (__pyx_nargs) {
   24844           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24845           0 :         CYTHON_FALLTHROUGH;
   24846           0 :         case  0: break;
   24847           0 :         default: goto __pyx_L5_argtuple_error;
   24848             :       }
   24849           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24850           0 :       switch (__pyx_nargs) {
   24851           0 :         case  0:
   24852           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   24853           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   24854           0 :           kw_args--;
   24855             :         }
   24856           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   24857           0 :         else goto __pyx_L5_argtuple_error;
   24858             :       }
   24859           0 :       if (unlikely(kw_args > 0)) {
   24860           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   24861           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   24862             :       }
   24863           4 :     } else if (unlikely(__pyx_nargs != 1)) {
   24864           0 :       goto __pyx_L5_argtuple_error;
   24865             :     } else {
   24866           4 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24867             :     }
   24868           4 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   24869             :   }
   24870           4 :   goto __pyx_L6_skip;
   24871           0 :   __pyx_L5_argtuple_error:;
   24872           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   24873           4 :   __pyx_L6_skip:;
   24874           4 :   goto __pyx_L4_argument_unpacking_done;
   24875           0 :   __pyx_L3_error:;
   24876             :   {
   24877           0 :     Py_ssize_t __pyx_temp;
   24878           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24879             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24880             :     }
   24881             :   }
   24882           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24883           0 :   __Pyx_RefNannyFinishContext();
   24884           0 :   return NULL;
   24885           4 :   __pyx_L4_argument_unpacking_done:;
   24886           4 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   24887           4 :   __pyx_r = __pyx_pf_9_ni_label_24get_nonzero_line(__pyx_self, __pyx_v_a);
   24888             : 
   24889             :   /* function exit code */
   24890           4 :   goto __pyx_L0;
   24891           0 :   __pyx_L1_error:;
   24892           0 :   __pyx_r = NULL;
   24893           4 :   __pyx_L0:;
   24894             :   {
   24895           4 :     Py_ssize_t __pyx_temp;
   24896           4 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   24897             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   24898             :     }
   24899             :   }
   24900             :   __Pyx_RefNannyFinishContext();
   24901             :   return __pyx_r;
   24902             : }
   24903             : 
   24904           4 : static PyObject *__pyx_pf_9_ni_label_24get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   24905           4 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   24906           4 :   __Pyx_Buffer __pyx_pybuffer_a;
   24907           4 :   PyObject *__pyx_r = NULL;
   24908             :   __Pyx_RefNannyDeclarations
   24909           4 :   PyObject *__pyx_t_1 = NULL;
   24910           4 :   int __pyx_lineno = 0;
   24911           4 :   const char *__pyx_filename = NULL;
   24912           4 :   int __pyx_clineno = 0;
   24913           4 :   __Pyx_RefNannySetupContext("__pyx_fuse_8get_nonzero_line", 1);
   24914           4 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   24915           4 :   __pyx_pybuffer_a.refcount = 0;
   24916           4 :   __pyx_pybuffernd_a.data = NULL;
   24917           4 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   24918             :   {
   24919           4 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   24920           4 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   24921             :   }
   24922           4 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   24923             : 
   24924             :   /* "_ni_label.pyx":94
   24925             :  * ######################################################################
   24926             :  * def get_nonzero_line(np.ndarray[data_t] a):
   24927             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   24928             :  * 
   24929             :  * def get_read_line(np.ndarray[data_t] a):
   24930             :  */
   24931           4 :   __Pyx_XDECREF(__pyx_r);
   24932           4 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_8__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   24933           4 :   __Pyx_GOTREF(__pyx_t_1);
   24934           4 :   __pyx_r = __pyx_t_1;
   24935           4 :   __pyx_t_1 = 0;
   24936           4 :   goto __pyx_L0;
   24937             : 
   24938             :   /* "_ni_label.pyx":93
   24939             :  * # Function specializers
   24940             :  * ######################################################################
   24941             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   24942             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   24943             :  * 
   24944             :  */
   24945             : 
   24946             :   /* function exit code */
   24947           0 :   __pyx_L1_error:;
   24948           0 :   __Pyx_XDECREF(__pyx_t_1);
   24949           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   24950           0 :     __Pyx_PyThreadState_declare
   24951           0 :     __Pyx_PyThreadState_assign
   24952           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   24953           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24954           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   24955           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   24956           0 :   __pyx_r = NULL;
   24957           0 :   goto __pyx_L2;
   24958           4 :   __pyx_L0:;
   24959           4 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   24960           4 :   __pyx_L2:;
   24961           4 :   __Pyx_XGIVEREF(__pyx_r);
   24962           4 :   __Pyx_RefNannyFinishContext();
   24963           4 :   return __pyx_r;
   24964             : }
   24965             : 
   24966             : /* Python wrapper */
   24967             : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_27get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   24968             : static PyMethodDef __pyx_fuse_9__pyx_mdef_9_ni_label_27get_nonzero_line = {"__pyx_fuse_9get_nonzero_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_9__pyx_pw_9_ni_label_27get_nonzero_line, METH_VARARGS|METH_KEYWORDS, 0};
   24969          70 : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_27get_nonzero_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   24970          70 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   24971          70 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   24972          70 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   24973          70 :   PyObject* values[1] = {0};
   24974          70 :   int __pyx_lineno = 0;
   24975          70 :   const char *__pyx_filename = NULL;
   24976          70 :   int __pyx_clineno = 0;
   24977          70 :   PyObject *__pyx_r = 0;
   24978             :   __Pyx_RefNannyDeclarations
   24979          70 :   __Pyx_RefNannySetupContext("get_nonzero_line (wrapper)", 0);
   24980             :   #if CYTHON_ASSUME_SAFE_MACROS
   24981          70 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   24982             :   #else
   24983             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   24984             :   #endif
   24985          70 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   24986             :   {
   24987          70 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   24988          70 :     if (__pyx_kwds) {
   24989           0 :       Py_ssize_t kw_args;
   24990           0 :       switch (__pyx_nargs) {
   24991           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   24992           0 :         CYTHON_FALLTHROUGH;
   24993           0 :         case  0: break;
   24994           0 :         default: goto __pyx_L5_argtuple_error;
   24995             :       }
   24996           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   24997           0 :       switch (__pyx_nargs) {
   24998           0 :         case  0:
   24999           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   25000           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   25001           0 :           kw_args--;
   25002             :         }
   25003           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 93, __pyx_L3_error)
   25004           0 :         else goto __pyx_L5_argtuple_error;
   25005             :       }
   25006           0 :       if (unlikely(kw_args > 0)) {
   25007           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   25008           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_nonzero_line") < 0)) __PYX_ERR(0, 93, __pyx_L3_error)
   25009             :       }
   25010          70 :     } else if (unlikely(__pyx_nargs != 1)) {
   25011           0 :       goto __pyx_L5_argtuple_error;
   25012             :     } else {
   25013          70 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   25014             :     }
   25015          70 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   25016             :   }
   25017          70 :   goto __pyx_L6_skip;
   25018           0 :   __pyx_L5_argtuple_error:;
   25019           0 :   __Pyx_RaiseArgtupleInvalid("get_nonzero_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 93, __pyx_L3_error)
   25020          70 :   __pyx_L6_skip:;
   25021          70 :   goto __pyx_L4_argument_unpacking_done;
   25022           0 :   __pyx_L3_error:;
   25023             :   {
   25024           0 :     Py_ssize_t __pyx_temp;
   25025           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   25026             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   25027             :     }
   25028             :   }
   25029           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   25030           0 :   __Pyx_RefNannyFinishContext();
   25031           0 :   return NULL;
   25032          70 :   __pyx_L4_argument_unpacking_done:;
   25033          70 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 93, __pyx_L1_error)
   25034          70 :   __pyx_r = __pyx_pf_9_ni_label_26get_nonzero_line(__pyx_self, __pyx_v_a);
   25035             : 
   25036             :   /* function exit code */
   25037          70 :   goto __pyx_L0;
   25038           0 :   __pyx_L1_error:;
   25039           0 :   __pyx_r = NULL;
   25040          70 :   __pyx_L0:;
   25041             :   {
   25042          70 :     Py_ssize_t __pyx_temp;
   25043          70 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   25044             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   25045             :     }
   25046             :   }
   25047             :   __Pyx_RefNannyFinishContext();
   25048             :   return __pyx_r;
   25049             : }
   25050             : 
   25051          70 : static PyObject *__pyx_pf_9_ni_label_26get_nonzero_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   25052          70 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   25053          70 :   __Pyx_Buffer __pyx_pybuffer_a;
   25054          70 :   PyObject *__pyx_r = NULL;
   25055             :   __Pyx_RefNannyDeclarations
   25056          70 :   PyObject *__pyx_t_1 = NULL;
   25057          70 :   int __pyx_lineno = 0;
   25058          70 :   const char *__pyx_filename = NULL;
   25059          70 :   int __pyx_clineno = 0;
   25060          70 :   __Pyx_RefNannySetupContext("__pyx_fuse_9get_nonzero_line", 1);
   25061          70 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   25062          70 :   __pyx_pybuffer_a.refcount = 0;
   25063          70 :   __pyx_pybuffernd_a.data = NULL;
   25064          70 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   25065             :   {
   25066          70 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   25067          70 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 93, __pyx_L1_error)
   25068             :   }
   25069          70 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   25070             : 
   25071             :   /* "_ni_label.pyx":94
   25072             :  * ######################################################################
   25073             :  * def get_nonzero_line(np.ndarray[data_t] a):
   25074             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]             # <<<<<<<<<<<<<<
   25075             :  * 
   25076             :  * def get_read_line(np.ndarray[data_t] a):
   25077             :  */
   25078          70 :   __Pyx_XDECREF(__pyx_r);
   25079          70 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_9__pyx_f_9_ni_label_fused_nonzero_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 94, __pyx_L1_error)
   25080          70 :   __Pyx_GOTREF(__pyx_t_1);
   25081          70 :   __pyx_r = __pyx_t_1;
   25082          70 :   __pyx_t_1 = 0;
   25083          70 :   goto __pyx_L0;
   25084             : 
   25085             :   /* "_ni_label.pyx":93
   25086             :  * # Function specializers
   25087             :  * ######################################################################
   25088             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   25089             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   25090             :  * 
   25091             :  */
   25092             : 
   25093             :   /* function exit code */
   25094           0 :   __pyx_L1_error:;
   25095           0 :   __Pyx_XDECREF(__pyx_t_1);
   25096           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   25097           0 :     __Pyx_PyThreadState_declare
   25098           0 :     __Pyx_PyThreadState_assign
   25099           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   25100           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   25101           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   25102           0 :   __Pyx_AddTraceback("_ni_label.get_nonzero_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   25103           0 :   __pyx_r = NULL;
   25104           0 :   goto __pyx_L2;
   25105          70 :   __pyx_L0:;
   25106          70 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   25107          70 :   __pyx_L2:;
   25108          70 :   __Pyx_XGIVEREF(__pyx_r);
   25109          70 :   __Pyx_RefNannyFinishContext();
   25110          70 :   return __pyx_r;
   25111             : }
   25112             : 
   25113             : /* "_ni_label.pyx":96
   25114             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   25115             :  * 
   25116             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   25117             :  *     return <Py_intptr_t> fused_read_line[data_t]
   25118             :  * 
   25119             :  */
   25120             : 
   25121             : /* Python wrapper */
   25122             : static PyObject *__pyx_pw_9_ni_label_3get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   25123             : static PyMethodDef __pyx_mdef_9_ni_label_3get_read_line = {"get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_9_ni_label_3get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   25124         119 : static PyObject *__pyx_pw_9_ni_label_3get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   25125         119 :   PyObject *__pyx_v_signatures = 0;
   25126         119 :   PyObject *__pyx_v_args = 0;
   25127         119 :   PyObject *__pyx_v_kwargs = 0;
   25128         119 :   CYTHON_UNUSED PyObject *__pyx_v_defaults = 0;
   25129         119 :   PyObject *__pyx_v__fused_sigindex = 0;
   25130         119 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   25131         119 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   25132         119 :   PyObject* values[5] = {0,0,0,0,0};
   25133         119 :   int __pyx_lineno = 0;
   25134         119 :   const char *__pyx_filename = NULL;
   25135         119 :   int __pyx_clineno = 0;
   25136         119 :   PyObject *__pyx_r = 0;
   25137             :   __Pyx_RefNannyDeclarations
   25138         119 :   __Pyx_RefNannySetupContext("__pyx_fused_cpdef (wrapper)", 0);
   25139             :   #if CYTHON_ASSUME_SAFE_MACROS
   25140         119 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   25141             :   #else
   25142             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   25143             :   #endif
   25144         119 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   25145             :   {
   25146         119 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_signatures,&__pyx_n_s_args,&__pyx_n_s_kwargs,&__pyx_n_s_defaults,&__pyx_n_s_fused_sigindex,0};
   25147         119 :     __pyx_defaults1 *__pyx_dynamic_args = __Pyx_CyFunction_Defaults(__pyx_defaults1, __pyx_self);
   25148         119 :     values[4] = __Pyx_Arg_NewRef_VARARGS(__pyx_dynamic_args->__pyx_arg__fused_sigindex);
   25149         119 :     if (__pyx_kwds) {
   25150           0 :       Py_ssize_t kw_args;
   25151           0 :       switch (__pyx_nargs) {
   25152           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   25153           0 :         CYTHON_FALLTHROUGH;
   25154           0 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   25155           0 :         CYTHON_FALLTHROUGH;
   25156           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   25157           0 :         CYTHON_FALLTHROUGH;
   25158           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   25159           0 :         CYTHON_FALLTHROUGH;
   25160           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   25161           0 :         CYTHON_FALLTHROUGH;
   25162           0 :         case  0: break;
   25163           0 :         default: goto __pyx_L5_argtuple_error;
   25164             :       }
   25165           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   25166           0 :       switch (__pyx_nargs) {
   25167           0 :         case  0:
   25168           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_signatures)) != 0)) {
   25169           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   25170           0 :           kw_args--;
   25171             :         }
   25172           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   25173           0 :         else goto __pyx_L5_argtuple_error;
   25174           0 :         CYTHON_FALLTHROUGH;
   25175             :         case  1:
   25176           0 :         if (likely((values[1] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_args)) != 0)) {
   25177           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[1]);
   25178           0 :           kw_args--;
   25179             :         }
   25180           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   25181             :         else {
   25182           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 1); __PYX_ERR(0, 96, __pyx_L3_error)
   25183             :         }
   25184           0 :         CYTHON_FALLTHROUGH;
   25185             :         case  2:
   25186           0 :         if (likely((values[2] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_kwargs)) != 0)) {
   25187           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[2]);
   25188           0 :           kw_args--;
   25189             :         }
   25190           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   25191             :         else {
   25192           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 2); __PYX_ERR(0, 96, __pyx_L3_error)
   25193             :         }
   25194           0 :         CYTHON_FALLTHROUGH;
   25195             :         case  3:
   25196           0 :         if (likely((values[3] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_defaults)) != 0)) {
   25197           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[3]);
   25198           0 :           kw_args--;
   25199             :         }
   25200           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   25201             :         else {
   25202           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 3); __PYX_ERR(0, 96, __pyx_L3_error)
   25203             :         }
   25204           0 :         CYTHON_FALLTHROUGH;
   25205             :         case  4:
   25206           0 :         if (kw_args > 0) {
   25207           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_fused_sigindex);
   25208           0 :           if (value) { values[4] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
   25209           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   25210             :         }
   25211             :       }
   25212           0 :       if (unlikely(kw_args > 0)) {
   25213           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   25214           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__pyx_fused_cpdef") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   25215             :       }
   25216             :     } else {
   25217         119 :       switch (__pyx_nargs) {
   25218           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   25219         119 :         CYTHON_FALLTHROUGH;
   25220         119 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   25221         119 :         values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   25222         119 :         values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   25223         119 :         values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   25224         119 :         break;
   25225           0 :         default: goto __pyx_L5_argtuple_error;
   25226             :       }
   25227             :     }
   25228         119 :     __pyx_v_signatures = values[0];
   25229         119 :     __pyx_v_args = values[1];
   25230         119 :     __pyx_v_kwargs = values[2];
   25231         119 :     __pyx_v_defaults = values[3];
   25232         119 :     __pyx_v__fused_sigindex = values[4];
   25233             :   }
   25234         119 :   goto __pyx_L6_skip;
   25235           0 :   __pyx_L5_argtuple_error:;
   25236           0 :   __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   25237         119 :   __pyx_L6_skip:;
   25238         119 :   goto __pyx_L4_argument_unpacking_done;
   25239           0 :   __pyx_L3_error:;
   25240             :   {
   25241           0 :     Py_ssize_t __pyx_temp;
   25242           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   25243             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   25244             :     }
   25245             :   }
   25246           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   25247           0 :   __Pyx_RefNannyFinishContext();
   25248           0 :   return NULL;
   25249         119 :   __pyx_L4_argument_unpacking_done:;
   25250         119 :   __pyx_r = __pyx_pf_9_ni_label_2get_read_line(__pyx_self, __pyx_v_signatures, __pyx_v_args, __pyx_v_kwargs, __pyx_v_defaults, __pyx_v__fused_sigindex);
   25251             : 
   25252             :   /* function exit code */
   25253             :   {
   25254         119 :     Py_ssize_t __pyx_temp;
   25255         119 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   25256             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   25257             :     }
   25258             :   }
   25259             :   __Pyx_RefNannyFinishContext();
   25260             :   return __pyx_r;
   25261             : }
   25262             : 
   25263         119 : static PyObject *__pyx_pf_9_ni_label_2get_read_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex) {
   25264         119 :   PyObject *__pyx_v_search_list = 0;
   25265         119 :   PyObject *__pyx_v_sigindex_node = 0;
   25266         119 :   PyObject *__pyx_v_dest_sig = NULL;
   25267         119 :   PyTypeObject *__pyx_v_ndarray = 0;
   25268         119 :   PyObject *__pyx_v_arg_as_memoryview = 0;
   25269         119 :   __Pyx_memviewslice __pyx_v_memslice;
   25270         119 :   Py_ssize_t __pyx_v_itemsize;
   25271         119 :   int __pyx_v_dtype_signed;
   25272         119 :   Py_UCS4 __pyx_v_kind;
   25273         119 :   int __pyx_v___pyx_fused_dtype_int8__t_is_signed;
   25274         119 :   int __pyx_v___pyx_fused_dtype_int16__t_is_signed;
   25275         119 :   int __pyx_v___pyx_fused_dtype_int32__t_is_signed;
   25276         119 :   int __pyx_v___pyx_fused_dtype_int64__t_is_signed;
   25277         119 :   int __pyx_v___pyx_fused_dtype_uint8__t_is_signed;
   25278         119 :   int __pyx_v___pyx_fused_dtype_uint16__t_is_signed;
   25279         119 :   int __pyx_v___pyx_fused_dtype_uint32__t_is_signed;
   25280         119 :   int __pyx_v___pyx_fused_dtype_uint64__t_is_signed;
   25281         119 :   PyObject *__pyx_v_arg = NULL;
   25282         119 :   PyObject *__pyx_v_dtype = NULL;
   25283         119 :   PyObject *__pyx_v_arg_base = NULL;
   25284         119 :   PyObject *__pyx_v_sig = NULL;
   25285         119 :   PyObject *__pyx_v_sig_series = NULL;
   25286         119 :   PyObject *__pyx_v_last_type = NULL;
   25287         119 :   PyObject *__pyx_v_sig_type = NULL;
   25288         119 :   PyObject *__pyx_v_sigindex_matches = NULL;
   25289         119 :   PyObject *__pyx_v_sigindex_candidates = NULL;
   25290         119 :   PyObject *__pyx_v_dst_type = NULL;
   25291         119 :   PyObject *__pyx_v_found_matches = NULL;
   25292         119 :   PyObject *__pyx_v_found_candidates = NULL;
   25293         119 :   PyObject *__pyx_v_sn = NULL;
   25294         119 :   PyObject *__pyx_v_type_match = NULL;
   25295         119 :   PyObject *__pyx_v_candidates = NULL;
   25296         119 :   PyObject *__pyx_r = NULL;
   25297             :   __Pyx_RefNannyDeclarations
   25298         119 :   PyObject *__pyx_t_1 = NULL;
   25299         119 :   int __pyx_t_2;
   25300         119 :   int __pyx_t_3;
   25301         119 :   int __pyx_t_4;
   25302         119 :   Py_ssize_t __pyx_t_5;
   25303         119 :   PyObject *__pyx_t_6 = NULL;
   25304         119 :   long __pyx_t_7;
   25305         119 :   PyObject *__pyx_t_8 = NULL;
   25306         119 :   PyObject *__pyx_t_9 = NULL;
   25307         119 :   PyObject *__pyx_t_10 = NULL;
   25308         119 :   int __pyx_t_11;
   25309         119 :   __Pyx_memviewslice __pyx_t_12;
   25310         119 :   PyObject *__pyx_t_13 = NULL;
   25311         119 :   Py_ssize_t __pyx_t_14;
   25312         119 :   int __pyx_t_15;
   25313         119 :   PyObject *__pyx_t_16 = NULL;
   25314         119 :   PyObject *__pyx_t_17 = NULL;
   25315         119 :   unsigned int __pyx_t_18;
   25316         119 :   Py_ssize_t __pyx_t_19;
   25317         119 :   int __pyx_t_20;
   25318         119 :   int __pyx_lineno = 0;
   25319         119 :   const char *__pyx_filename = NULL;
   25320         119 :   int __pyx_clineno = 0;
   25321         119 :   __Pyx_RefNannySetupContext("get_read_line", 0);
   25322         119 :   __Pyx_INCREF(__pyx_v_kwargs);
   25323         119 :   __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25324         119 :   __Pyx_GOTREF(__pyx_t_1);
   25325         119 :   __Pyx_INCREF(Py_None);
   25326         119 :   __Pyx_GIVEREF(Py_None);
   25327         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_1, 0, Py_None)) __PYX_ERR(0, 96, __pyx_L1_error);
   25328         119 :   __pyx_v_dest_sig = ((PyObject*)__pyx_t_1);
   25329         119 :   __pyx_t_1 = 0;
   25330         119 :   __pyx_t_3 = (__pyx_v_kwargs != Py_None);
   25331         119 :   if (__pyx_t_3) {
   25332           0 :   } else {
   25333         119 :     __pyx_t_2 = __pyx_t_3;
   25334         119 :     goto __pyx_L4_bool_binop_done;
   25335             :   }
   25336           0 :   __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_kwargs); if (unlikely((__pyx_t_3 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25337           0 :   __pyx_t_4 = (!__pyx_t_3);
   25338           0 :   __pyx_t_2 = __pyx_t_4;
   25339         119 :   __pyx_L4_bool_binop_done:;
   25340         119 :   if (__pyx_t_2) {
   25341           0 :     __Pyx_INCREF(Py_None);
   25342           0 :     __Pyx_DECREF_SET(__pyx_v_kwargs, Py_None);
   25343             :   }
   25344         119 :   __pyx_t_1 = ((PyObject *)__Pyx_ImportNumPyArrayTypeIfAvailable()); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25345         119 :   __Pyx_GOTREF(__pyx_t_1);
   25346         119 :   __pyx_v_ndarray = ((PyTypeObject*)__pyx_t_1);
   25347         119 :   __pyx_t_1 = 0;
   25348         119 :   __pyx_v_itemsize = -1L;
   25349         119 :   __pyx_v___pyx_fused_dtype_int8__t_is_signed = (!(((__pyx_t_5numpy_int8_t)-1L) > 0));
   25350         119 :   __pyx_v___pyx_fused_dtype_int16__t_is_signed = (!(((__pyx_t_5numpy_int16_t)-1L) > 0));
   25351         119 :   __pyx_v___pyx_fused_dtype_int32__t_is_signed = (!(((__pyx_t_5numpy_int32_t)-1L) > 0));
   25352         119 :   __pyx_v___pyx_fused_dtype_int64__t_is_signed = (!(((__pyx_t_5numpy_int64_t)-1L) > 0));
   25353         119 :   __pyx_v___pyx_fused_dtype_uint8__t_is_signed = (!(((__pyx_t_5numpy_uint8_t)-1L) > 0));
   25354         119 :   __pyx_v___pyx_fused_dtype_uint16__t_is_signed = (!(((__pyx_t_5numpy_uint16_t)-1L) > 0));
   25355         119 :   __pyx_v___pyx_fused_dtype_uint32__t_is_signed = (!(((__pyx_t_5numpy_uint32_t)-1L) > 0));
   25356         119 :   __pyx_v___pyx_fused_dtype_uint64__t_is_signed = (!(((__pyx_t_5numpy_uint64_t)-1L) > 0));
   25357         119 :   if (unlikely(__pyx_v_args == Py_None)) {
   25358           0 :     PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   25359           0 :     __PYX_ERR(0, 96, __pyx_L1_error)
   25360             :   }
   25361         119 :   __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   25362         119 :   __pyx_t_2 = (0 < __pyx_t_5);
   25363         119 :   if (__pyx_t_2) {
   25364         119 :     if (unlikely(__pyx_v_args == Py_None)) {
   25365             :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   25366             :       __PYX_ERR(0, 96, __pyx_L1_error)
   25367             :     }
   25368         119 :     __pyx_t_1 = __Pyx_GetItemInt_Tuple(((PyObject*)__pyx_v_args), 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25369         119 :     __Pyx_GOTREF(__pyx_t_1);
   25370         119 :     __pyx_v_arg = __pyx_t_1;
   25371         119 :     __pyx_t_1 = 0;
   25372         119 :     goto __pyx_L6;
   25373             :   }
   25374           0 :   __pyx_t_4 = (__pyx_v_kwargs != Py_None);
   25375           0 :   if (__pyx_t_4) {
   25376           0 :   } else {
   25377           0 :     __pyx_t_2 = __pyx_t_4;
   25378           0 :     goto __pyx_L7_bool_binop_done;
   25379             :   }
   25380           0 :   if (unlikely(__pyx_v_kwargs == Py_None)) {
   25381             :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   25382             :     __PYX_ERR(0, 96, __pyx_L1_error)
   25383             :   }
   25384           0 :   __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_n_s_a, ((PyObject*)__pyx_v_kwargs), Py_EQ)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25385             :   __pyx_t_2 = __pyx_t_4;
   25386           0 :   __pyx_L7_bool_binop_done:;
   25387           0 :   if (likely(__pyx_t_2)) {
   25388           0 :     if (unlikely(__pyx_v_kwargs == Py_None)) {
   25389           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   25390           0 :       __PYX_ERR(0, 96, __pyx_L1_error)
   25391             :     }
   25392           0 :     __pyx_t_1 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_kwargs), __pyx_n_s_a); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25393           0 :     __Pyx_GOTREF(__pyx_t_1);
   25394           0 :     __pyx_v_arg = __pyx_t_1;
   25395           0 :     __pyx_t_1 = 0;
   25396           0 :     goto __pyx_L6;
   25397             :   }
   25398             :   /*else*/ {
   25399           0 :     if (unlikely(__pyx_v_args == Py_None)) {
   25400             :       PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   25401             :       __PYX_ERR(0, 96, __pyx_L1_error)
   25402             :     }
   25403           0 :     __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   25404           0 :     __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25405           0 :     __Pyx_GOTREF(__pyx_t_1);
   25406           0 :     __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25407           0 :     __Pyx_GOTREF(__pyx_t_6);
   25408           0 :     __Pyx_INCREF(__pyx_int_1);
   25409           0 :     __Pyx_GIVEREF(__pyx_int_1);
   25410           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_int_1)) __PYX_ERR(0, 96, __pyx_L1_error);
   25411           0 :     __Pyx_INCREF(__pyx_kp_s__11);
   25412           0 :     __Pyx_GIVEREF(__pyx_kp_s__11);
   25413           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_kp_s__11)) __PYX_ERR(0, 96, __pyx_L1_error);
   25414           0 :     __Pyx_GIVEREF(__pyx_t_1);
   25415           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error);
   25416           0 :     __pyx_t_1 = 0;
   25417           0 :     __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_Expected_at_least_d_argument_s_g, __pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   25418           0 :     __Pyx_GOTREF(__pyx_t_1);
   25419           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25420           0 :     __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25421           0 :     __Pyx_GOTREF(__pyx_t_6);
   25422           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   25423           0 :     __Pyx_Raise(__pyx_t_6, 0, 0, 0);
   25424           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25425           0 :     __PYX_ERR(0, 96, __pyx_L1_error)
   25426             :   }
   25427         119 :   __pyx_L6:;
   25428         119 :   while (1) {
   25429         119 :     __pyx_t_2 = (__pyx_v_ndarray != ((PyTypeObject*)Py_None));
   25430         119 :     if (__pyx_t_2) {
   25431         119 :       __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg, __pyx_v_ndarray); 
   25432         119 :       if (__pyx_t_2) {
   25433         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25434         119 :         __Pyx_GOTREF(__pyx_t_6);
   25435         119 :         __pyx_v_dtype = __pyx_t_6;
   25436         119 :         __pyx_t_6 = 0;
   25437         119 :         goto __pyx_L12;
   25438             :       }
   25439           0 :       __pyx_t_2 = __pyx_memoryview_check(__pyx_v_arg); 
   25440           0 :       if (__pyx_t_2) {
   25441           0 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_base); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25442           0 :         __Pyx_GOTREF(__pyx_t_6);
   25443           0 :         __pyx_v_arg_base = __pyx_t_6;
   25444           0 :         __pyx_t_6 = 0;
   25445           0 :         __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg_base, __pyx_v_ndarray); 
   25446           0 :         if (__pyx_t_2) {
   25447           0 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg_base, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25448           0 :           __Pyx_GOTREF(__pyx_t_6);
   25449           0 :           __pyx_v_dtype = __pyx_t_6;
   25450           0 :           __pyx_t_6 = 0;
   25451           0 :           goto __pyx_L13;
   25452             :         }
   25453             :         /*else*/ {
   25454           0 :           __Pyx_INCREF(Py_None);
   25455             :           __pyx_v_dtype = Py_None;
   25456             :         }
   25457           0 :         __pyx_L13:;
   25458           0 :         goto __pyx_L12;
   25459             :       }
   25460             :       /*else*/ {
   25461           0 :         __Pyx_INCREF(Py_None);
   25462             :         __pyx_v_dtype = Py_None;
   25463             :       }
   25464         119 :       __pyx_L12:;
   25465         119 :       __pyx_v_itemsize = -1L;
   25466         119 :       __pyx_t_2 = (__pyx_v_dtype != Py_None);
   25467         119 :       if (__pyx_t_2) {
   25468         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_itemsize); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25469         119 :         __Pyx_GOTREF(__pyx_t_6);
   25470         119 :         __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25471         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25472         119 :         __pyx_v_itemsize = __pyx_t_5;
   25473         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_kind); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25474         119 :         __Pyx_GOTREF(__pyx_t_6);
   25475         119 :         __pyx_t_7 = __Pyx_PyObject_Ord(__pyx_t_6); if (unlikely(__pyx_t_7 == ((long)(long)(Py_UCS4)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   25476         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25477         119 :         __pyx_v_kind = __pyx_t_7;
   25478         119 :         __pyx_v_dtype_signed = (__pyx_v_kind == 0x69);
   25479         119 :         switch (__pyx_v_kind) {
   25480         113 :           case 0x69:
   25481             :           case 0x75:
   25482         113 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int8_t)) == __pyx_v_itemsize);
   25483         113 :           if (__pyx_t_4) {
   25484           6 :           } else {
   25485         107 :             __pyx_t_2 = __pyx_t_4;
   25486         107 :             goto __pyx_L16_bool_binop_done;
   25487             :           }
   25488           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25489           6 :           __Pyx_GOTREF(__pyx_t_6);
   25490           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25491           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25492           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25493           6 :           if (__pyx_t_4) {
   25494           6 :           } else {
   25495           0 :             __pyx_t_2 = __pyx_t_4;
   25496           0 :             goto __pyx_L16_bool_binop_done;
   25497             :           }
   25498           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int8__t_is_signed ^ __pyx_v_dtype_signed));
   25499           6 :           __pyx_t_2 = __pyx_t_4;
   25500         113 :           __pyx_L16_bool_binop_done:;
   25501         113 :           if (__pyx_t_2) {
   25502           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25503           3 :             goto __pyx_L10_break;
   25504             :           }
   25505         110 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int16_t)) == __pyx_v_itemsize);
   25506         110 :           if (__pyx_t_4) {
   25507           6 :           } else {
   25508         104 :             __pyx_t_2 = __pyx_t_4;
   25509         104 :             goto __pyx_L20_bool_binop_done;
   25510             :           }
   25511           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25512           6 :           __Pyx_GOTREF(__pyx_t_6);
   25513           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25514           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25515           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25516           6 :           if (__pyx_t_4) {
   25517           6 :           } else {
   25518           0 :             __pyx_t_2 = __pyx_t_4;
   25519           0 :             goto __pyx_L20_bool_binop_done;
   25520             :           }
   25521           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int16__t_is_signed ^ __pyx_v_dtype_signed));
   25522           6 :           __pyx_t_2 = __pyx_t_4;
   25523         110 :           __pyx_L20_bool_binop_done:;
   25524         110 :           if (__pyx_t_2) {
   25525           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25526           3 :             goto __pyx_L10_break;
   25527             :           }
   25528         107 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int32_t)) == __pyx_v_itemsize);
   25529         107 :           if (__pyx_t_4) {
   25530          95 :           } else {
   25531          12 :             __pyx_t_2 = __pyx_t_4;
   25532          12 :             goto __pyx_L24_bool_binop_done;
   25533             :           }
   25534          95 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25535          95 :           __Pyx_GOTREF(__pyx_t_6);
   25536          95 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25537          95 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25538          95 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25539          95 :           if (__pyx_t_4) {
   25540          95 :           } else {
   25541           0 :             __pyx_t_2 = __pyx_t_4;
   25542           0 :             goto __pyx_L24_bool_binop_done;
   25543             :           }
   25544          95 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int32__t_is_signed ^ __pyx_v_dtype_signed));
   25545          95 :           __pyx_t_2 = __pyx_t_4;
   25546         107 :           __pyx_L24_bool_binop_done:;
   25547         107 :           if (__pyx_t_2) {
   25548          92 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25549          92 :             goto __pyx_L10_break;
   25550             :           }
   25551          15 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int64_t)) == __pyx_v_itemsize);
   25552          15 :           if (__pyx_t_4) {
   25553           6 :           } else {
   25554           9 :             __pyx_t_2 = __pyx_t_4;
   25555           9 :             goto __pyx_L28_bool_binop_done;
   25556             :           }
   25557           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25558           6 :           __Pyx_GOTREF(__pyx_t_6);
   25559           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25560           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25561           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25562           6 :           if (__pyx_t_4) {
   25563           6 :           } else {
   25564           0 :             __pyx_t_2 = __pyx_t_4;
   25565           0 :             goto __pyx_L28_bool_binop_done;
   25566             :           }
   25567           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int64__t_is_signed ^ __pyx_v_dtype_signed));
   25568           6 :           __pyx_t_2 = __pyx_t_4;
   25569          15 :           __pyx_L28_bool_binop_done:;
   25570          15 :           if (__pyx_t_2) {
   25571           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25572           3 :             goto __pyx_L10_break;
   25573             :           }
   25574          12 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint8_t)) == __pyx_v_itemsize);
   25575          12 :           if (__pyx_t_4) {
   25576           3 :           } else {
   25577           9 :             __pyx_t_2 = __pyx_t_4;
   25578           9 :             goto __pyx_L32_bool_binop_done;
   25579             :           }
   25580           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25581           3 :           __Pyx_GOTREF(__pyx_t_6);
   25582           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25583           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25584           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25585           3 :           if (__pyx_t_4) {
   25586           3 :           } else {
   25587           0 :             __pyx_t_2 = __pyx_t_4;
   25588           0 :             goto __pyx_L32_bool_binop_done;
   25589             :           }
   25590           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint8__t_is_signed ^ __pyx_v_dtype_signed));
   25591           3 :           __pyx_t_2 = __pyx_t_4;
   25592          12 :           __pyx_L32_bool_binop_done:;
   25593          12 :           if (__pyx_t_2) {
   25594           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25595           3 :             goto __pyx_L10_break;
   25596             :           }
   25597           9 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint16_t)) == __pyx_v_itemsize);
   25598           9 :           if (__pyx_t_4) {
   25599           3 :           } else {
   25600           6 :             __pyx_t_2 = __pyx_t_4;
   25601           6 :             goto __pyx_L36_bool_binop_done;
   25602             :           }
   25603           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25604           3 :           __Pyx_GOTREF(__pyx_t_6);
   25605           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25606           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25607           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25608           3 :           if (__pyx_t_4) {
   25609           3 :           } else {
   25610           0 :             __pyx_t_2 = __pyx_t_4;
   25611           0 :             goto __pyx_L36_bool_binop_done;
   25612             :           }
   25613           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint16__t_is_signed ^ __pyx_v_dtype_signed));
   25614           3 :           __pyx_t_2 = __pyx_t_4;
   25615           9 :           __pyx_L36_bool_binop_done:;
   25616           9 :           if (__pyx_t_2) {
   25617           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25618           3 :             goto __pyx_L10_break;
   25619             :           }
   25620           6 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint32_t)) == __pyx_v_itemsize);
   25621           6 :           if (__pyx_t_4) {
   25622           3 :           } else {
   25623           3 :             __pyx_t_2 = __pyx_t_4;
   25624           3 :             goto __pyx_L40_bool_binop_done;
   25625             :           }
   25626           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25627           3 :           __Pyx_GOTREF(__pyx_t_6);
   25628           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25629           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25630           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25631           3 :           if (__pyx_t_4) {
   25632           3 :           } else {
   25633           0 :             __pyx_t_2 = __pyx_t_4;
   25634           0 :             goto __pyx_L40_bool_binop_done;
   25635             :           }
   25636           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint32__t_is_signed ^ __pyx_v_dtype_signed));
   25637           3 :           __pyx_t_2 = __pyx_t_4;
   25638           6 :           __pyx_L40_bool_binop_done:;
   25639           6 :           if (__pyx_t_2) {
   25640           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25641           3 :             goto __pyx_L10_break;
   25642             :           }
   25643           3 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint64_t)) == __pyx_v_itemsize);
   25644           3 :           if (__pyx_t_4) {
   25645           3 :           } else {
   25646           0 :             __pyx_t_2 = __pyx_t_4;
   25647           0 :             goto __pyx_L44_bool_binop_done;
   25648             :           }
   25649           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25650           3 :           __Pyx_GOTREF(__pyx_t_6);
   25651           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25652           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25653           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25654           3 :           if (__pyx_t_4) {
   25655           3 :           } else {
   25656           0 :             __pyx_t_2 = __pyx_t_4;
   25657           0 :             goto __pyx_L44_bool_binop_done;
   25658             :           }
   25659           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint64__t_is_signed ^ __pyx_v_dtype_signed));
   25660           3 :           __pyx_t_2 = __pyx_t_4;
   25661           3 :           __pyx_L44_bool_binop_done:;
   25662           3 :           if (__pyx_t_2) {
   25663           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25664           3 :             goto __pyx_L10_break;
   25665             :           }
   25666             :           break;
   25667           6 :           case 0x66:
   25668           6 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float32_t)) == __pyx_v_itemsize);
   25669           6 :           if (__pyx_t_4) {
   25670           3 :           } else {
   25671           3 :             __pyx_t_2 = __pyx_t_4;
   25672           3 :             goto __pyx_L48_bool_binop_done;
   25673             :           }
   25674           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25675           3 :           __Pyx_GOTREF(__pyx_t_6);
   25676           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25677           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25678           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25679           3 :           __pyx_t_2 = __pyx_t_4;
   25680           6 :           __pyx_L48_bool_binop_done:;
   25681           6 :           if (__pyx_t_2) {
   25682           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25683           3 :             goto __pyx_L10_break;
   25684             :           }
   25685           3 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float64_t)) == __pyx_v_itemsize);
   25686           3 :           if (__pyx_t_4) {
   25687           3 :           } else {
   25688           0 :             __pyx_t_2 = __pyx_t_4;
   25689           0 :             goto __pyx_L51_bool_binop_done;
   25690             :           }
   25691           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   25692           3 :           __Pyx_GOTREF(__pyx_t_6);
   25693           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L1_error)
   25694           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   25695           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   25696           3 :           __pyx_t_2 = __pyx_t_4;
   25697           3 :           __pyx_L51_bool_binop_done:;
   25698           3 :           if (__pyx_t_2) {
   25699           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25700           3 :             goto __pyx_L10_break;
   25701             :           }
   25702             :           break;
   25703             :           case 99:
   25704             :           break;
   25705             :           case 79:
   25706             :           break;
   25707             :           default: break;
   25708             :         }
   25709             :       }
   25710             :     }
   25711           0 :     __pyx_t_2 = (__pyx_v_arg == Py_None);
   25712           0 :     if (__pyx_t_2) {
   25713           0 :       if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   25714           0 :       goto __pyx_L10_break;
   25715             :     }
   25716             :     {
   25717           0 :       __Pyx_PyThreadState_declare
   25718           0 :       __Pyx_PyThreadState_assign
   25719           0 :       __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10);
   25720           0 :       __Pyx_XGOTREF(__pyx_t_8);
   25721           0 :       __Pyx_XGOTREF(__pyx_t_9);
   25722           0 :       __Pyx_XGOTREF(__pyx_t_10);
   25723             :       /*try:*/ {
   25724           0 :         __pyx_t_6 = PyMemoryView_FromObject(__pyx_v_arg); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L54_error)
   25725           0 :         __Pyx_GOTREF(__pyx_t_6);
   25726           0 :         __pyx_v_arg_as_memoryview = ((PyObject*)__pyx_t_6);
   25727           0 :         __pyx_t_6 = 0;
   25728             :       }
   25729             :       /*else:*/ {
   25730           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25731           0 :         if (!__pyx_t_4) {
   25732           0 :           goto __pyx_L65_next_or;
   25733             :         } else {
   25734           0 :         }
   25735           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25736           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int8_t)));
   25737           0 :         if (!__pyx_t_4) {
   25738             :         } else {
   25739           0 :           goto __pyx_L64_next_and;
   25740             :         }
   25741           0 :         __pyx_L65_next_or:;
   25742           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int8_t)));
   25743           0 :         if (__pyx_t_4) {
   25744             :         } else {
   25745           0 :           __pyx_t_2 = __pyx_t_4;
   25746           0 :           goto __pyx_L63_bool_binop_done;
   25747             :         }
   25748           0 :         __pyx_L64_next_and:;
   25749           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25750           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25751           0 :         __pyx_t_2 = __pyx_t_4;
   25752           0 :         __pyx_L63_bool_binop_done:;
   25753           0 :         if (__pyx_t_2) {
   25754           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int8_t(__pyx_v_arg_as_memoryview, 0); 
   25755           0 :           __pyx_v_memslice = __pyx_t_12;
   25756           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25757           0 :           if (__pyx_t_2) {
   25758           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25759           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25760           0 :             goto __pyx_L59_try_break;
   25761             :           }
   25762             :           /*else*/ {
   25763           0 :             PyErr_Clear(); 
   25764             :           }
   25765             :         }
   25766           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25767           0 :         if (!__pyx_t_4) {
   25768           0 :           goto __pyx_L71_next_or;
   25769             :         } else {
   25770           0 :         }
   25771           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25772           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int16_t)));
   25773           0 :         if (!__pyx_t_4) {
   25774             :         } else {
   25775           0 :           goto __pyx_L70_next_and;
   25776             :         }
   25777           0 :         __pyx_L71_next_or:;
   25778           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int16_t)));
   25779           0 :         if (__pyx_t_4) {
   25780             :         } else {
   25781           0 :           __pyx_t_2 = __pyx_t_4;
   25782           0 :           goto __pyx_L69_bool_binop_done;
   25783             :         }
   25784           0 :         __pyx_L70_next_and:;
   25785           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25786           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25787           0 :         __pyx_t_2 = __pyx_t_4;
   25788           0 :         __pyx_L69_bool_binop_done:;
   25789           0 :         if (__pyx_t_2) {
   25790           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int16_t(__pyx_v_arg_as_memoryview, 0); 
   25791           0 :           __pyx_v_memslice = __pyx_t_12;
   25792           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25793           0 :           if (__pyx_t_2) {
   25794           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25795           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25796           0 :             goto __pyx_L59_try_break;
   25797             :           }
   25798             :           /*else*/ {
   25799           0 :             PyErr_Clear(); 
   25800             :           }
   25801             :         }
   25802           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25803           0 :         if (!__pyx_t_4) {
   25804           0 :           goto __pyx_L77_next_or;
   25805             :         } else {
   25806           0 :         }
   25807           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25808           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int32_t)));
   25809           0 :         if (!__pyx_t_4) {
   25810             :         } else {
   25811           0 :           goto __pyx_L76_next_and;
   25812             :         }
   25813           0 :         __pyx_L77_next_or:;
   25814           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int32_t)));
   25815           0 :         if (__pyx_t_4) {
   25816             :         } else {
   25817           0 :           __pyx_t_2 = __pyx_t_4;
   25818           0 :           goto __pyx_L75_bool_binop_done;
   25819             :         }
   25820           0 :         __pyx_L76_next_and:;
   25821           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25822           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25823           0 :         __pyx_t_2 = __pyx_t_4;
   25824           0 :         __pyx_L75_bool_binop_done:;
   25825           0 :         if (__pyx_t_2) {
   25826           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int32_t(__pyx_v_arg_as_memoryview, 0); 
   25827           0 :           __pyx_v_memslice = __pyx_t_12;
   25828           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25829           0 :           if (__pyx_t_2) {
   25830           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25831           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25832           0 :             goto __pyx_L59_try_break;
   25833             :           }
   25834             :           /*else*/ {
   25835           0 :             PyErr_Clear(); 
   25836             :           }
   25837             :         }
   25838           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25839           0 :         if (!__pyx_t_4) {
   25840           0 :           goto __pyx_L83_next_or;
   25841             :         } else {
   25842           0 :         }
   25843           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25844           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int64_t)));
   25845           0 :         if (!__pyx_t_4) {
   25846             :         } else {
   25847           0 :           goto __pyx_L82_next_and;
   25848             :         }
   25849           0 :         __pyx_L83_next_or:;
   25850           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int64_t)));
   25851           0 :         if (__pyx_t_4) {
   25852             :         } else {
   25853           0 :           __pyx_t_2 = __pyx_t_4;
   25854           0 :           goto __pyx_L81_bool_binop_done;
   25855             :         }
   25856           0 :         __pyx_L82_next_and:;
   25857           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25858           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25859           0 :         __pyx_t_2 = __pyx_t_4;
   25860           0 :         __pyx_L81_bool_binop_done:;
   25861           0 :         if (__pyx_t_2) {
   25862           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int64_t(__pyx_v_arg_as_memoryview, 0); 
   25863           0 :           __pyx_v_memslice = __pyx_t_12;
   25864           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25865           0 :           if (__pyx_t_2) {
   25866           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25867           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25868           0 :             goto __pyx_L59_try_break;
   25869             :           }
   25870             :           /*else*/ {
   25871           0 :             PyErr_Clear(); 
   25872             :           }
   25873             :         }
   25874           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25875           0 :         if (!__pyx_t_4) {
   25876           0 :           goto __pyx_L89_next_or;
   25877             :         } else {
   25878           0 :         }
   25879           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25880           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint8_t)));
   25881           0 :         if (!__pyx_t_4) {
   25882             :         } else {
   25883           0 :           goto __pyx_L88_next_and;
   25884             :         }
   25885           0 :         __pyx_L89_next_or:;
   25886           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint8_t)));
   25887           0 :         if (__pyx_t_4) {
   25888             :         } else {
   25889           0 :           __pyx_t_2 = __pyx_t_4;
   25890           0 :           goto __pyx_L87_bool_binop_done;
   25891             :         }
   25892           0 :         __pyx_L88_next_and:;
   25893           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25894           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25895           0 :         __pyx_t_2 = __pyx_t_4;
   25896           0 :         __pyx_L87_bool_binop_done:;
   25897           0 :         if (__pyx_t_2) {
   25898           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint8_t(__pyx_v_arg_as_memoryview, 0); 
   25899           0 :           __pyx_v_memslice = __pyx_t_12;
   25900           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25901           0 :           if (__pyx_t_2) {
   25902           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25903           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25904           0 :             goto __pyx_L59_try_break;
   25905             :           }
   25906             :           /*else*/ {
   25907           0 :             PyErr_Clear(); 
   25908             :           }
   25909             :         }
   25910           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25911           0 :         if (!__pyx_t_4) {
   25912           0 :           goto __pyx_L95_next_or;
   25913             :         } else {
   25914           0 :         }
   25915           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25916           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint16_t)));
   25917           0 :         if (!__pyx_t_4) {
   25918             :         } else {
   25919           0 :           goto __pyx_L94_next_and;
   25920             :         }
   25921           0 :         __pyx_L95_next_or:;
   25922           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint16_t)));
   25923           0 :         if (__pyx_t_4) {
   25924             :         } else {
   25925           0 :           __pyx_t_2 = __pyx_t_4;
   25926           0 :           goto __pyx_L93_bool_binop_done;
   25927             :         }
   25928           0 :         __pyx_L94_next_and:;
   25929           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25930           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25931           0 :         __pyx_t_2 = __pyx_t_4;
   25932           0 :         __pyx_L93_bool_binop_done:;
   25933           0 :         if (__pyx_t_2) {
   25934           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint16_t(__pyx_v_arg_as_memoryview, 0); 
   25935           0 :           __pyx_v_memslice = __pyx_t_12;
   25936           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25937           0 :           if (__pyx_t_2) {
   25938           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25939           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25940           0 :             goto __pyx_L59_try_break;
   25941             :           }
   25942             :           /*else*/ {
   25943           0 :             PyErr_Clear(); 
   25944             :           }
   25945             :         }
   25946           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25947           0 :         if (!__pyx_t_4) {
   25948           0 :           goto __pyx_L101_next_or;
   25949             :         } else {
   25950           0 :         }
   25951           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25952           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint32_t)));
   25953           0 :         if (!__pyx_t_4) {
   25954             :         } else {
   25955           0 :           goto __pyx_L100_next_and;
   25956             :         }
   25957           0 :         __pyx_L101_next_or:;
   25958           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint32_t)));
   25959           0 :         if (__pyx_t_4) {
   25960             :         } else {
   25961           0 :           __pyx_t_2 = __pyx_t_4;
   25962           0 :           goto __pyx_L99_bool_binop_done;
   25963             :         }
   25964           0 :         __pyx_L100_next_and:;
   25965           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25966           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   25967           0 :         __pyx_t_2 = __pyx_t_4;
   25968           0 :         __pyx_L99_bool_binop_done:;
   25969           0 :         if (__pyx_t_2) {
   25970           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint32_t(__pyx_v_arg_as_memoryview, 0); 
   25971           0 :           __pyx_v_memslice = __pyx_t_12;
   25972           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   25973           0 :           if (__pyx_t_2) {
   25974           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   25975           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25976           0 :             goto __pyx_L59_try_break;
   25977             :           }
   25978             :           /*else*/ {
   25979           0 :             PyErr_Clear(); 
   25980             :           }
   25981             :         }
   25982           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   25983           0 :         if (!__pyx_t_4) {
   25984           0 :           goto __pyx_L107_next_or;
   25985             :         } else {
   25986           0 :         }
   25987           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   25988           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint64_t)));
   25989           0 :         if (!__pyx_t_4) {
   25990             :         } else {
   25991           0 :           goto __pyx_L106_next_and;
   25992             :         }
   25993           0 :         __pyx_L107_next_or:;
   25994           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint64_t)));
   25995           0 :         if (__pyx_t_4) {
   25996             :         } else {
   25997           0 :           __pyx_t_2 = __pyx_t_4;
   25998           0 :           goto __pyx_L105_bool_binop_done;
   25999             :         }
   26000           0 :         __pyx_L106_next_and:;
   26001           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26002           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   26003           0 :         __pyx_t_2 = __pyx_t_4;
   26004           0 :         __pyx_L105_bool_binop_done:;
   26005           0 :         if (__pyx_t_2) {
   26006           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint64_t(__pyx_v_arg_as_memoryview, 0); 
   26007           0 :           __pyx_v_memslice = __pyx_t_12;
   26008           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   26009           0 :           if (__pyx_t_2) {
   26010           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   26011           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26012           0 :             goto __pyx_L59_try_break;
   26013             :           }
   26014             :           /*else*/ {
   26015           0 :             PyErr_Clear(); 
   26016             :           }
   26017             :         }
   26018           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   26019           0 :         if (!__pyx_t_4) {
   26020           0 :           goto __pyx_L113_next_or;
   26021             :         } else {
   26022           0 :         }
   26023           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26024           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float32_t)));
   26025           0 :         if (!__pyx_t_4) {
   26026             :         } else {
   26027           0 :           goto __pyx_L112_next_and;
   26028             :         }
   26029           0 :         __pyx_L113_next_or:;
   26030           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float32_t)));
   26031           0 :         if (__pyx_t_4) {
   26032             :         } else {
   26033           0 :           __pyx_t_2 = __pyx_t_4;
   26034           0 :           goto __pyx_L111_bool_binop_done;
   26035             :         }
   26036           0 :         __pyx_L112_next_and:;
   26037           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26038           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   26039           0 :         __pyx_t_2 = __pyx_t_4;
   26040           0 :         __pyx_L111_bool_binop_done:;
   26041           0 :         if (__pyx_t_2) {
   26042           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float32_t(__pyx_v_arg_as_memoryview, 0); 
   26043           0 :           __pyx_v_memslice = __pyx_t_12;
   26044           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   26045           0 :           if (__pyx_t_2) {
   26046           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   26047           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26048           0 :             goto __pyx_L59_try_break;
   26049             :           }
   26050             :           /*else*/ {
   26051           0 :             PyErr_Clear(); 
   26052             :           }
   26053             :         }
   26054           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   26055           0 :         if (!__pyx_t_4) {
   26056           0 :           goto __pyx_L119_next_or;
   26057             :         } else {
   26058           0 :         }
   26059           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26060           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float64_t)));
   26061           0 :         if (!__pyx_t_4) {
   26062             :         } else {
   26063           0 :           goto __pyx_L118_next_and;
   26064             :         }
   26065           0 :         __pyx_L119_next_or:;
   26066           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float64_t)));
   26067           0 :         if (__pyx_t_4) {
   26068             :         } else {
   26069           0 :           __pyx_t_2 = __pyx_t_4;
   26070           0 :           goto __pyx_L117_bool_binop_done;
   26071             :         }
   26072           0 :         __pyx_L118_next_and:;
   26073           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26074           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   26075           0 :         __pyx_t_2 = __pyx_t_4;
   26076           0 :         __pyx_L117_bool_binop_done:;
   26077           0 :         if (__pyx_t_2) {
   26078           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float64_t(__pyx_v_arg_as_memoryview, 0); 
   26079           0 :           __pyx_v_memslice = __pyx_t_12;
   26080           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   26081           0 :           if (__pyx_t_2) {
   26082           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   26083           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26084           0 :             goto __pyx_L59_try_break;
   26085             :           }
   26086             :           /*else*/ {
   26087           0 :             PyErr_Clear(); 
   26088             :           }
   26089             :         }
   26090             :       }
   26091           0 :       __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   26092           0 :       __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
   26093           0 :       __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
   26094           0 :       goto __pyx_L61_try_end;
   26095           0 :       __pyx_L54_error:;
   26096           0 :       __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   26097           0 :       __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   26098           0 :       __pyx_t_11 = __Pyx_PyErr_ExceptionMatches2(__pyx_builtin_ValueError, __pyx_builtin_TypeError);
   26099           0 :       if (__pyx_t_11) {
   26100           0 :         __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26101           0 :         if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_1, &__pyx_t_13) < 0) __PYX_ERR(0, 96, __pyx_L56_except_error)
   26102           0 :         __Pyx_XGOTREF(__pyx_t_6);
   26103           0 :         __Pyx_XGOTREF(__pyx_t_1);
   26104           0 :         __Pyx_XGOTREF(__pyx_t_13);
   26105           0 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   26106           0 :         __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   26107           0 :         __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0;
   26108           0 :         goto __pyx_L55_exception_handled;
   26109             :       }
   26110           0 :       goto __pyx_L56_except_error;
   26111           0 :       __pyx_L56_except_error:;
   26112           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   26113           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   26114           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   26115           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   26116           0 :       goto __pyx_L1_error;
   26117           0 :       __pyx_L59_try_break:;
   26118           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   26119           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   26120           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   26121           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   26122           0 :       goto __pyx_L10_break;
   26123           0 :       __pyx_L55_exception_handled:;
   26124           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   26125           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   26126           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   26127           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   26128           0 :       __pyx_L61_try_end:;
   26129             :     }
   26130           0 :     if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, Py_None, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26131           0 :     goto __pyx_L10_break;
   26132             :   }
   26133         119 :   __pyx_L10_break:;
   26134         119 :   __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v__fused_sigindex); if (unlikely((__pyx_t_2 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26135         119 :   __pyx_t_4 = (!__pyx_t_2);
   26136         119 :   if (__pyx_t_4) {
   26137           1 :     __pyx_t_5 = 0;
   26138           1 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   26139           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   26140           0 :       __PYX_ERR(0, 96, __pyx_L1_error)
   26141             :     }
   26142           2 :     __pyx_t_1 = __Pyx_dict_iterator(((PyObject*)__pyx_v_signatures), 1, ((PyObject *)NULL), (&__pyx_t_14), (&__pyx_t_11)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26143           1 :     __Pyx_GOTREF(__pyx_t_1);
   26144           1 :     __Pyx_XDECREF(__pyx_t_13);
   26145           1 :     __pyx_t_13 = __pyx_t_1;
   26146           1 :     __pyx_t_1 = 0;
   26147          11 :     while (1) {
   26148          11 :       __pyx_t_15 = __Pyx_dict_iter_next(__pyx_t_13, __pyx_t_14, &__pyx_t_5, &__pyx_t_1, NULL, NULL, __pyx_t_11);
   26149          11 :       if (unlikely(__pyx_t_15 == 0)) break;
   26150          10 :       if (unlikely(__pyx_t_15 == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26151          10 :       __Pyx_GOTREF(__pyx_t_1);
   26152          10 :       __Pyx_XDECREF_SET(__pyx_v_sig, __pyx_t_1);
   26153          10 :       __pyx_t_1 = 0;
   26154          10 :       __pyx_t_1 = __pyx_v__fused_sigindex;
   26155          10 :       __Pyx_INCREF(__pyx_t_1);
   26156          10 :       __Pyx_XDECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_1));
   26157          10 :       __pyx_t_1 = 0;
   26158          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_sig, __pyx_n_s_strip); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26159          10 :       __Pyx_GOTREF(__pyx_t_16);
   26160          10 :       __pyx_t_17 = NULL;
   26161          10 :       __pyx_t_18 = 0;
   26162             :       #if CYTHON_UNPACK_METHODS
   26163          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   26164           0 :         __pyx_t_17 = PyMethod_GET_SELF(__pyx_t_16);
   26165           0 :         if (likely(__pyx_t_17)) {
   26166           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   26167           0 :           __Pyx_INCREF(__pyx_t_17);
   26168           0 :           __Pyx_INCREF(function);
   26169           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   26170             :           __pyx_t_18 = 1;
   26171             :         }
   26172             :       }
   26173             :       #endif
   26174             :       {
   26175          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_17, __pyx_kp_s__12};
   26176          10 :         __pyx_t_6 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   26177          10 :         __Pyx_XDECREF(__pyx_t_17); __pyx_t_17 = 0;
   26178          10 :         if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26179          10 :         __Pyx_GOTREF(__pyx_t_6);
   26180          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   26181             :       }
   26182          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_split); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26183          10 :       __Pyx_GOTREF(__pyx_t_16);
   26184          10 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   26185          10 :       __pyx_t_6 = NULL;
   26186          10 :       __pyx_t_18 = 0;
   26187             :       #if CYTHON_UNPACK_METHODS
   26188          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   26189           0 :         __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_16);
   26190           0 :         if (likely(__pyx_t_6)) {
   26191           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   26192           0 :           __Pyx_INCREF(__pyx_t_6);
   26193           0 :           __Pyx_INCREF(function);
   26194           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   26195             :           __pyx_t_18 = 1;
   26196             :         }
   26197             :       }
   26198             :       #endif
   26199             :       {
   26200          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_kp_s__13};
   26201          10 :         __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   26202          10 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   26203          10 :         if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26204          10 :         __Pyx_GOTREF(__pyx_t_1);
   26205          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   26206             :       }
   26207          20 :       __pyx_t_16 = __Pyx_PySequence_ListKeepNew(__pyx_t_1); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26208          10 :       __Pyx_GOTREF(__pyx_t_16);
   26209          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26210          10 :       __pyx_t_19 = PyList_GET_SIZE(__pyx_t_16);
   26211          10 :       if (unlikely(__pyx_t_19 < 1)) {
   26212           0 :         __Pyx_RaiseNeedMoreValuesError(0+__pyx_t_19); __PYX_ERR(0, 96, __pyx_L1_error)
   26213             :       }
   26214             :       #if CYTHON_COMPILING_IN_CPYTHON
   26215          10 :       __pyx_t_6 = PyList_GET_ITEM(__pyx_t_16, __pyx_t_19-1); 
   26216          10 :       ((PyVarObject*)__pyx_t_16)->ob_size--;
   26217             :       #else
   26218             :       __pyx_t_6 = PySequence_ITEM(__pyx_t_16, __pyx_t_19-1); 
   26219             :       #endif
   26220          10 :       __Pyx_GOTREF(__pyx_t_6);
   26221             :       #if !CYTHON_COMPILING_IN_CPYTHON
   26222             :       __pyx_t_17 = PySequence_GetSlice(__pyx_t_16, 0, __pyx_t_19-1); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 96, __pyx_L1_error)
   26223             :       __Pyx_GOTREF(__pyx_t_17);
   26224             :       __Pyx_DECREF(__pyx_t_16);
   26225             :       __pyx_t_16 = __pyx_t_17; __pyx_t_17 = NULL;
   26226             :       #else
   26227          10 :       CYTHON_UNUSED_VAR(__pyx_t_17);
   26228             :       #endif
   26229          10 :       __Pyx_XDECREF_SET(__pyx_v_sig_series, ((PyObject*)__pyx_t_16));
   26230          10 :       __pyx_t_16 = 0;
   26231          10 :       __Pyx_XDECREF_SET(__pyx_v_last_type, __pyx_t_6);
   26232          10 :       __pyx_t_6 = 0;
   26233          10 :       __pyx_t_1 = __pyx_v_sig_series; __Pyx_INCREF(__pyx_t_1);
   26234             :       __pyx_t_19 = 0;
   26235          10 :       for (;;) {
   26236             :         {
   26237          10 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   26238             :           #if !CYTHON_ASSUME_SAFE_MACROS
   26239             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26240             :           #endif
   26241          10 :           if (__pyx_t_19 >= __pyx_temp) break;
   26242             :         }
   26243             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26244           0 :         __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26245             :         #else
   26246             :         __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26247             :         __Pyx_GOTREF(__pyx_t_6);
   26248             :         #endif
   26249           0 :         __Pyx_XDECREF_SET(__pyx_v_sig_type, __pyx_t_6);
   26250           0 :         __pyx_t_6 = 0;
   26251           0 :         if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   26252           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   26253           0 :           __PYX_ERR(0, 96, __pyx_L1_error)
   26254             :         }
   26255           0 :         __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_v_sig_type, __pyx_v_sigindex_node, Py_NE)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26256           0 :         if (__pyx_t_4) {
   26257           0 :           __pyx_t_6 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26258           0 :           __Pyx_GOTREF(__pyx_t_6);
   26259           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   26260             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   26261             :             __PYX_ERR(0, 96, __pyx_L1_error)
   26262             :           }
   26263           0 :           if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_sig_type, __pyx_t_6) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26264           0 :           __Pyx_INCREF(__pyx_t_6);
   26265           0 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, __pyx_t_6);
   26266           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   26267           0 :           goto __pyx_L129;
   26268             :         }
   26269             :         /*else*/ {
   26270           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   26271             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   26272             :             __PYX_ERR(0, 96, __pyx_L1_error)
   26273             :           }
   26274           0 :           __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_sigindex_node, __pyx_v_sig_type); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26275           0 :           __Pyx_GOTREF(__pyx_t_6);
   26276           0 :           __pyx_t_16 = __pyx_t_6;
   26277           0 :           __Pyx_INCREF(__pyx_t_16);
   26278           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   26279          10 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_16));
   26280             :           __pyx_t_16 = 0;
   26281             :         }
   26282             :         __pyx_L129:;
   26283             :       }
   26284          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26285          10 :       if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   26286           0 :         PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   26287           0 :         __PYX_ERR(0, 96, __pyx_L1_error)
   26288             :       }
   26289          10 :       if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_last_type, __pyx_v_sig) < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26290             :     }
   26291           2 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26292             :   }
   26293         119 :   __pyx_t_13 = PyList_New(0); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 96, __pyx_L1_error)
   26294         119 :   __Pyx_GOTREF(__pyx_t_13);
   26295         119 :   __pyx_v_sigindex_matches = ((PyObject*)__pyx_t_13);
   26296         119 :   __pyx_t_13 = 0;
   26297         119 :   __pyx_t_13 = PyList_New(1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 96, __pyx_L1_error)
   26298         119 :   __Pyx_GOTREF(__pyx_t_13);
   26299         119 :   __Pyx_INCREF(__pyx_v__fused_sigindex);
   26300         119 :   __Pyx_GIVEREF(__pyx_v__fused_sigindex);
   26301         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_13, 0, __pyx_v__fused_sigindex)) __PYX_ERR(0, 96, __pyx_L1_error);
   26302         119 :   __pyx_v_sigindex_candidates = ((PyObject*)__pyx_t_13);
   26303         119 :   __pyx_t_13 = 0;
   26304         119 :   __pyx_t_13 = __pyx_v_dest_sig; __Pyx_INCREF(__pyx_t_13);
   26305             :   __pyx_t_14 = 0;
   26306         238 :   for (;;) {
   26307             :     {
   26308         238 :       Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_13);
   26309             :       #if !CYTHON_ASSUME_SAFE_MACROS
   26310             :       if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26311             :       #endif
   26312         238 :       if (__pyx_t_14 >= __pyx_temp) break;
   26313             :     }
   26314             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26315         119 :     __pyx_t_1 = PyList_GET_ITEM(__pyx_t_13, __pyx_t_14); __Pyx_INCREF(__pyx_t_1); __pyx_t_14++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26316             :     #else
   26317             :     __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_13, __pyx_t_14); __pyx_t_14++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26318             :     __Pyx_GOTREF(__pyx_t_1);
   26319             :     #endif
   26320         119 :     __Pyx_XDECREF_SET(__pyx_v_dst_type, __pyx_t_1);
   26321         119 :     __pyx_t_1 = 0;
   26322         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26323         119 :     __Pyx_GOTREF(__pyx_t_1);
   26324         119 :     __Pyx_XDECREF_SET(__pyx_v_found_matches, ((PyObject*)__pyx_t_1));
   26325         119 :     __pyx_t_1 = 0;
   26326         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26327         119 :     __Pyx_GOTREF(__pyx_t_1);
   26328         119 :     __Pyx_XDECREF_SET(__pyx_v_found_candidates, ((PyObject*)__pyx_t_1));
   26329         119 :     __pyx_t_1 = 0;
   26330         119 :     __pyx_t_4 = (__pyx_v_dst_type == Py_None);
   26331         119 :     if (__pyx_t_4) {
   26332           0 :       __pyx_t_1 = __pyx_v_sigindex_matches; __Pyx_INCREF(__pyx_t_1);
   26333           0 :       __pyx_t_5 = 0;
   26334           0 :       for (;;) {
   26335             :         {
   26336           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   26337             :           #if !CYTHON_ASSUME_SAFE_MACROS
   26338             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26339             :           #endif
   26340           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   26341             :         }
   26342             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26343           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26344             :         #else
   26345             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26346             :         __Pyx_GOTREF(__pyx_t_16);
   26347             :         #endif
   26348           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   26349           0 :         __pyx_t_16 = 0;
   26350           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   26351           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   26352           0 :           __PYX_ERR(0, 96, __pyx_L1_error)
   26353             :         }
   26354           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26355           0 :         __Pyx_GOTREF(__pyx_t_16);
   26356           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_matches, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   26357           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   26358             :       }
   26359           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26360           0 :       __pyx_t_1 = __pyx_v_sigindex_candidates; __Pyx_INCREF(__pyx_t_1);
   26361           0 :       __pyx_t_5 = 0;
   26362           0 :       for (;;) {
   26363             :         {
   26364           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   26365             :           #if !CYTHON_ASSUME_SAFE_MACROS
   26366             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26367             :           #endif
   26368           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   26369             :         }
   26370             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26371           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26372             :         #else
   26373             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26374             :         __Pyx_GOTREF(__pyx_t_16);
   26375             :         #endif
   26376           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   26377           0 :         __pyx_t_16 = 0;
   26378           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   26379           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   26380           0 :           __PYX_ERR(0, 96, __pyx_L1_error)
   26381             :         }
   26382           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26383           0 :         __Pyx_GOTREF(__pyx_t_16);
   26384           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_candidates, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   26385           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   26386             :       }
   26387           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26388           0 :       goto __pyx_L133;
   26389             :     }
   26390             :     /*else*/ {
   26391         119 :       __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26392         119 :       __Pyx_GOTREF(__pyx_t_1);
   26393         119 :       __Pyx_INCREF(__pyx_v_sigindex_matches);
   26394         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_matches);
   26395         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_sigindex_matches)) __PYX_ERR(0, 96, __pyx_L1_error);
   26396         119 :       __Pyx_INCREF(__pyx_v_sigindex_candidates);
   26397         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_candidates);
   26398         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_sigindex_candidates)) __PYX_ERR(0, 96, __pyx_L1_error);
   26399         119 :       __pyx_t_16 = __pyx_t_1; __Pyx_INCREF(__pyx_t_16);
   26400         119 :       __pyx_t_5 = 0;
   26401         238 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26402         595 :       for (;;) {
   26403         357 :         if (__pyx_t_5 >= 2) break;
   26404             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26405         238 :         __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_16, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26406             :         #else
   26407             :         __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_16, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26408             :         __Pyx_GOTREF(__pyx_t_1);
   26409             :         #endif
   26410         238 :         __Pyx_XDECREF_SET(__pyx_v_search_list, ((PyObject*)__pyx_t_1));
   26411         238 :         __pyx_t_1 = 0;
   26412         238 :         if (unlikely(__pyx_v_search_list == Py_None)) {
   26413           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   26414           0 :           __PYX_ERR(0, 96, __pyx_L1_error)
   26415             :         }
   26416         238 :         __pyx_t_1 = __pyx_v_search_list; __Pyx_INCREF(__pyx_t_1);
   26417             :         __pyx_t_19 = 0;
   26418         357 :         for (;;) {
   26419             :           {
   26420         357 :             Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   26421             :             #if !CYTHON_ASSUME_SAFE_MACROS
   26422             :             if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26423             :             #endif
   26424         357 :             if (__pyx_t_19 >= __pyx_temp) break;
   26425             :           }
   26426             :           #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   26427         119 :           __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26428             :           #else
   26429             :           __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26430             :           __Pyx_GOTREF(__pyx_t_6);
   26431             :           #endif
   26432         119 :           __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_6);
   26433         119 :           __pyx_t_6 = 0;
   26434         119 :           if (unlikely(__pyx_v_sn == Py_None)) {
   26435           0 :             PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get");
   26436           0 :             __PYX_ERR(0, 96, __pyx_L1_error)
   26437             :           }
   26438         119 :           __pyx_t_6 = __Pyx_PyDict_GetItemDefault(((PyObject*)__pyx_v_sn), __pyx_v_dst_type, Py_None); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
   26439         119 :           __Pyx_GOTREF(__pyx_t_6);
   26440         119 :           __Pyx_XDECREF_SET(__pyx_v_type_match, __pyx_t_6);
   26441         119 :           __pyx_t_6 = 0;
   26442         119 :           __pyx_t_4 = (__pyx_v_type_match != Py_None);
   26443         119 :           if (__pyx_t_4) {
   26444         119 :             __pyx_t_20 = __Pyx_PyList_Append(__pyx_v_found_matches, __pyx_v_type_match); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   26445             :           }
   26446             :         }
   26447         476 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   26448             :       }
   26449         119 :       __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   26450             :     }
   26451         119 :     __pyx_L133:;
   26452         119 :     __Pyx_INCREF(__pyx_v_found_matches);
   26453         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_matches, __pyx_v_found_matches);
   26454         119 :     __Pyx_INCREF(__pyx_v_found_candidates);
   26455         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_candidates, __pyx_v_found_candidates);
   26456         119 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_matches) != 0);
   26457         119 :     if (!__pyx_t_2) {
   26458           0 :     } else {
   26459         119 :       __pyx_t_4 = __pyx_t_2;
   26460         119 :       goto __pyx_L148_bool_binop_done;
   26461             :     }
   26462           0 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_candidates) != 0);
   26463           0 :     __pyx_t_4 = __pyx_t_2;
   26464         119 :     __pyx_L148_bool_binop_done:;
   26465         119 :     __pyx_t_2 = (!__pyx_t_4);
   26466         119 :     if (__pyx_t_2) {
   26467           0 :       goto __pyx_L132_break;
   26468             :     }
   26469             :   }
   26470         119 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26471         119 :   goto __pyx_L150_for_end;
   26472           0 :   __pyx_L132_break:;
   26473           0 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26474           0 :   goto __pyx_L150_for_end;
   26475         119 :   __pyx_L150_for_end:;
   26476         119 :   __Pyx_INCREF(__pyx_v_sigindex_matches);
   26477         119 :   __pyx_v_candidates = __pyx_v_sigindex_matches;
   26478         119 :   __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_candidates) != 0);
   26479         119 :   __pyx_t_4 = (!__pyx_t_2);
   26480         119 :   if (unlikely(__pyx_t_4)) {
   26481           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__14, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 96, __pyx_L1_error)
   26482           0 :     __Pyx_GOTREF(__pyx_t_13);
   26483           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   26484           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26485           0 :     __PYX_ERR(0, 96, __pyx_L1_error)
   26486             :   }
   26487         119 :   __pyx_t_14 = __Pyx_PyList_GET_SIZE(__pyx_v_candidates); if (unlikely(__pyx_t_14 == ((Py_ssize_t)-1))) __PYX_ERR(0, 96, __pyx_L1_error)
   26488         119 :   __pyx_t_4 = (__pyx_t_14 > 1);
   26489         119 :   if (unlikely(__pyx_t_4)) {
   26490           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__15, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 96, __pyx_L1_error)
   26491           0 :     __Pyx_GOTREF(__pyx_t_13);
   26492           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   26493           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26494           0 :     __PYX_ERR(0, 96, __pyx_L1_error)
   26495             :   }
   26496             :   /*else*/ {
   26497         119 :     __Pyx_XDECREF(__pyx_r);
   26498         119 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   26499           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   26500           0 :       __PYX_ERR(0, 96, __pyx_L1_error)
   26501             :     }
   26502         119 :     __pyx_t_13 = __Pyx_GetItemInt_List(__pyx_v_candidates, 0, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 96, __pyx_L1_error)
   26503         119 :     __Pyx_GOTREF(__pyx_t_13);
   26504         119 :     __pyx_t_16 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_signatures), __pyx_t_13); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 96, __pyx_L1_error)
   26505         119 :     __Pyx_GOTREF(__pyx_t_16);
   26506         119 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   26507         119 :     __pyx_r = __pyx_t_16;
   26508         119 :     __pyx_t_16 = 0;
   26509         119 :     goto __pyx_L0;
   26510             :   }
   26511             : 
   26512             :   /* function exit code */
   26513           0 :   __pyx_L1_error:;
   26514           0 :   __Pyx_XDECREF(__pyx_t_1);
   26515           0 :   __Pyx_XDECREF(__pyx_t_6);
   26516           0 :   __Pyx_XDECREF(__pyx_t_13);
   26517           0 :   __Pyx_XDECREF(__pyx_t_16);
   26518           0 :   __Pyx_XDECREF(__pyx_t_17);
   26519           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26520           0 :   __pyx_r = NULL;
   26521         119 :   __pyx_L0:;
   26522         119 :   __Pyx_XDECREF(__pyx_v_search_list);
   26523         119 :   __Pyx_XDECREF(__pyx_v_sigindex_node);
   26524         119 :   __Pyx_XDECREF(__pyx_v_dest_sig);
   26525         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_ndarray);
   26526         119 :   __Pyx_XDECREF(__pyx_v_arg_as_memoryview);
   26527         119 :   __Pyx_XDECREF(__pyx_v_arg);
   26528         119 :   __Pyx_XDECREF(__pyx_v_dtype);
   26529         119 :   __Pyx_XDECREF(__pyx_v_arg_base);
   26530         119 :   __Pyx_XDECREF(__pyx_v_sig);
   26531         119 :   __Pyx_XDECREF(__pyx_v_sig_series);
   26532         119 :   __Pyx_XDECREF(__pyx_v_last_type);
   26533         119 :   __Pyx_XDECREF(__pyx_v_sig_type);
   26534         119 :   __Pyx_XDECREF(__pyx_v_sigindex_matches);
   26535         119 :   __Pyx_XDECREF(__pyx_v_sigindex_candidates);
   26536         119 :   __Pyx_XDECREF(__pyx_v_dst_type);
   26537         119 :   __Pyx_XDECREF(__pyx_v_found_matches);
   26538         119 :   __Pyx_XDECREF(__pyx_v_found_candidates);
   26539         119 :   __Pyx_XDECREF(__pyx_v_sn);
   26540         119 :   __Pyx_XDECREF(__pyx_v_type_match);
   26541         119 :   __Pyx_XDECREF(__pyx_v_candidates);
   26542         119 :   __Pyx_XDECREF(__pyx_v_kwargs);
   26543         119 :   __Pyx_XGIVEREF(__pyx_r);
   26544         119 :   __Pyx_RefNannyFinishContext();
   26545         119 :   return __pyx_r;
   26546             : }
   26547             : 
   26548             : /* Python wrapper */
   26549             : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_31get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   26550             : static PyMethodDef __pyx_fuse_0__pyx_mdef_9_ni_label_31get_read_line = {"__pyx_fuse_0get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_0__pyx_pw_9_ni_label_31get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   26551           3 : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_31get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   26552           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   26553           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   26554           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   26555           3 :   PyObject* values[1] = {0};
   26556           3 :   int __pyx_lineno = 0;
   26557           3 :   const char *__pyx_filename = NULL;
   26558           3 :   int __pyx_clineno = 0;
   26559           3 :   PyObject *__pyx_r = 0;
   26560             :   __Pyx_RefNannyDeclarations
   26561           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   26562             :   #if CYTHON_ASSUME_SAFE_MACROS
   26563           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   26564             :   #else
   26565             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   26566             :   #endif
   26567           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   26568             :   {
   26569           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   26570           3 :     if (__pyx_kwds) {
   26571           0 :       Py_ssize_t kw_args;
   26572           0 :       switch (__pyx_nargs) {
   26573           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26574           0 :         CYTHON_FALLTHROUGH;
   26575           0 :         case  0: break;
   26576           0 :         default: goto __pyx_L5_argtuple_error;
   26577             :       }
   26578           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   26579           0 :       switch (__pyx_nargs) {
   26580           0 :         case  0:
   26581           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   26582           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   26583           0 :           kw_args--;
   26584             :         }
   26585           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   26586           0 :         else goto __pyx_L5_argtuple_error;
   26587             :       }
   26588           0 :       if (unlikely(kw_args > 0)) {
   26589           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   26590           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   26591             :       }
   26592           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   26593           0 :       goto __pyx_L5_argtuple_error;
   26594             :     } else {
   26595           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26596             :     }
   26597           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   26598             :   }
   26599           3 :   goto __pyx_L6_skip;
   26600           0 :   __pyx_L5_argtuple_error:;
   26601           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   26602           3 :   __pyx_L6_skip:;
   26603           3 :   goto __pyx_L4_argument_unpacking_done;
   26604           0 :   __pyx_L3_error:;
   26605             :   {
   26606           0 :     Py_ssize_t __pyx_temp;
   26607           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26608             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26609             :     }
   26610             :   }
   26611           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26612           0 :   __Pyx_RefNannyFinishContext();
   26613           0 :   return NULL;
   26614           3 :   __pyx_L4_argument_unpacking_done:;
   26615           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26616           3 :   __pyx_r = __pyx_pf_9_ni_label_30get_read_line(__pyx_self, __pyx_v_a);
   26617             : 
   26618             :   /* function exit code */
   26619           3 :   goto __pyx_L0;
   26620           0 :   __pyx_L1_error:;
   26621           0 :   __pyx_r = NULL;
   26622           3 :   __pyx_L0:;
   26623             :   {
   26624           3 :     Py_ssize_t __pyx_temp;
   26625           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26626             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26627             :     }
   26628             :   }
   26629             :   __Pyx_RefNannyFinishContext();
   26630             :   return __pyx_r;
   26631             : }
   26632             : 
   26633           3 : static PyObject *__pyx_pf_9_ni_label_30get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   26634           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   26635           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   26636           3 :   PyObject *__pyx_r = NULL;
   26637             :   __Pyx_RefNannyDeclarations
   26638           3 :   PyObject *__pyx_t_1 = NULL;
   26639           3 :   int __pyx_lineno = 0;
   26640           3 :   const char *__pyx_filename = NULL;
   26641           3 :   int __pyx_clineno = 0;
   26642           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_0get_read_line", 1);
   26643           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   26644           3 :   __pyx_pybuffer_a.refcount = 0;
   26645           3 :   __pyx_pybuffernd_a.data = NULL;
   26646           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   26647             :   {
   26648           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   26649           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26650             :   }
   26651           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   26652             : 
   26653             :   /* "_ni_label.pyx":97
   26654             :  * 
   26655             :  * def get_read_line(np.ndarray[data_t] a):
   26656             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   26657             :  * 
   26658             :  * def get_write_line(np.ndarray[data_t] a):
   26659             :  */
   26660           3 :   __Pyx_XDECREF(__pyx_r);
   26661           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_0__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   26662           3 :   __Pyx_GOTREF(__pyx_t_1);
   26663           3 :   __pyx_r = __pyx_t_1;
   26664           3 :   __pyx_t_1 = 0;
   26665           3 :   goto __pyx_L0;
   26666             : 
   26667             :   /* "_ni_label.pyx":96
   26668             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   26669             :  * 
   26670             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   26671             :  *     return <Py_intptr_t> fused_read_line[data_t]
   26672             :  * 
   26673             :  */
   26674             : 
   26675             :   /* function exit code */
   26676           0 :   __pyx_L1_error:;
   26677           0 :   __Pyx_XDECREF(__pyx_t_1);
   26678           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   26679           0 :     __Pyx_PyThreadState_declare
   26680           0 :     __Pyx_PyThreadState_assign
   26681           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   26682           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26683           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   26684           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26685           0 :   __pyx_r = NULL;
   26686           0 :   goto __pyx_L2;
   26687           3 :   __pyx_L0:;
   26688           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26689           3 :   __pyx_L2:;
   26690           3 :   __Pyx_XGIVEREF(__pyx_r);
   26691           3 :   __Pyx_RefNannyFinishContext();
   26692           3 :   return __pyx_r;
   26693             : }
   26694             : 
   26695             : /* Python wrapper */
   26696             : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_33get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   26697             : static PyMethodDef __pyx_fuse_1__pyx_mdef_9_ni_label_33get_read_line = {"__pyx_fuse_1get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_1__pyx_pw_9_ni_label_33get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   26698           3 : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_33get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   26699           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   26700           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   26701           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   26702           3 :   PyObject* values[1] = {0};
   26703           3 :   int __pyx_lineno = 0;
   26704           3 :   const char *__pyx_filename = NULL;
   26705           3 :   int __pyx_clineno = 0;
   26706           3 :   PyObject *__pyx_r = 0;
   26707             :   __Pyx_RefNannyDeclarations
   26708           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   26709             :   #if CYTHON_ASSUME_SAFE_MACROS
   26710           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   26711             :   #else
   26712             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   26713             :   #endif
   26714           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   26715             :   {
   26716           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   26717           3 :     if (__pyx_kwds) {
   26718           0 :       Py_ssize_t kw_args;
   26719           0 :       switch (__pyx_nargs) {
   26720           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26721           0 :         CYTHON_FALLTHROUGH;
   26722           0 :         case  0: break;
   26723           0 :         default: goto __pyx_L5_argtuple_error;
   26724             :       }
   26725           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   26726           0 :       switch (__pyx_nargs) {
   26727           0 :         case  0:
   26728           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   26729           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   26730           0 :           kw_args--;
   26731             :         }
   26732           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   26733           0 :         else goto __pyx_L5_argtuple_error;
   26734             :       }
   26735           0 :       if (unlikely(kw_args > 0)) {
   26736           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   26737           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   26738             :       }
   26739           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   26740           0 :       goto __pyx_L5_argtuple_error;
   26741             :     } else {
   26742           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26743             :     }
   26744           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   26745             :   }
   26746           3 :   goto __pyx_L6_skip;
   26747           0 :   __pyx_L5_argtuple_error:;
   26748           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   26749           3 :   __pyx_L6_skip:;
   26750           3 :   goto __pyx_L4_argument_unpacking_done;
   26751           0 :   __pyx_L3_error:;
   26752             :   {
   26753           0 :     Py_ssize_t __pyx_temp;
   26754           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26755             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26756             :     }
   26757             :   }
   26758           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26759           0 :   __Pyx_RefNannyFinishContext();
   26760           0 :   return NULL;
   26761           3 :   __pyx_L4_argument_unpacking_done:;
   26762           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26763           3 :   __pyx_r = __pyx_pf_9_ni_label_32get_read_line(__pyx_self, __pyx_v_a);
   26764             : 
   26765             :   /* function exit code */
   26766           3 :   goto __pyx_L0;
   26767           0 :   __pyx_L1_error:;
   26768           0 :   __pyx_r = NULL;
   26769           3 :   __pyx_L0:;
   26770             :   {
   26771           3 :     Py_ssize_t __pyx_temp;
   26772           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26773             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26774             :     }
   26775             :   }
   26776             :   __Pyx_RefNannyFinishContext();
   26777             :   return __pyx_r;
   26778             : }
   26779             : 
   26780           3 : static PyObject *__pyx_pf_9_ni_label_32get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   26781           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   26782           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   26783           3 :   PyObject *__pyx_r = NULL;
   26784             :   __Pyx_RefNannyDeclarations
   26785           3 :   PyObject *__pyx_t_1 = NULL;
   26786           3 :   int __pyx_lineno = 0;
   26787           3 :   const char *__pyx_filename = NULL;
   26788           3 :   int __pyx_clineno = 0;
   26789           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_1get_read_line", 1);
   26790           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   26791           3 :   __pyx_pybuffer_a.refcount = 0;
   26792           3 :   __pyx_pybuffernd_a.data = NULL;
   26793           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   26794             :   {
   26795           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   26796           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26797             :   }
   26798           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   26799             : 
   26800             :   /* "_ni_label.pyx":97
   26801             :  * 
   26802             :  * def get_read_line(np.ndarray[data_t] a):
   26803             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   26804             :  * 
   26805             :  * def get_write_line(np.ndarray[data_t] a):
   26806             :  */
   26807           3 :   __Pyx_XDECREF(__pyx_r);
   26808           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_1__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   26809           3 :   __Pyx_GOTREF(__pyx_t_1);
   26810           3 :   __pyx_r = __pyx_t_1;
   26811           3 :   __pyx_t_1 = 0;
   26812           3 :   goto __pyx_L0;
   26813             : 
   26814             :   /* "_ni_label.pyx":96
   26815             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   26816             :  * 
   26817             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   26818             :  *     return <Py_intptr_t> fused_read_line[data_t]
   26819             :  * 
   26820             :  */
   26821             : 
   26822             :   /* function exit code */
   26823           0 :   __pyx_L1_error:;
   26824           0 :   __Pyx_XDECREF(__pyx_t_1);
   26825           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   26826           0 :     __Pyx_PyThreadState_declare
   26827           0 :     __Pyx_PyThreadState_assign
   26828           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   26829           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26830           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   26831           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26832           0 :   __pyx_r = NULL;
   26833           0 :   goto __pyx_L2;
   26834           3 :   __pyx_L0:;
   26835           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26836           3 :   __pyx_L2:;
   26837           3 :   __Pyx_XGIVEREF(__pyx_r);
   26838           3 :   __Pyx_RefNannyFinishContext();
   26839           3 :   return __pyx_r;
   26840             : }
   26841             : 
   26842             : /* Python wrapper */
   26843             : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_35get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   26844             : static PyMethodDef __pyx_fuse_2__pyx_mdef_9_ni_label_35get_read_line = {"__pyx_fuse_2get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_2__pyx_pw_9_ni_label_35get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   26845          92 : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_35get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   26846          92 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   26847          92 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   26848          92 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   26849          92 :   PyObject* values[1] = {0};
   26850          92 :   int __pyx_lineno = 0;
   26851          92 :   const char *__pyx_filename = NULL;
   26852          92 :   int __pyx_clineno = 0;
   26853          92 :   PyObject *__pyx_r = 0;
   26854             :   __Pyx_RefNannyDeclarations
   26855          92 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   26856             :   #if CYTHON_ASSUME_SAFE_MACROS
   26857          92 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   26858             :   #else
   26859             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   26860             :   #endif
   26861          92 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   26862             :   {
   26863          92 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   26864          92 :     if (__pyx_kwds) {
   26865           0 :       Py_ssize_t kw_args;
   26866           0 :       switch (__pyx_nargs) {
   26867           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26868           0 :         CYTHON_FALLTHROUGH;
   26869           0 :         case  0: break;
   26870           0 :         default: goto __pyx_L5_argtuple_error;
   26871             :       }
   26872           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   26873           0 :       switch (__pyx_nargs) {
   26874           0 :         case  0:
   26875           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   26876           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   26877           0 :           kw_args--;
   26878             :         }
   26879           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   26880           0 :         else goto __pyx_L5_argtuple_error;
   26881             :       }
   26882           0 :       if (unlikely(kw_args > 0)) {
   26883           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   26884           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   26885             :       }
   26886          92 :     } else if (unlikely(__pyx_nargs != 1)) {
   26887           0 :       goto __pyx_L5_argtuple_error;
   26888             :     } else {
   26889          92 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   26890             :     }
   26891          92 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   26892             :   }
   26893          92 :   goto __pyx_L6_skip;
   26894           0 :   __pyx_L5_argtuple_error:;
   26895           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   26896          92 :   __pyx_L6_skip:;
   26897          92 :   goto __pyx_L4_argument_unpacking_done;
   26898           0 :   __pyx_L3_error:;
   26899             :   {
   26900           0 :     Py_ssize_t __pyx_temp;
   26901           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26902             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26903             :     }
   26904             :   }
   26905           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26906           0 :   __Pyx_RefNannyFinishContext();
   26907           0 :   return NULL;
   26908          92 :   __pyx_L4_argument_unpacking_done:;
   26909          92 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   26910          92 :   __pyx_r = __pyx_pf_9_ni_label_34get_read_line(__pyx_self, __pyx_v_a);
   26911             : 
   26912             :   /* function exit code */
   26913          92 :   goto __pyx_L0;
   26914           0 :   __pyx_L1_error:;
   26915           0 :   __pyx_r = NULL;
   26916          92 :   __pyx_L0:;
   26917             :   {
   26918          92 :     Py_ssize_t __pyx_temp;
   26919          92 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   26920             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   26921             :     }
   26922             :   }
   26923             :   __Pyx_RefNannyFinishContext();
   26924             :   return __pyx_r;
   26925             : }
   26926             : 
   26927          92 : static PyObject *__pyx_pf_9_ni_label_34get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   26928          92 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   26929          92 :   __Pyx_Buffer __pyx_pybuffer_a;
   26930          92 :   PyObject *__pyx_r = NULL;
   26931             :   __Pyx_RefNannyDeclarations
   26932          92 :   PyObject *__pyx_t_1 = NULL;
   26933          92 :   int __pyx_lineno = 0;
   26934          92 :   const char *__pyx_filename = NULL;
   26935          92 :   int __pyx_clineno = 0;
   26936          92 :   __Pyx_RefNannySetupContext("__pyx_fuse_2get_read_line", 1);
   26937          92 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   26938          92 :   __pyx_pybuffer_a.refcount = 0;
   26939          92 :   __pyx_pybuffernd_a.data = NULL;
   26940          92 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   26941             :   {
   26942          92 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   26943          92 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   26944             :   }
   26945          92 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   26946             : 
   26947             :   /* "_ni_label.pyx":97
   26948             :  * 
   26949             :  * def get_read_line(np.ndarray[data_t] a):
   26950             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   26951             :  * 
   26952             :  * def get_write_line(np.ndarray[data_t] a):
   26953             :  */
   26954          92 :   __Pyx_XDECREF(__pyx_r);
   26955          92 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_2__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   26956          92 :   __Pyx_GOTREF(__pyx_t_1);
   26957          92 :   __pyx_r = __pyx_t_1;
   26958          92 :   __pyx_t_1 = 0;
   26959          92 :   goto __pyx_L0;
   26960             : 
   26961             :   /* "_ni_label.pyx":96
   26962             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   26963             :  * 
   26964             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   26965             :  *     return <Py_intptr_t> fused_read_line[data_t]
   26966             :  * 
   26967             :  */
   26968             : 
   26969             :   /* function exit code */
   26970           0 :   __pyx_L1_error:;
   26971           0 :   __Pyx_XDECREF(__pyx_t_1);
   26972           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   26973           0 :     __Pyx_PyThreadState_declare
   26974           0 :     __Pyx_PyThreadState_assign
   26975           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   26976           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26977           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   26978           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   26979           0 :   __pyx_r = NULL;
   26980           0 :   goto __pyx_L2;
   26981          92 :   __pyx_L0:;
   26982          92 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   26983          92 :   __pyx_L2:;
   26984          92 :   __Pyx_XGIVEREF(__pyx_r);
   26985          92 :   __Pyx_RefNannyFinishContext();
   26986          92 :   return __pyx_r;
   26987             : }
   26988             : 
   26989             : /* Python wrapper */
   26990             : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_37get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   26991             : static PyMethodDef __pyx_fuse_3__pyx_mdef_9_ni_label_37get_read_line = {"__pyx_fuse_3get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_3__pyx_pw_9_ni_label_37get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   26992           3 : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_37get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   26993           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   26994           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   26995           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   26996           3 :   PyObject* values[1] = {0};
   26997           3 :   int __pyx_lineno = 0;
   26998           3 :   const char *__pyx_filename = NULL;
   26999           3 :   int __pyx_clineno = 0;
   27000           3 :   PyObject *__pyx_r = 0;
   27001             :   __Pyx_RefNannyDeclarations
   27002           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27003             :   #if CYTHON_ASSUME_SAFE_MACROS
   27004           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27005             :   #else
   27006             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27007             :   #endif
   27008           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27009             :   {
   27010           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27011           3 :     if (__pyx_kwds) {
   27012           0 :       Py_ssize_t kw_args;
   27013           0 :       switch (__pyx_nargs) {
   27014           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27015           0 :         CYTHON_FALLTHROUGH;
   27016           0 :         case  0: break;
   27017           0 :         default: goto __pyx_L5_argtuple_error;
   27018             :       }
   27019           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27020           0 :       switch (__pyx_nargs) {
   27021           0 :         case  0:
   27022           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27023           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27024           0 :           kw_args--;
   27025             :         }
   27026           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27027           0 :         else goto __pyx_L5_argtuple_error;
   27028             :       }
   27029           0 :       if (unlikely(kw_args > 0)) {
   27030           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27031           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27032             :       }
   27033           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27034           0 :       goto __pyx_L5_argtuple_error;
   27035             :     } else {
   27036           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27037             :     }
   27038           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27039             :   }
   27040           3 :   goto __pyx_L6_skip;
   27041           0 :   __pyx_L5_argtuple_error:;
   27042           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27043           3 :   __pyx_L6_skip:;
   27044           3 :   goto __pyx_L4_argument_unpacking_done;
   27045           0 :   __pyx_L3_error:;
   27046             :   {
   27047           0 :     Py_ssize_t __pyx_temp;
   27048           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27049             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27050             :     }
   27051             :   }
   27052           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27053           0 :   __Pyx_RefNannyFinishContext();
   27054           0 :   return NULL;
   27055           3 :   __pyx_L4_argument_unpacking_done:;
   27056           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27057           3 :   __pyx_r = __pyx_pf_9_ni_label_36get_read_line(__pyx_self, __pyx_v_a);
   27058             : 
   27059             :   /* function exit code */
   27060           3 :   goto __pyx_L0;
   27061           0 :   __pyx_L1_error:;
   27062           0 :   __pyx_r = NULL;
   27063           3 :   __pyx_L0:;
   27064             :   {
   27065           3 :     Py_ssize_t __pyx_temp;
   27066           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27067             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27068             :     }
   27069             :   }
   27070             :   __Pyx_RefNannyFinishContext();
   27071             :   return __pyx_r;
   27072             : }
   27073             : 
   27074           3 : static PyObject *__pyx_pf_9_ni_label_36get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27075           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27076           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27077           3 :   PyObject *__pyx_r = NULL;
   27078             :   __Pyx_RefNannyDeclarations
   27079           3 :   PyObject *__pyx_t_1 = NULL;
   27080           3 :   int __pyx_lineno = 0;
   27081           3 :   const char *__pyx_filename = NULL;
   27082           3 :   int __pyx_clineno = 0;
   27083           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_3get_read_line", 1);
   27084           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27085           3 :   __pyx_pybuffer_a.refcount = 0;
   27086           3 :   __pyx_pybuffernd_a.data = NULL;
   27087           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27088             :   {
   27089           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27090           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27091             :   }
   27092           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27093             : 
   27094             :   /* "_ni_label.pyx":97
   27095             :  * 
   27096             :  * def get_read_line(np.ndarray[data_t] a):
   27097             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27098             :  * 
   27099             :  * def get_write_line(np.ndarray[data_t] a):
   27100             :  */
   27101           3 :   __Pyx_XDECREF(__pyx_r);
   27102           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_3__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27103           3 :   __Pyx_GOTREF(__pyx_t_1);
   27104           3 :   __pyx_r = __pyx_t_1;
   27105           3 :   __pyx_t_1 = 0;
   27106           3 :   goto __pyx_L0;
   27107             : 
   27108             :   /* "_ni_label.pyx":96
   27109             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27110             :  * 
   27111             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27112             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27113             :  * 
   27114             :  */
   27115             : 
   27116             :   /* function exit code */
   27117           0 :   __pyx_L1_error:;
   27118           0 :   __Pyx_XDECREF(__pyx_t_1);
   27119           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27120           0 :     __Pyx_PyThreadState_declare
   27121           0 :     __Pyx_PyThreadState_assign
   27122           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27123           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27124           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27125           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27126           0 :   __pyx_r = NULL;
   27127           0 :   goto __pyx_L2;
   27128           3 :   __pyx_L0:;
   27129           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27130           3 :   __pyx_L2:;
   27131           3 :   __Pyx_XGIVEREF(__pyx_r);
   27132           3 :   __Pyx_RefNannyFinishContext();
   27133           3 :   return __pyx_r;
   27134             : }
   27135             : 
   27136             : /* Python wrapper */
   27137             : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_39get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27138             : static PyMethodDef __pyx_fuse_4__pyx_mdef_9_ni_label_39get_read_line = {"__pyx_fuse_4get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_4__pyx_pw_9_ni_label_39get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27139           3 : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_39get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27140           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27141           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27142           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27143           3 :   PyObject* values[1] = {0};
   27144           3 :   int __pyx_lineno = 0;
   27145           3 :   const char *__pyx_filename = NULL;
   27146           3 :   int __pyx_clineno = 0;
   27147           3 :   PyObject *__pyx_r = 0;
   27148             :   __Pyx_RefNannyDeclarations
   27149           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27150             :   #if CYTHON_ASSUME_SAFE_MACROS
   27151           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27152             :   #else
   27153             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27154             :   #endif
   27155           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27156             :   {
   27157           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27158           3 :     if (__pyx_kwds) {
   27159           0 :       Py_ssize_t kw_args;
   27160           0 :       switch (__pyx_nargs) {
   27161           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27162           0 :         CYTHON_FALLTHROUGH;
   27163           0 :         case  0: break;
   27164           0 :         default: goto __pyx_L5_argtuple_error;
   27165             :       }
   27166           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27167           0 :       switch (__pyx_nargs) {
   27168           0 :         case  0:
   27169           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27170           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27171           0 :           kw_args--;
   27172             :         }
   27173           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27174           0 :         else goto __pyx_L5_argtuple_error;
   27175             :       }
   27176           0 :       if (unlikely(kw_args > 0)) {
   27177           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27178           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27179             :       }
   27180           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27181           0 :       goto __pyx_L5_argtuple_error;
   27182             :     } else {
   27183           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27184             :     }
   27185           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27186             :   }
   27187           3 :   goto __pyx_L6_skip;
   27188           0 :   __pyx_L5_argtuple_error:;
   27189           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27190           3 :   __pyx_L6_skip:;
   27191           3 :   goto __pyx_L4_argument_unpacking_done;
   27192           0 :   __pyx_L3_error:;
   27193             :   {
   27194           0 :     Py_ssize_t __pyx_temp;
   27195           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27196             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27197             :     }
   27198             :   }
   27199           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27200           0 :   __Pyx_RefNannyFinishContext();
   27201           0 :   return NULL;
   27202           3 :   __pyx_L4_argument_unpacking_done:;
   27203           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27204           3 :   __pyx_r = __pyx_pf_9_ni_label_38get_read_line(__pyx_self, __pyx_v_a);
   27205             : 
   27206             :   /* function exit code */
   27207           3 :   goto __pyx_L0;
   27208           0 :   __pyx_L1_error:;
   27209           0 :   __pyx_r = NULL;
   27210           3 :   __pyx_L0:;
   27211             :   {
   27212           3 :     Py_ssize_t __pyx_temp;
   27213           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27214             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27215             :     }
   27216             :   }
   27217             :   __Pyx_RefNannyFinishContext();
   27218             :   return __pyx_r;
   27219             : }
   27220             : 
   27221           3 : static PyObject *__pyx_pf_9_ni_label_38get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27222           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27223           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27224           3 :   PyObject *__pyx_r = NULL;
   27225             :   __Pyx_RefNannyDeclarations
   27226           3 :   PyObject *__pyx_t_1 = NULL;
   27227           3 :   int __pyx_lineno = 0;
   27228           3 :   const char *__pyx_filename = NULL;
   27229           3 :   int __pyx_clineno = 0;
   27230           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_4get_read_line", 1);
   27231           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27232           3 :   __pyx_pybuffer_a.refcount = 0;
   27233           3 :   __pyx_pybuffernd_a.data = NULL;
   27234           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27235             :   {
   27236           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27237           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27238             :   }
   27239           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27240             : 
   27241             :   /* "_ni_label.pyx":97
   27242             :  * 
   27243             :  * def get_read_line(np.ndarray[data_t] a):
   27244             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27245             :  * 
   27246             :  * def get_write_line(np.ndarray[data_t] a):
   27247             :  */
   27248           3 :   __Pyx_XDECREF(__pyx_r);
   27249           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_4__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27250           3 :   __Pyx_GOTREF(__pyx_t_1);
   27251           3 :   __pyx_r = __pyx_t_1;
   27252           3 :   __pyx_t_1 = 0;
   27253           3 :   goto __pyx_L0;
   27254             : 
   27255             :   /* "_ni_label.pyx":96
   27256             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27257             :  * 
   27258             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27259             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27260             :  * 
   27261             :  */
   27262             : 
   27263             :   /* function exit code */
   27264           0 :   __pyx_L1_error:;
   27265           0 :   __Pyx_XDECREF(__pyx_t_1);
   27266           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27267           0 :     __Pyx_PyThreadState_declare
   27268           0 :     __Pyx_PyThreadState_assign
   27269           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27270           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27271           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27272           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27273           0 :   __pyx_r = NULL;
   27274           0 :   goto __pyx_L2;
   27275           3 :   __pyx_L0:;
   27276           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27277           3 :   __pyx_L2:;
   27278           3 :   __Pyx_XGIVEREF(__pyx_r);
   27279           3 :   __Pyx_RefNannyFinishContext();
   27280           3 :   return __pyx_r;
   27281             : }
   27282             : 
   27283             : /* Python wrapper */
   27284             : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_41get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27285             : static PyMethodDef __pyx_fuse_5__pyx_mdef_9_ni_label_41get_read_line = {"__pyx_fuse_5get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_5__pyx_pw_9_ni_label_41get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27286           3 : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_41get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27287           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27288           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27289           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27290           3 :   PyObject* values[1] = {0};
   27291           3 :   int __pyx_lineno = 0;
   27292           3 :   const char *__pyx_filename = NULL;
   27293           3 :   int __pyx_clineno = 0;
   27294           3 :   PyObject *__pyx_r = 0;
   27295             :   __Pyx_RefNannyDeclarations
   27296           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27297             :   #if CYTHON_ASSUME_SAFE_MACROS
   27298           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27299             :   #else
   27300             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27301             :   #endif
   27302           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27303             :   {
   27304           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27305           3 :     if (__pyx_kwds) {
   27306           0 :       Py_ssize_t kw_args;
   27307           0 :       switch (__pyx_nargs) {
   27308           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27309           0 :         CYTHON_FALLTHROUGH;
   27310           0 :         case  0: break;
   27311           0 :         default: goto __pyx_L5_argtuple_error;
   27312             :       }
   27313           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27314           0 :       switch (__pyx_nargs) {
   27315           0 :         case  0:
   27316           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27317           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27318           0 :           kw_args--;
   27319             :         }
   27320           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27321           0 :         else goto __pyx_L5_argtuple_error;
   27322             :       }
   27323           0 :       if (unlikely(kw_args > 0)) {
   27324           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27325           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27326             :       }
   27327           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27328           0 :       goto __pyx_L5_argtuple_error;
   27329             :     } else {
   27330           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27331             :     }
   27332           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27333             :   }
   27334           3 :   goto __pyx_L6_skip;
   27335           0 :   __pyx_L5_argtuple_error:;
   27336           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27337           3 :   __pyx_L6_skip:;
   27338           3 :   goto __pyx_L4_argument_unpacking_done;
   27339           0 :   __pyx_L3_error:;
   27340             :   {
   27341           0 :     Py_ssize_t __pyx_temp;
   27342           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27343             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27344             :     }
   27345             :   }
   27346           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27347           0 :   __Pyx_RefNannyFinishContext();
   27348           0 :   return NULL;
   27349           3 :   __pyx_L4_argument_unpacking_done:;
   27350           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27351           3 :   __pyx_r = __pyx_pf_9_ni_label_40get_read_line(__pyx_self, __pyx_v_a);
   27352             : 
   27353             :   /* function exit code */
   27354           3 :   goto __pyx_L0;
   27355           0 :   __pyx_L1_error:;
   27356           0 :   __pyx_r = NULL;
   27357           3 :   __pyx_L0:;
   27358             :   {
   27359           3 :     Py_ssize_t __pyx_temp;
   27360           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27361             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27362             :     }
   27363             :   }
   27364             :   __Pyx_RefNannyFinishContext();
   27365             :   return __pyx_r;
   27366             : }
   27367             : 
   27368           3 : static PyObject *__pyx_pf_9_ni_label_40get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27369           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27370           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27371           3 :   PyObject *__pyx_r = NULL;
   27372             :   __Pyx_RefNannyDeclarations
   27373           3 :   PyObject *__pyx_t_1 = NULL;
   27374           3 :   int __pyx_lineno = 0;
   27375           3 :   const char *__pyx_filename = NULL;
   27376           3 :   int __pyx_clineno = 0;
   27377           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_5get_read_line", 1);
   27378           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27379           3 :   __pyx_pybuffer_a.refcount = 0;
   27380           3 :   __pyx_pybuffernd_a.data = NULL;
   27381           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27382             :   {
   27383           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27384           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27385             :   }
   27386           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27387             : 
   27388             :   /* "_ni_label.pyx":97
   27389             :  * 
   27390             :  * def get_read_line(np.ndarray[data_t] a):
   27391             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27392             :  * 
   27393             :  * def get_write_line(np.ndarray[data_t] a):
   27394             :  */
   27395           3 :   __Pyx_XDECREF(__pyx_r);
   27396           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_5__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27397           3 :   __Pyx_GOTREF(__pyx_t_1);
   27398           3 :   __pyx_r = __pyx_t_1;
   27399           3 :   __pyx_t_1 = 0;
   27400           3 :   goto __pyx_L0;
   27401             : 
   27402             :   /* "_ni_label.pyx":96
   27403             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27404             :  * 
   27405             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27406             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27407             :  * 
   27408             :  */
   27409             : 
   27410             :   /* function exit code */
   27411           0 :   __pyx_L1_error:;
   27412           0 :   __Pyx_XDECREF(__pyx_t_1);
   27413           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27414           0 :     __Pyx_PyThreadState_declare
   27415           0 :     __Pyx_PyThreadState_assign
   27416           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27417           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27418           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27419           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27420           0 :   __pyx_r = NULL;
   27421           0 :   goto __pyx_L2;
   27422           3 :   __pyx_L0:;
   27423           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27424           3 :   __pyx_L2:;
   27425           3 :   __Pyx_XGIVEREF(__pyx_r);
   27426           3 :   __Pyx_RefNannyFinishContext();
   27427           3 :   return __pyx_r;
   27428             : }
   27429             : 
   27430             : /* Python wrapper */
   27431             : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_43get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27432             : static PyMethodDef __pyx_fuse_6__pyx_mdef_9_ni_label_43get_read_line = {"__pyx_fuse_6get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_6__pyx_pw_9_ni_label_43get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27433           3 : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_43get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27434           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27435           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27436           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27437           3 :   PyObject* values[1] = {0};
   27438           3 :   int __pyx_lineno = 0;
   27439           3 :   const char *__pyx_filename = NULL;
   27440           3 :   int __pyx_clineno = 0;
   27441           3 :   PyObject *__pyx_r = 0;
   27442             :   __Pyx_RefNannyDeclarations
   27443           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27444             :   #if CYTHON_ASSUME_SAFE_MACROS
   27445           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27446             :   #else
   27447             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27448             :   #endif
   27449           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27450             :   {
   27451           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27452           3 :     if (__pyx_kwds) {
   27453           0 :       Py_ssize_t kw_args;
   27454           0 :       switch (__pyx_nargs) {
   27455           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27456           0 :         CYTHON_FALLTHROUGH;
   27457           0 :         case  0: break;
   27458           0 :         default: goto __pyx_L5_argtuple_error;
   27459             :       }
   27460           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27461           0 :       switch (__pyx_nargs) {
   27462           0 :         case  0:
   27463           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27464           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27465           0 :           kw_args--;
   27466             :         }
   27467           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27468           0 :         else goto __pyx_L5_argtuple_error;
   27469             :       }
   27470           0 :       if (unlikely(kw_args > 0)) {
   27471           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27472           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27473             :       }
   27474           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27475           0 :       goto __pyx_L5_argtuple_error;
   27476             :     } else {
   27477           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27478             :     }
   27479           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27480             :   }
   27481           3 :   goto __pyx_L6_skip;
   27482           0 :   __pyx_L5_argtuple_error:;
   27483           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27484           3 :   __pyx_L6_skip:;
   27485           3 :   goto __pyx_L4_argument_unpacking_done;
   27486           0 :   __pyx_L3_error:;
   27487             :   {
   27488           0 :     Py_ssize_t __pyx_temp;
   27489           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27490             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27491             :     }
   27492             :   }
   27493           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27494           0 :   __Pyx_RefNannyFinishContext();
   27495           0 :   return NULL;
   27496           3 :   __pyx_L4_argument_unpacking_done:;
   27497           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27498           3 :   __pyx_r = __pyx_pf_9_ni_label_42get_read_line(__pyx_self, __pyx_v_a);
   27499             : 
   27500             :   /* function exit code */
   27501           3 :   goto __pyx_L0;
   27502           0 :   __pyx_L1_error:;
   27503           0 :   __pyx_r = NULL;
   27504           3 :   __pyx_L0:;
   27505             :   {
   27506           3 :     Py_ssize_t __pyx_temp;
   27507           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27508             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27509             :     }
   27510             :   }
   27511             :   __Pyx_RefNannyFinishContext();
   27512             :   return __pyx_r;
   27513             : }
   27514             : 
   27515           3 : static PyObject *__pyx_pf_9_ni_label_42get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27516           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27517           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27518           3 :   PyObject *__pyx_r = NULL;
   27519             :   __Pyx_RefNannyDeclarations
   27520           3 :   PyObject *__pyx_t_1 = NULL;
   27521           3 :   int __pyx_lineno = 0;
   27522           3 :   const char *__pyx_filename = NULL;
   27523           3 :   int __pyx_clineno = 0;
   27524           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_6get_read_line", 1);
   27525           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27526           3 :   __pyx_pybuffer_a.refcount = 0;
   27527           3 :   __pyx_pybuffernd_a.data = NULL;
   27528           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27529             :   {
   27530           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27531           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27532             :   }
   27533           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27534             : 
   27535             :   /* "_ni_label.pyx":97
   27536             :  * 
   27537             :  * def get_read_line(np.ndarray[data_t] a):
   27538             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27539             :  * 
   27540             :  * def get_write_line(np.ndarray[data_t] a):
   27541             :  */
   27542           3 :   __Pyx_XDECREF(__pyx_r);
   27543           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_6__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27544           3 :   __Pyx_GOTREF(__pyx_t_1);
   27545           3 :   __pyx_r = __pyx_t_1;
   27546           3 :   __pyx_t_1 = 0;
   27547           3 :   goto __pyx_L0;
   27548             : 
   27549             :   /* "_ni_label.pyx":96
   27550             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27551             :  * 
   27552             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27553             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27554             :  * 
   27555             :  */
   27556             : 
   27557             :   /* function exit code */
   27558           0 :   __pyx_L1_error:;
   27559           0 :   __Pyx_XDECREF(__pyx_t_1);
   27560           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27561           0 :     __Pyx_PyThreadState_declare
   27562           0 :     __Pyx_PyThreadState_assign
   27563           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27564           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27565           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27566           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27567           0 :   __pyx_r = NULL;
   27568           0 :   goto __pyx_L2;
   27569           3 :   __pyx_L0:;
   27570           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27571           3 :   __pyx_L2:;
   27572           3 :   __Pyx_XGIVEREF(__pyx_r);
   27573           3 :   __Pyx_RefNannyFinishContext();
   27574           3 :   return __pyx_r;
   27575             : }
   27576             : 
   27577             : /* Python wrapper */
   27578             : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_45get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27579             : static PyMethodDef __pyx_fuse_7__pyx_mdef_9_ni_label_45get_read_line = {"__pyx_fuse_7get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_7__pyx_pw_9_ni_label_45get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27580           3 : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_45get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27581           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27582           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27583           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27584           3 :   PyObject* values[1] = {0};
   27585           3 :   int __pyx_lineno = 0;
   27586           3 :   const char *__pyx_filename = NULL;
   27587           3 :   int __pyx_clineno = 0;
   27588           3 :   PyObject *__pyx_r = 0;
   27589             :   __Pyx_RefNannyDeclarations
   27590           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27591             :   #if CYTHON_ASSUME_SAFE_MACROS
   27592           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27593             :   #else
   27594             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27595             :   #endif
   27596           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27597             :   {
   27598           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27599           3 :     if (__pyx_kwds) {
   27600           0 :       Py_ssize_t kw_args;
   27601           0 :       switch (__pyx_nargs) {
   27602           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27603           0 :         CYTHON_FALLTHROUGH;
   27604           0 :         case  0: break;
   27605           0 :         default: goto __pyx_L5_argtuple_error;
   27606             :       }
   27607           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27608           0 :       switch (__pyx_nargs) {
   27609           0 :         case  0:
   27610           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27611           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27612           0 :           kw_args--;
   27613             :         }
   27614           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27615           0 :         else goto __pyx_L5_argtuple_error;
   27616             :       }
   27617           0 :       if (unlikely(kw_args > 0)) {
   27618           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27619           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27620             :       }
   27621           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27622           0 :       goto __pyx_L5_argtuple_error;
   27623             :     } else {
   27624           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27625             :     }
   27626           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27627             :   }
   27628           3 :   goto __pyx_L6_skip;
   27629           0 :   __pyx_L5_argtuple_error:;
   27630           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27631           3 :   __pyx_L6_skip:;
   27632           3 :   goto __pyx_L4_argument_unpacking_done;
   27633           0 :   __pyx_L3_error:;
   27634             :   {
   27635           0 :     Py_ssize_t __pyx_temp;
   27636           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27637             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27638             :     }
   27639             :   }
   27640           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27641           0 :   __Pyx_RefNannyFinishContext();
   27642           0 :   return NULL;
   27643           3 :   __pyx_L4_argument_unpacking_done:;
   27644           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27645           3 :   __pyx_r = __pyx_pf_9_ni_label_44get_read_line(__pyx_self, __pyx_v_a);
   27646             : 
   27647             :   /* function exit code */
   27648           3 :   goto __pyx_L0;
   27649           0 :   __pyx_L1_error:;
   27650           0 :   __pyx_r = NULL;
   27651           3 :   __pyx_L0:;
   27652             :   {
   27653           3 :     Py_ssize_t __pyx_temp;
   27654           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27655             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27656             :     }
   27657             :   }
   27658             :   __Pyx_RefNannyFinishContext();
   27659             :   return __pyx_r;
   27660             : }
   27661             : 
   27662           3 : static PyObject *__pyx_pf_9_ni_label_44get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27663           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27664           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27665           3 :   PyObject *__pyx_r = NULL;
   27666             :   __Pyx_RefNannyDeclarations
   27667           3 :   PyObject *__pyx_t_1 = NULL;
   27668           3 :   int __pyx_lineno = 0;
   27669           3 :   const char *__pyx_filename = NULL;
   27670           3 :   int __pyx_clineno = 0;
   27671           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_7get_read_line", 1);
   27672           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27673           3 :   __pyx_pybuffer_a.refcount = 0;
   27674           3 :   __pyx_pybuffernd_a.data = NULL;
   27675           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27676             :   {
   27677           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27678           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27679             :   }
   27680           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27681             : 
   27682             :   /* "_ni_label.pyx":97
   27683             :  * 
   27684             :  * def get_read_line(np.ndarray[data_t] a):
   27685             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27686             :  * 
   27687             :  * def get_write_line(np.ndarray[data_t] a):
   27688             :  */
   27689           3 :   __Pyx_XDECREF(__pyx_r);
   27690           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_7__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27691           3 :   __Pyx_GOTREF(__pyx_t_1);
   27692           3 :   __pyx_r = __pyx_t_1;
   27693           3 :   __pyx_t_1 = 0;
   27694           3 :   goto __pyx_L0;
   27695             : 
   27696             :   /* "_ni_label.pyx":96
   27697             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27698             :  * 
   27699             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27700             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27701             :  * 
   27702             :  */
   27703             : 
   27704             :   /* function exit code */
   27705           0 :   __pyx_L1_error:;
   27706           0 :   __Pyx_XDECREF(__pyx_t_1);
   27707           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27708           0 :     __Pyx_PyThreadState_declare
   27709           0 :     __Pyx_PyThreadState_assign
   27710           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27711           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27712           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27713           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27714           0 :   __pyx_r = NULL;
   27715           0 :   goto __pyx_L2;
   27716           3 :   __pyx_L0:;
   27717           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27718           3 :   __pyx_L2:;
   27719           3 :   __Pyx_XGIVEREF(__pyx_r);
   27720           3 :   __Pyx_RefNannyFinishContext();
   27721           3 :   return __pyx_r;
   27722             : }
   27723             : 
   27724             : /* Python wrapper */
   27725             : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_47get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27726             : static PyMethodDef __pyx_fuse_8__pyx_mdef_9_ni_label_47get_read_line = {"__pyx_fuse_8get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_8__pyx_pw_9_ni_label_47get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27727           3 : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_47get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27728           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27729           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27730           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27731           3 :   PyObject* values[1] = {0};
   27732           3 :   int __pyx_lineno = 0;
   27733           3 :   const char *__pyx_filename = NULL;
   27734           3 :   int __pyx_clineno = 0;
   27735           3 :   PyObject *__pyx_r = 0;
   27736             :   __Pyx_RefNannyDeclarations
   27737           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27738             :   #if CYTHON_ASSUME_SAFE_MACROS
   27739           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27740             :   #else
   27741             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27742             :   #endif
   27743           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27744             :   {
   27745           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27746           3 :     if (__pyx_kwds) {
   27747           0 :       Py_ssize_t kw_args;
   27748           0 :       switch (__pyx_nargs) {
   27749           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27750           0 :         CYTHON_FALLTHROUGH;
   27751           0 :         case  0: break;
   27752           0 :         default: goto __pyx_L5_argtuple_error;
   27753             :       }
   27754           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27755           0 :       switch (__pyx_nargs) {
   27756           0 :         case  0:
   27757           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27758           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27759           0 :           kw_args--;
   27760             :         }
   27761           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27762           0 :         else goto __pyx_L5_argtuple_error;
   27763             :       }
   27764           0 :       if (unlikely(kw_args > 0)) {
   27765           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27766           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27767             :       }
   27768           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27769           0 :       goto __pyx_L5_argtuple_error;
   27770             :     } else {
   27771           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27772             :     }
   27773           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27774             :   }
   27775           3 :   goto __pyx_L6_skip;
   27776           0 :   __pyx_L5_argtuple_error:;
   27777           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27778           3 :   __pyx_L6_skip:;
   27779           3 :   goto __pyx_L4_argument_unpacking_done;
   27780           0 :   __pyx_L3_error:;
   27781             :   {
   27782           0 :     Py_ssize_t __pyx_temp;
   27783           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27784             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27785             :     }
   27786             :   }
   27787           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27788           0 :   __Pyx_RefNannyFinishContext();
   27789           0 :   return NULL;
   27790           3 :   __pyx_L4_argument_unpacking_done:;
   27791           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27792           3 :   __pyx_r = __pyx_pf_9_ni_label_46get_read_line(__pyx_self, __pyx_v_a);
   27793             : 
   27794             :   /* function exit code */
   27795           3 :   goto __pyx_L0;
   27796           0 :   __pyx_L1_error:;
   27797           0 :   __pyx_r = NULL;
   27798           3 :   __pyx_L0:;
   27799             :   {
   27800           3 :     Py_ssize_t __pyx_temp;
   27801           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27802             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27803             :     }
   27804             :   }
   27805             :   __Pyx_RefNannyFinishContext();
   27806             :   return __pyx_r;
   27807             : }
   27808             : 
   27809           3 : static PyObject *__pyx_pf_9_ni_label_46get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27810           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27811           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27812           3 :   PyObject *__pyx_r = NULL;
   27813             :   __Pyx_RefNannyDeclarations
   27814           3 :   PyObject *__pyx_t_1 = NULL;
   27815           3 :   int __pyx_lineno = 0;
   27816           3 :   const char *__pyx_filename = NULL;
   27817           3 :   int __pyx_clineno = 0;
   27818           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_8get_read_line", 1);
   27819           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27820           3 :   __pyx_pybuffer_a.refcount = 0;
   27821           3 :   __pyx_pybuffernd_a.data = NULL;
   27822           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27823             :   {
   27824           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27825           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27826             :   }
   27827           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27828             : 
   27829             :   /* "_ni_label.pyx":97
   27830             :  * 
   27831             :  * def get_read_line(np.ndarray[data_t] a):
   27832             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27833             :  * 
   27834             :  * def get_write_line(np.ndarray[data_t] a):
   27835             :  */
   27836           3 :   __Pyx_XDECREF(__pyx_r);
   27837           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_8__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27838           3 :   __Pyx_GOTREF(__pyx_t_1);
   27839           3 :   __pyx_r = __pyx_t_1;
   27840           3 :   __pyx_t_1 = 0;
   27841           3 :   goto __pyx_L0;
   27842             : 
   27843             :   /* "_ni_label.pyx":96
   27844             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27845             :  * 
   27846             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27847             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27848             :  * 
   27849             :  */
   27850             : 
   27851             :   /* function exit code */
   27852           0 :   __pyx_L1_error:;
   27853           0 :   __Pyx_XDECREF(__pyx_t_1);
   27854           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   27855           0 :     __Pyx_PyThreadState_declare
   27856           0 :     __Pyx_PyThreadState_assign
   27857           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   27858           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27859           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   27860           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27861           0 :   __pyx_r = NULL;
   27862           0 :   goto __pyx_L2;
   27863           3 :   __pyx_L0:;
   27864           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   27865           3 :   __pyx_L2:;
   27866           3 :   __Pyx_XGIVEREF(__pyx_r);
   27867           3 :   __Pyx_RefNannyFinishContext();
   27868           3 :   return __pyx_r;
   27869             : }
   27870             : 
   27871             : /* Python wrapper */
   27872             : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_49get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   27873             : static PyMethodDef __pyx_fuse_9__pyx_mdef_9_ni_label_49get_read_line = {"__pyx_fuse_9get_read_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_9__pyx_pw_9_ni_label_49get_read_line, METH_VARARGS|METH_KEYWORDS, 0};
   27874           3 : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_49get_read_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   27875           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   27876           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   27877           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   27878           3 :   PyObject* values[1] = {0};
   27879           3 :   int __pyx_lineno = 0;
   27880           3 :   const char *__pyx_filename = NULL;
   27881           3 :   int __pyx_clineno = 0;
   27882           3 :   PyObject *__pyx_r = 0;
   27883             :   __Pyx_RefNannyDeclarations
   27884           3 :   __Pyx_RefNannySetupContext("get_read_line (wrapper)", 0);
   27885             :   #if CYTHON_ASSUME_SAFE_MACROS
   27886           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   27887             :   #else
   27888             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   27889             :   #endif
   27890           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   27891             :   {
   27892           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   27893           3 :     if (__pyx_kwds) {
   27894           0 :       Py_ssize_t kw_args;
   27895           0 :       switch (__pyx_nargs) {
   27896           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27897           0 :         CYTHON_FALLTHROUGH;
   27898           0 :         case  0: break;
   27899           0 :         default: goto __pyx_L5_argtuple_error;
   27900             :       }
   27901           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   27902           0 :       switch (__pyx_nargs) {
   27903           0 :         case  0:
   27904           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   27905           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   27906           0 :           kw_args--;
   27907             :         }
   27908           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 96, __pyx_L3_error)
   27909           0 :         else goto __pyx_L5_argtuple_error;
   27910             :       }
   27911           0 :       if (unlikely(kw_args > 0)) {
   27912           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   27913           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_read_line") < 0)) __PYX_ERR(0, 96, __pyx_L3_error)
   27914             :       }
   27915           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   27916           0 :       goto __pyx_L5_argtuple_error;
   27917             :     } else {
   27918           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   27919             :     }
   27920           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   27921             :   }
   27922           3 :   goto __pyx_L6_skip;
   27923           0 :   __pyx_L5_argtuple_error:;
   27924           0 :   __Pyx_RaiseArgtupleInvalid("get_read_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 96, __pyx_L3_error)
   27925           3 :   __pyx_L6_skip:;
   27926           3 :   goto __pyx_L4_argument_unpacking_done;
   27927           0 :   __pyx_L3_error:;
   27928             :   {
   27929           0 :     Py_ssize_t __pyx_temp;
   27930           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27931             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27932             :     }
   27933             :   }
   27934           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   27935           0 :   __Pyx_RefNannyFinishContext();
   27936           0 :   return NULL;
   27937           3 :   __pyx_L4_argument_unpacking_done:;
   27938           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 96, __pyx_L1_error)
   27939           3 :   __pyx_r = __pyx_pf_9_ni_label_48get_read_line(__pyx_self, __pyx_v_a);
   27940             : 
   27941             :   /* function exit code */
   27942           3 :   goto __pyx_L0;
   27943           0 :   __pyx_L1_error:;
   27944           0 :   __pyx_r = NULL;
   27945           3 :   __pyx_L0:;
   27946             :   {
   27947           3 :     Py_ssize_t __pyx_temp;
   27948           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   27949             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   27950             :     }
   27951             :   }
   27952             :   __Pyx_RefNannyFinishContext();
   27953             :   return __pyx_r;
   27954             : }
   27955             : 
   27956           3 : static PyObject *__pyx_pf_9_ni_label_48get_read_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   27957           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   27958           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   27959           3 :   PyObject *__pyx_r = NULL;
   27960             :   __Pyx_RefNannyDeclarations
   27961           3 :   PyObject *__pyx_t_1 = NULL;
   27962           3 :   int __pyx_lineno = 0;
   27963           3 :   const char *__pyx_filename = NULL;
   27964           3 :   int __pyx_clineno = 0;
   27965           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_9get_read_line", 1);
   27966           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   27967           3 :   __pyx_pybuffer_a.refcount = 0;
   27968           3 :   __pyx_pybuffernd_a.data = NULL;
   27969           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   27970             :   {
   27971           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   27972           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 96, __pyx_L1_error)
   27973             :   }
   27974           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   27975             : 
   27976             :   /* "_ni_label.pyx":97
   27977             :  * 
   27978             :  * def get_read_line(np.ndarray[data_t] a):
   27979             :  *     return <Py_intptr_t> fused_read_line[data_t]             # <<<<<<<<<<<<<<
   27980             :  * 
   27981             :  * def get_write_line(np.ndarray[data_t] a):
   27982             :  */
   27983           3 :   __Pyx_XDECREF(__pyx_r);
   27984           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_9__pyx_f_9_ni_label_fused_read_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
   27985           3 :   __Pyx_GOTREF(__pyx_t_1);
   27986           3 :   __pyx_r = __pyx_t_1;
   27987           3 :   __pyx_t_1 = 0;
   27988           3 :   goto __pyx_L0;
   27989             : 
   27990             :   /* "_ni_label.pyx":96
   27991             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   27992             :  * 
   27993             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   27994             :  *     return <Py_intptr_t> fused_read_line[data_t]
   27995             :  * 
   27996             :  */
   27997             : 
   27998             :   /* function exit code */
   27999           0 :   __pyx_L1_error:;
   28000           0 :   __Pyx_XDECREF(__pyx_t_1);
   28001           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   28002           0 :     __Pyx_PyThreadState_declare
   28003           0 :     __Pyx_PyThreadState_assign
   28004           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   28005           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   28006           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   28007           0 :   __Pyx_AddTraceback("_ni_label.get_read_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   28008           0 :   __pyx_r = NULL;
   28009           0 :   goto __pyx_L2;
   28010           3 :   __pyx_L0:;
   28011           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   28012           3 :   __pyx_L2:;
   28013           3 :   __Pyx_XGIVEREF(__pyx_r);
   28014           3 :   __Pyx_RefNannyFinishContext();
   28015           3 :   return __pyx_r;
   28016             : }
   28017             : 
   28018             : /* "_ni_label.pyx":99
   28019             :  *     return <Py_intptr_t> fused_read_line[data_t]
   28020             :  * 
   28021             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   28022             :  *     return <Py_intptr_t> fused_write_line[data_t]
   28023             :  * 
   28024             :  */
   28025             : 
   28026             : /* Python wrapper */
   28027             : static PyObject *__pyx_pw_9_ni_label_5get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   28028             : static PyMethodDef __pyx_mdef_9_ni_label_5get_write_line = {"get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_9_ni_label_5get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   28029         119 : static PyObject *__pyx_pw_9_ni_label_5get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   28030         119 :   PyObject *__pyx_v_signatures = 0;
   28031         119 :   PyObject *__pyx_v_args = 0;
   28032         119 :   PyObject *__pyx_v_kwargs = 0;
   28033         119 :   CYTHON_UNUSED PyObject *__pyx_v_defaults = 0;
   28034         119 :   PyObject *__pyx_v__fused_sigindex = 0;
   28035         119 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   28036         119 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   28037         119 :   PyObject* values[5] = {0,0,0,0,0};
   28038         119 :   int __pyx_lineno = 0;
   28039         119 :   const char *__pyx_filename = NULL;
   28040         119 :   int __pyx_clineno = 0;
   28041         119 :   PyObject *__pyx_r = 0;
   28042             :   __Pyx_RefNannyDeclarations
   28043         119 :   __Pyx_RefNannySetupContext("__pyx_fused_cpdef (wrapper)", 0);
   28044             :   #if CYTHON_ASSUME_SAFE_MACROS
   28045         119 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   28046             :   #else
   28047             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   28048             :   #endif
   28049         119 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   28050             :   {
   28051         119 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_signatures,&__pyx_n_s_args,&__pyx_n_s_kwargs,&__pyx_n_s_defaults,&__pyx_n_s_fused_sigindex,0};
   28052         119 :     __pyx_defaults2 *__pyx_dynamic_args = __Pyx_CyFunction_Defaults(__pyx_defaults2, __pyx_self);
   28053         119 :     values[4] = __Pyx_Arg_NewRef_VARARGS(__pyx_dynamic_args->__pyx_arg__fused_sigindex);
   28054         119 :     if (__pyx_kwds) {
   28055           0 :       Py_ssize_t kw_args;
   28056           0 :       switch (__pyx_nargs) {
   28057           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   28058           0 :         CYTHON_FALLTHROUGH;
   28059           0 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   28060           0 :         CYTHON_FALLTHROUGH;
   28061           0 :         case  3: values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   28062           0 :         CYTHON_FALLTHROUGH;
   28063           0 :         case  2: values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   28064           0 :         CYTHON_FALLTHROUGH;
   28065           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   28066           0 :         CYTHON_FALLTHROUGH;
   28067           0 :         case  0: break;
   28068           0 :         default: goto __pyx_L5_argtuple_error;
   28069             :       }
   28070           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   28071           0 :       switch (__pyx_nargs) {
   28072           0 :         case  0:
   28073           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_signatures)) != 0)) {
   28074           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   28075           0 :           kw_args--;
   28076             :         }
   28077           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   28078           0 :         else goto __pyx_L5_argtuple_error;
   28079           0 :         CYTHON_FALLTHROUGH;
   28080             :         case  1:
   28081           0 :         if (likely((values[1] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_args)) != 0)) {
   28082           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[1]);
   28083           0 :           kw_args--;
   28084             :         }
   28085           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   28086             :         else {
   28087           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 1); __PYX_ERR(0, 99, __pyx_L3_error)
   28088             :         }
   28089           0 :         CYTHON_FALLTHROUGH;
   28090             :         case  2:
   28091           0 :         if (likely((values[2] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_kwargs)) != 0)) {
   28092           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[2]);
   28093           0 :           kw_args--;
   28094             :         }
   28095           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   28096             :         else {
   28097           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 2); __PYX_ERR(0, 99, __pyx_L3_error)
   28098             :         }
   28099           0 :         CYTHON_FALLTHROUGH;
   28100             :         case  3:
   28101           0 :         if (likely((values[3] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_defaults)) != 0)) {
   28102           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[3]);
   28103           0 :           kw_args--;
   28104             :         }
   28105           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   28106             :         else {
   28107           0 :           __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, 3); __PYX_ERR(0, 99, __pyx_L3_error)
   28108             :         }
   28109           0 :         CYTHON_FALLTHROUGH;
   28110             :         case  4:
   28111           0 :         if (kw_args > 0) {
   28112           0 :           PyObject* value = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_fused_sigindex);
   28113           0 :           if (value) { values[4] = __Pyx_Arg_NewRef_VARARGS(value); kw_args--; }
   28114           0 :           else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   28115             :         }
   28116             :       }
   28117           0 :       if (unlikely(kw_args > 0)) {
   28118           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   28119           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "__pyx_fused_cpdef") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   28120             :       }
   28121             :     } else {
   28122         119 :       switch (__pyx_nargs) {
   28123           0 :         case  5: values[4] = __Pyx_Arg_VARARGS(__pyx_args, 4);
   28124         119 :         CYTHON_FALLTHROUGH;
   28125         119 :         case  4: values[3] = __Pyx_Arg_VARARGS(__pyx_args, 3);
   28126         119 :         values[2] = __Pyx_Arg_VARARGS(__pyx_args, 2);
   28127         119 :         values[1] = __Pyx_Arg_VARARGS(__pyx_args, 1);
   28128         119 :         values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   28129         119 :         break;
   28130           0 :         default: goto __pyx_L5_argtuple_error;
   28131             :       }
   28132             :     }
   28133         119 :     __pyx_v_signatures = values[0];
   28134         119 :     __pyx_v_args = values[1];
   28135         119 :     __pyx_v_kwargs = values[2];
   28136         119 :     __pyx_v_defaults = values[3];
   28137         119 :     __pyx_v__fused_sigindex = values[4];
   28138             :   }
   28139         119 :   goto __pyx_L6_skip;
   28140           0 :   __pyx_L5_argtuple_error:;
   28141           0 :   __Pyx_RaiseArgtupleInvalid("__pyx_fused_cpdef", 0, 4, 5, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   28142         119 :   __pyx_L6_skip:;
   28143         119 :   goto __pyx_L4_argument_unpacking_done;
   28144           0 :   __pyx_L3_error:;
   28145             :   {
   28146           0 :     Py_ssize_t __pyx_temp;
   28147           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   28148             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   28149             :     }
   28150             :   }
   28151           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   28152           0 :   __Pyx_RefNannyFinishContext();
   28153           0 :   return NULL;
   28154         119 :   __pyx_L4_argument_unpacking_done:;
   28155         119 :   __pyx_r = __pyx_pf_9_ni_label_4get_write_line(__pyx_self, __pyx_v_signatures, __pyx_v_args, __pyx_v_kwargs, __pyx_v_defaults, __pyx_v__fused_sigindex);
   28156             : 
   28157             :   /* function exit code */
   28158             :   {
   28159         119 :     Py_ssize_t __pyx_temp;
   28160         119 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   28161             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   28162             :     }
   28163             :   }
   28164             :   __Pyx_RefNannyFinishContext();
   28165             :   return __pyx_r;
   28166             : }
   28167             : 
   28168         119 : static PyObject *__pyx_pf_9_ni_label_4get_write_line(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_signatures, PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs, CYTHON_UNUSED PyObject *__pyx_v_defaults, PyObject *__pyx_v__fused_sigindex) {
   28169         119 :   PyObject *__pyx_v_search_list = 0;
   28170         119 :   PyObject *__pyx_v_sigindex_node = 0;
   28171         119 :   PyObject *__pyx_v_dest_sig = NULL;
   28172         119 :   PyTypeObject *__pyx_v_ndarray = 0;
   28173         119 :   PyObject *__pyx_v_arg_as_memoryview = 0;
   28174         119 :   __Pyx_memviewslice __pyx_v_memslice;
   28175         119 :   Py_ssize_t __pyx_v_itemsize;
   28176         119 :   int __pyx_v_dtype_signed;
   28177         119 :   Py_UCS4 __pyx_v_kind;
   28178         119 :   int __pyx_v___pyx_fused_dtype_int8__t_is_signed;
   28179         119 :   int __pyx_v___pyx_fused_dtype_int16__t_is_signed;
   28180         119 :   int __pyx_v___pyx_fused_dtype_int32__t_is_signed;
   28181         119 :   int __pyx_v___pyx_fused_dtype_int64__t_is_signed;
   28182         119 :   int __pyx_v___pyx_fused_dtype_uint8__t_is_signed;
   28183         119 :   int __pyx_v___pyx_fused_dtype_uint16__t_is_signed;
   28184         119 :   int __pyx_v___pyx_fused_dtype_uint32__t_is_signed;
   28185         119 :   int __pyx_v___pyx_fused_dtype_uint64__t_is_signed;
   28186         119 :   PyObject *__pyx_v_arg = NULL;
   28187         119 :   PyObject *__pyx_v_dtype = NULL;
   28188         119 :   PyObject *__pyx_v_arg_base = NULL;
   28189         119 :   PyObject *__pyx_v_sig = NULL;
   28190         119 :   PyObject *__pyx_v_sig_series = NULL;
   28191         119 :   PyObject *__pyx_v_last_type = NULL;
   28192         119 :   PyObject *__pyx_v_sig_type = NULL;
   28193         119 :   PyObject *__pyx_v_sigindex_matches = NULL;
   28194         119 :   PyObject *__pyx_v_sigindex_candidates = NULL;
   28195         119 :   PyObject *__pyx_v_dst_type = NULL;
   28196         119 :   PyObject *__pyx_v_found_matches = NULL;
   28197         119 :   PyObject *__pyx_v_found_candidates = NULL;
   28198         119 :   PyObject *__pyx_v_sn = NULL;
   28199         119 :   PyObject *__pyx_v_type_match = NULL;
   28200         119 :   PyObject *__pyx_v_candidates = NULL;
   28201         119 :   PyObject *__pyx_r = NULL;
   28202             :   __Pyx_RefNannyDeclarations
   28203         119 :   PyObject *__pyx_t_1 = NULL;
   28204         119 :   int __pyx_t_2;
   28205         119 :   int __pyx_t_3;
   28206         119 :   int __pyx_t_4;
   28207         119 :   Py_ssize_t __pyx_t_5;
   28208         119 :   PyObject *__pyx_t_6 = NULL;
   28209         119 :   long __pyx_t_7;
   28210         119 :   PyObject *__pyx_t_8 = NULL;
   28211         119 :   PyObject *__pyx_t_9 = NULL;
   28212         119 :   PyObject *__pyx_t_10 = NULL;
   28213         119 :   int __pyx_t_11;
   28214         119 :   __Pyx_memviewslice __pyx_t_12;
   28215         119 :   PyObject *__pyx_t_13 = NULL;
   28216         119 :   Py_ssize_t __pyx_t_14;
   28217         119 :   int __pyx_t_15;
   28218         119 :   PyObject *__pyx_t_16 = NULL;
   28219         119 :   PyObject *__pyx_t_17 = NULL;
   28220         119 :   unsigned int __pyx_t_18;
   28221         119 :   Py_ssize_t __pyx_t_19;
   28222         119 :   int __pyx_t_20;
   28223         119 :   int __pyx_lineno = 0;
   28224         119 :   const char *__pyx_filename = NULL;
   28225         119 :   int __pyx_clineno = 0;
   28226         119 :   __Pyx_RefNannySetupContext("get_write_line", 0);
   28227         119 :   __Pyx_INCREF(__pyx_v_kwargs);
   28228         119 :   __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28229         119 :   __Pyx_GOTREF(__pyx_t_1);
   28230         119 :   __Pyx_INCREF(Py_None);
   28231         119 :   __Pyx_GIVEREF(Py_None);
   28232         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_1, 0, Py_None)) __PYX_ERR(0, 99, __pyx_L1_error);
   28233         119 :   __pyx_v_dest_sig = ((PyObject*)__pyx_t_1);
   28234         119 :   __pyx_t_1 = 0;
   28235         119 :   __pyx_t_3 = (__pyx_v_kwargs != Py_None);
   28236         119 :   if (__pyx_t_3) {
   28237           0 :   } else {
   28238         119 :     __pyx_t_2 = __pyx_t_3;
   28239         119 :     goto __pyx_L4_bool_binop_done;
   28240             :   }
   28241           0 :   __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_kwargs); if (unlikely((__pyx_t_3 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28242           0 :   __pyx_t_4 = (!__pyx_t_3);
   28243           0 :   __pyx_t_2 = __pyx_t_4;
   28244         119 :   __pyx_L4_bool_binop_done:;
   28245         119 :   if (__pyx_t_2) {
   28246           0 :     __Pyx_INCREF(Py_None);
   28247           0 :     __Pyx_DECREF_SET(__pyx_v_kwargs, Py_None);
   28248             :   }
   28249         119 :   __pyx_t_1 = ((PyObject *)__Pyx_ImportNumPyArrayTypeIfAvailable()); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28250         119 :   __Pyx_GOTREF(__pyx_t_1);
   28251         119 :   __pyx_v_ndarray = ((PyTypeObject*)__pyx_t_1);
   28252         119 :   __pyx_t_1 = 0;
   28253         119 :   __pyx_v_itemsize = -1L;
   28254         119 :   __pyx_v___pyx_fused_dtype_int8__t_is_signed = (!(((__pyx_t_5numpy_int8_t)-1L) > 0));
   28255         119 :   __pyx_v___pyx_fused_dtype_int16__t_is_signed = (!(((__pyx_t_5numpy_int16_t)-1L) > 0));
   28256         119 :   __pyx_v___pyx_fused_dtype_int32__t_is_signed = (!(((__pyx_t_5numpy_int32_t)-1L) > 0));
   28257         119 :   __pyx_v___pyx_fused_dtype_int64__t_is_signed = (!(((__pyx_t_5numpy_int64_t)-1L) > 0));
   28258         119 :   __pyx_v___pyx_fused_dtype_uint8__t_is_signed = (!(((__pyx_t_5numpy_uint8_t)-1L) > 0));
   28259         119 :   __pyx_v___pyx_fused_dtype_uint16__t_is_signed = (!(((__pyx_t_5numpy_uint16_t)-1L) > 0));
   28260         119 :   __pyx_v___pyx_fused_dtype_uint32__t_is_signed = (!(((__pyx_t_5numpy_uint32_t)-1L) > 0));
   28261         119 :   __pyx_v___pyx_fused_dtype_uint64__t_is_signed = (!(((__pyx_t_5numpy_uint64_t)-1L) > 0));
   28262         119 :   if (unlikely(__pyx_v_args == Py_None)) {
   28263           0 :     PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   28264           0 :     __PYX_ERR(0, 99, __pyx_L1_error)
   28265             :   }
   28266         119 :   __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   28267         119 :   __pyx_t_2 = (0 < __pyx_t_5);
   28268         119 :   if (__pyx_t_2) {
   28269         119 :     if (unlikely(__pyx_v_args == Py_None)) {
   28270             :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   28271             :       __PYX_ERR(0, 99, __pyx_L1_error)
   28272             :     }
   28273         119 :     __pyx_t_1 = __Pyx_GetItemInt_Tuple(((PyObject*)__pyx_v_args), 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28274         119 :     __Pyx_GOTREF(__pyx_t_1);
   28275         119 :     __pyx_v_arg = __pyx_t_1;
   28276         119 :     __pyx_t_1 = 0;
   28277         119 :     goto __pyx_L6;
   28278             :   }
   28279           0 :   __pyx_t_4 = (__pyx_v_kwargs != Py_None);
   28280           0 :   if (__pyx_t_4) {
   28281           0 :   } else {
   28282           0 :     __pyx_t_2 = __pyx_t_4;
   28283           0 :     goto __pyx_L7_bool_binop_done;
   28284             :   }
   28285           0 :   if (unlikely(__pyx_v_kwargs == Py_None)) {
   28286             :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   28287             :     __PYX_ERR(0, 99, __pyx_L1_error)
   28288             :   }
   28289           0 :   __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_n_s_a, ((PyObject*)__pyx_v_kwargs), Py_EQ)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28290             :   __pyx_t_2 = __pyx_t_4;
   28291           0 :   __pyx_L7_bool_binop_done:;
   28292           0 :   if (likely(__pyx_t_2)) {
   28293           0 :     if (unlikely(__pyx_v_kwargs == Py_None)) {
   28294           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   28295           0 :       __PYX_ERR(0, 99, __pyx_L1_error)
   28296             :     }
   28297           0 :     __pyx_t_1 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_kwargs), __pyx_n_s_a); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28298           0 :     __Pyx_GOTREF(__pyx_t_1);
   28299           0 :     __pyx_v_arg = __pyx_t_1;
   28300           0 :     __pyx_t_1 = 0;
   28301           0 :     goto __pyx_L6;
   28302             :   }
   28303             :   /*else*/ {
   28304           0 :     if (unlikely(__pyx_v_args == Py_None)) {
   28305             :       PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
   28306             :       __PYX_ERR(0, 99, __pyx_L1_error)
   28307             :     }
   28308           0 :     __pyx_t_5 = __Pyx_PyTuple_GET_SIZE(((PyObject*)__pyx_v_args)); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   28309           0 :     __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28310           0 :     __Pyx_GOTREF(__pyx_t_1);
   28311           0 :     __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28312           0 :     __Pyx_GOTREF(__pyx_t_6);
   28313           0 :     __Pyx_INCREF(__pyx_int_1);
   28314           0 :     __Pyx_GIVEREF(__pyx_int_1);
   28315           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_int_1)) __PYX_ERR(0, 99, __pyx_L1_error);
   28316           0 :     __Pyx_INCREF(__pyx_kp_s__11);
   28317           0 :     __Pyx_GIVEREF(__pyx_kp_s__11);
   28318           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_kp_s__11)) __PYX_ERR(0, 99, __pyx_L1_error);
   28319           0 :     __Pyx_GIVEREF(__pyx_t_1);
   28320           0 :     if (__Pyx_PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error);
   28321           0 :     __pyx_t_1 = 0;
   28322           0 :     __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_Expected_at_least_d_argument_s_g, __pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   28323           0 :     __Pyx_GOTREF(__pyx_t_1);
   28324           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28325           0 :     __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28326           0 :     __Pyx_GOTREF(__pyx_t_6);
   28327           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   28328           0 :     __Pyx_Raise(__pyx_t_6, 0, 0, 0);
   28329           0 :     __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28330           0 :     __PYX_ERR(0, 99, __pyx_L1_error)
   28331             :   }
   28332         119 :   __pyx_L6:;
   28333         119 :   while (1) {
   28334         119 :     __pyx_t_2 = (__pyx_v_ndarray != ((PyTypeObject*)Py_None));
   28335         119 :     if (__pyx_t_2) {
   28336         119 :       __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg, __pyx_v_ndarray); 
   28337         119 :       if (__pyx_t_2) {
   28338         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28339         119 :         __Pyx_GOTREF(__pyx_t_6);
   28340         119 :         __pyx_v_dtype = __pyx_t_6;
   28341         119 :         __pyx_t_6 = 0;
   28342         119 :         goto __pyx_L12;
   28343             :       }
   28344           0 :       __pyx_t_2 = __pyx_memoryview_check(__pyx_v_arg); 
   28345           0 :       if (__pyx_t_2) {
   28346           0 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_base); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28347           0 :         __Pyx_GOTREF(__pyx_t_6);
   28348           0 :         __pyx_v_arg_base = __pyx_t_6;
   28349           0 :         __pyx_t_6 = 0;
   28350           0 :         __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_arg_base, __pyx_v_ndarray); 
   28351           0 :         if (__pyx_t_2) {
   28352           0 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg_base, __pyx_n_s_dtype); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28353           0 :           __Pyx_GOTREF(__pyx_t_6);
   28354           0 :           __pyx_v_dtype = __pyx_t_6;
   28355           0 :           __pyx_t_6 = 0;
   28356           0 :           goto __pyx_L13;
   28357             :         }
   28358             :         /*else*/ {
   28359           0 :           __Pyx_INCREF(Py_None);
   28360             :           __pyx_v_dtype = Py_None;
   28361             :         }
   28362           0 :         __pyx_L13:;
   28363           0 :         goto __pyx_L12;
   28364             :       }
   28365             :       /*else*/ {
   28366           0 :         __Pyx_INCREF(Py_None);
   28367             :         __pyx_v_dtype = Py_None;
   28368             :       }
   28369         119 :       __pyx_L12:;
   28370         119 :       __pyx_v_itemsize = -1L;
   28371         119 :       __pyx_t_2 = (__pyx_v_dtype != Py_None);
   28372         119 :       if (__pyx_t_2) {
   28373         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_itemsize); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28374         119 :         __Pyx_GOTREF(__pyx_t_6);
   28375         119 :         __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28376         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28377         119 :         __pyx_v_itemsize = __pyx_t_5;
   28378         119 :         __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_dtype, __pyx_n_s_kind); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28379         119 :         __Pyx_GOTREF(__pyx_t_6);
   28380         119 :         __pyx_t_7 = __Pyx_PyObject_Ord(__pyx_t_6); if (unlikely(__pyx_t_7 == ((long)(long)(Py_UCS4)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   28381         119 :         __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28382         119 :         __pyx_v_kind = __pyx_t_7;
   28383         119 :         __pyx_v_dtype_signed = (__pyx_v_kind == 0x69);
   28384         119 :         switch (__pyx_v_kind) {
   28385         113 :           case 0x69:
   28386             :           case 0x75:
   28387         113 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int8_t)) == __pyx_v_itemsize);
   28388         113 :           if (__pyx_t_4) {
   28389           6 :           } else {
   28390         107 :             __pyx_t_2 = __pyx_t_4;
   28391         107 :             goto __pyx_L16_bool_binop_done;
   28392             :           }
   28393           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28394           6 :           __Pyx_GOTREF(__pyx_t_6);
   28395           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28396           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28397           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28398           6 :           if (__pyx_t_4) {
   28399           6 :           } else {
   28400           0 :             __pyx_t_2 = __pyx_t_4;
   28401           0 :             goto __pyx_L16_bool_binop_done;
   28402             :           }
   28403           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int8__t_is_signed ^ __pyx_v_dtype_signed));
   28404           6 :           __pyx_t_2 = __pyx_t_4;
   28405         113 :           __pyx_L16_bool_binop_done:;
   28406         113 :           if (__pyx_t_2) {
   28407           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28408           3 :             goto __pyx_L10_break;
   28409             :           }
   28410         110 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int16_t)) == __pyx_v_itemsize);
   28411         110 :           if (__pyx_t_4) {
   28412           6 :           } else {
   28413         104 :             __pyx_t_2 = __pyx_t_4;
   28414         104 :             goto __pyx_L20_bool_binop_done;
   28415             :           }
   28416           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28417           6 :           __Pyx_GOTREF(__pyx_t_6);
   28418           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28419           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28420           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28421           6 :           if (__pyx_t_4) {
   28422           6 :           } else {
   28423           0 :             __pyx_t_2 = __pyx_t_4;
   28424           0 :             goto __pyx_L20_bool_binop_done;
   28425             :           }
   28426           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int16__t_is_signed ^ __pyx_v_dtype_signed));
   28427           6 :           __pyx_t_2 = __pyx_t_4;
   28428         110 :           __pyx_L20_bool_binop_done:;
   28429         110 :           if (__pyx_t_2) {
   28430           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28431           3 :             goto __pyx_L10_break;
   28432             :           }
   28433         107 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int32_t)) == __pyx_v_itemsize);
   28434         107 :           if (__pyx_t_4) {
   28435          95 :           } else {
   28436          12 :             __pyx_t_2 = __pyx_t_4;
   28437          12 :             goto __pyx_L24_bool_binop_done;
   28438             :           }
   28439          95 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28440          95 :           __Pyx_GOTREF(__pyx_t_6);
   28441          95 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28442          95 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28443          95 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28444          95 :           if (__pyx_t_4) {
   28445          95 :           } else {
   28446           0 :             __pyx_t_2 = __pyx_t_4;
   28447           0 :             goto __pyx_L24_bool_binop_done;
   28448             :           }
   28449          95 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int32__t_is_signed ^ __pyx_v_dtype_signed));
   28450          95 :           __pyx_t_2 = __pyx_t_4;
   28451         107 :           __pyx_L24_bool_binop_done:;
   28452         107 :           if (__pyx_t_2) {
   28453          92 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28454          92 :             goto __pyx_L10_break;
   28455             :           }
   28456          15 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_int64_t)) == __pyx_v_itemsize);
   28457          15 :           if (__pyx_t_4) {
   28458           6 :           } else {
   28459           9 :             __pyx_t_2 = __pyx_t_4;
   28460           9 :             goto __pyx_L28_bool_binop_done;
   28461             :           }
   28462           6 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28463           6 :           __Pyx_GOTREF(__pyx_t_6);
   28464           6 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28465           6 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28466           6 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28467           6 :           if (__pyx_t_4) {
   28468           6 :           } else {
   28469           0 :             __pyx_t_2 = __pyx_t_4;
   28470           0 :             goto __pyx_L28_bool_binop_done;
   28471             :           }
   28472           6 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_int64__t_is_signed ^ __pyx_v_dtype_signed));
   28473           6 :           __pyx_t_2 = __pyx_t_4;
   28474          15 :           __pyx_L28_bool_binop_done:;
   28475          15 :           if (__pyx_t_2) {
   28476           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28477           3 :             goto __pyx_L10_break;
   28478             :           }
   28479          12 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint8_t)) == __pyx_v_itemsize);
   28480          12 :           if (__pyx_t_4) {
   28481           3 :           } else {
   28482           9 :             __pyx_t_2 = __pyx_t_4;
   28483           9 :             goto __pyx_L32_bool_binop_done;
   28484             :           }
   28485           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28486           3 :           __Pyx_GOTREF(__pyx_t_6);
   28487           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28488           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28489           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28490           3 :           if (__pyx_t_4) {
   28491           3 :           } else {
   28492           0 :             __pyx_t_2 = __pyx_t_4;
   28493           0 :             goto __pyx_L32_bool_binop_done;
   28494             :           }
   28495           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint8__t_is_signed ^ __pyx_v_dtype_signed));
   28496           3 :           __pyx_t_2 = __pyx_t_4;
   28497          12 :           __pyx_L32_bool_binop_done:;
   28498          12 :           if (__pyx_t_2) {
   28499           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28500           3 :             goto __pyx_L10_break;
   28501             :           }
   28502           9 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint16_t)) == __pyx_v_itemsize);
   28503           9 :           if (__pyx_t_4) {
   28504           3 :           } else {
   28505           6 :             __pyx_t_2 = __pyx_t_4;
   28506           6 :             goto __pyx_L36_bool_binop_done;
   28507             :           }
   28508           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28509           3 :           __Pyx_GOTREF(__pyx_t_6);
   28510           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28511           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28512           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28513           3 :           if (__pyx_t_4) {
   28514           3 :           } else {
   28515           0 :             __pyx_t_2 = __pyx_t_4;
   28516           0 :             goto __pyx_L36_bool_binop_done;
   28517             :           }
   28518           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint16__t_is_signed ^ __pyx_v_dtype_signed));
   28519           3 :           __pyx_t_2 = __pyx_t_4;
   28520           9 :           __pyx_L36_bool_binop_done:;
   28521           9 :           if (__pyx_t_2) {
   28522           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28523           3 :             goto __pyx_L10_break;
   28524             :           }
   28525           6 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint32_t)) == __pyx_v_itemsize);
   28526           6 :           if (__pyx_t_4) {
   28527           3 :           } else {
   28528           3 :             __pyx_t_2 = __pyx_t_4;
   28529           3 :             goto __pyx_L40_bool_binop_done;
   28530             :           }
   28531           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28532           3 :           __Pyx_GOTREF(__pyx_t_6);
   28533           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28534           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28535           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28536           3 :           if (__pyx_t_4) {
   28537           3 :           } else {
   28538           0 :             __pyx_t_2 = __pyx_t_4;
   28539           0 :             goto __pyx_L40_bool_binop_done;
   28540             :           }
   28541           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint32__t_is_signed ^ __pyx_v_dtype_signed));
   28542           3 :           __pyx_t_2 = __pyx_t_4;
   28543           6 :           __pyx_L40_bool_binop_done:;
   28544           6 :           if (__pyx_t_2) {
   28545           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28546           3 :             goto __pyx_L10_break;
   28547             :           }
   28548           3 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_uint64_t)) == __pyx_v_itemsize);
   28549           3 :           if (__pyx_t_4) {
   28550           3 :           } else {
   28551           0 :             __pyx_t_2 = __pyx_t_4;
   28552           0 :             goto __pyx_L44_bool_binop_done;
   28553             :           }
   28554           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28555           3 :           __Pyx_GOTREF(__pyx_t_6);
   28556           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28557           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28558           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28559           3 :           if (__pyx_t_4) {
   28560           3 :           } else {
   28561           0 :             __pyx_t_2 = __pyx_t_4;
   28562           0 :             goto __pyx_L44_bool_binop_done;
   28563             :           }
   28564           3 :           __pyx_t_4 = (!(__pyx_v___pyx_fused_dtype_uint64__t_is_signed ^ __pyx_v_dtype_signed));
   28565           3 :           __pyx_t_2 = __pyx_t_4;
   28566           3 :           __pyx_L44_bool_binop_done:;
   28567           3 :           if (__pyx_t_2) {
   28568           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28569           3 :             goto __pyx_L10_break;
   28570             :           }
   28571             :           break;
   28572           6 :           case 0x66:
   28573           6 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float32_t)) == __pyx_v_itemsize);
   28574           6 :           if (__pyx_t_4) {
   28575           3 :           } else {
   28576           3 :             __pyx_t_2 = __pyx_t_4;
   28577           3 :             goto __pyx_L48_bool_binop_done;
   28578             :           }
   28579           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28580           3 :           __Pyx_GOTREF(__pyx_t_6);
   28581           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28582           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28583           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28584           3 :           __pyx_t_2 = __pyx_t_4;
   28585           6 :           __pyx_L48_bool_binop_done:;
   28586           6 :           if (__pyx_t_2) {
   28587           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28588           3 :             goto __pyx_L10_break;
   28589             :           }
   28590           3 :           __pyx_t_4 = ((sizeof(__pyx_t_5numpy_float64_t)) == __pyx_v_itemsize);
   28591           3 :           if (__pyx_t_4) {
   28592           3 :           } else {
   28593           0 :             __pyx_t_2 = __pyx_t_4;
   28594           0 :             goto __pyx_L51_bool_binop_done;
   28595             :           }
   28596           3 :           __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_arg, __pyx_n_s_ndim); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   28597           3 :           __Pyx_GOTREF(__pyx_t_6);
   28598           3 :           __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_t_6); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
   28599           3 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   28600           3 :           __pyx_t_4 = (((Py_ssize_t)__pyx_t_5) == 1);
   28601           3 :           __pyx_t_2 = __pyx_t_4;
   28602           3 :           __pyx_L51_bool_binop_done:;
   28603           3 :           if (__pyx_t_2) {
   28604           3 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28605           3 :             goto __pyx_L10_break;
   28606             :           }
   28607             :           break;
   28608             :           case 99:
   28609             :           break;
   28610             :           case 79:
   28611             :           break;
   28612             :           default: break;
   28613             :         }
   28614             :       }
   28615             :     }
   28616           0 :     __pyx_t_2 = (__pyx_v_arg == Py_None);
   28617           0 :     if (__pyx_t_2) {
   28618           0 :       if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   28619           0 :       goto __pyx_L10_break;
   28620             :     }
   28621             :     {
   28622           0 :       __Pyx_PyThreadState_declare
   28623           0 :       __Pyx_PyThreadState_assign
   28624           0 :       __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10);
   28625           0 :       __Pyx_XGOTREF(__pyx_t_8);
   28626           0 :       __Pyx_XGOTREF(__pyx_t_9);
   28627           0 :       __Pyx_XGOTREF(__pyx_t_10);
   28628             :       /*try:*/ {
   28629           0 :         __pyx_t_6 = PyMemoryView_FromObject(__pyx_v_arg); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L54_error)
   28630           0 :         __Pyx_GOTREF(__pyx_t_6);
   28631           0 :         __pyx_v_arg_as_memoryview = ((PyObject*)__pyx_t_6);
   28632           0 :         __pyx_t_6 = 0;
   28633             :       }
   28634             :       /*else:*/ {
   28635           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28636           0 :         if (!__pyx_t_4) {
   28637           0 :           goto __pyx_L65_next_or;
   28638             :         } else {
   28639           0 :         }
   28640           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28641           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int8_t)));
   28642           0 :         if (!__pyx_t_4) {
   28643             :         } else {
   28644           0 :           goto __pyx_L64_next_and;
   28645             :         }
   28646           0 :         __pyx_L65_next_or:;
   28647           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int8_t)));
   28648           0 :         if (__pyx_t_4) {
   28649             :         } else {
   28650           0 :           __pyx_t_2 = __pyx_t_4;
   28651           0 :           goto __pyx_L63_bool_binop_done;
   28652             :         }
   28653           0 :         __pyx_L64_next_and:;
   28654           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28655           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28656           0 :         __pyx_t_2 = __pyx_t_4;
   28657           0 :         __pyx_L63_bool_binop_done:;
   28658           0 :         if (__pyx_t_2) {
   28659           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int8_t(__pyx_v_arg_as_memoryview, 0); 
   28660           0 :           __pyx_v_memslice = __pyx_t_12;
   28661           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28662           0 :           if (__pyx_t_2) {
   28663           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28664           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28665           0 :             goto __pyx_L59_try_break;
   28666             :           }
   28667             :           /*else*/ {
   28668           0 :             PyErr_Clear(); 
   28669             :           }
   28670             :         }
   28671           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28672           0 :         if (!__pyx_t_4) {
   28673           0 :           goto __pyx_L71_next_or;
   28674             :         } else {
   28675           0 :         }
   28676           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28677           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int16_t)));
   28678           0 :         if (!__pyx_t_4) {
   28679             :         } else {
   28680           0 :           goto __pyx_L70_next_and;
   28681             :         }
   28682           0 :         __pyx_L71_next_or:;
   28683           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int16_t)));
   28684           0 :         if (__pyx_t_4) {
   28685             :         } else {
   28686           0 :           __pyx_t_2 = __pyx_t_4;
   28687           0 :           goto __pyx_L69_bool_binop_done;
   28688             :         }
   28689           0 :         __pyx_L70_next_and:;
   28690           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28691           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28692           0 :         __pyx_t_2 = __pyx_t_4;
   28693           0 :         __pyx_L69_bool_binop_done:;
   28694           0 :         if (__pyx_t_2) {
   28695           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int16_t(__pyx_v_arg_as_memoryview, 0); 
   28696           0 :           __pyx_v_memslice = __pyx_t_12;
   28697           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28698           0 :           if (__pyx_t_2) {
   28699           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28700           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28701           0 :             goto __pyx_L59_try_break;
   28702             :           }
   28703             :           /*else*/ {
   28704           0 :             PyErr_Clear(); 
   28705             :           }
   28706             :         }
   28707           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28708           0 :         if (!__pyx_t_4) {
   28709           0 :           goto __pyx_L77_next_or;
   28710             :         } else {
   28711           0 :         }
   28712           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28713           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int32_t)));
   28714           0 :         if (!__pyx_t_4) {
   28715             :         } else {
   28716           0 :           goto __pyx_L76_next_and;
   28717             :         }
   28718           0 :         __pyx_L77_next_or:;
   28719           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int32_t)));
   28720           0 :         if (__pyx_t_4) {
   28721             :         } else {
   28722           0 :           __pyx_t_2 = __pyx_t_4;
   28723           0 :           goto __pyx_L75_bool_binop_done;
   28724             :         }
   28725           0 :         __pyx_L76_next_and:;
   28726           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28727           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28728           0 :         __pyx_t_2 = __pyx_t_4;
   28729           0 :         __pyx_L75_bool_binop_done:;
   28730           0 :         if (__pyx_t_2) {
   28731           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int32_t(__pyx_v_arg_as_memoryview, 0); 
   28732           0 :           __pyx_v_memslice = __pyx_t_12;
   28733           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28734           0 :           if (__pyx_t_2) {
   28735           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28736           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28737           0 :             goto __pyx_L59_try_break;
   28738             :           }
   28739             :           /*else*/ {
   28740           0 :             PyErr_Clear(); 
   28741             :           }
   28742             :         }
   28743           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28744           0 :         if (!__pyx_t_4) {
   28745           0 :           goto __pyx_L83_next_or;
   28746             :         } else {
   28747           0 :         }
   28748           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28749           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_int64_t)));
   28750           0 :         if (!__pyx_t_4) {
   28751             :         } else {
   28752           0 :           goto __pyx_L82_next_and;
   28753             :         }
   28754           0 :         __pyx_L83_next_or:;
   28755           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_int64_t)));
   28756           0 :         if (__pyx_t_4) {
   28757             :         } else {
   28758           0 :           __pyx_t_2 = __pyx_t_4;
   28759           0 :           goto __pyx_L81_bool_binop_done;
   28760             :         }
   28761           0 :         __pyx_L82_next_and:;
   28762           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28763           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28764           0 :         __pyx_t_2 = __pyx_t_4;
   28765           0 :         __pyx_L81_bool_binop_done:;
   28766           0 :         if (__pyx_t_2) {
   28767           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int64_t(__pyx_v_arg_as_memoryview, 0); 
   28768           0 :           __pyx_v_memslice = __pyx_t_12;
   28769           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28770           0 :           if (__pyx_t_2) {
   28771           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28772           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_int64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28773           0 :             goto __pyx_L59_try_break;
   28774             :           }
   28775             :           /*else*/ {
   28776           0 :             PyErr_Clear(); 
   28777             :           }
   28778             :         }
   28779           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28780           0 :         if (!__pyx_t_4) {
   28781           0 :           goto __pyx_L89_next_or;
   28782             :         } else {
   28783           0 :         }
   28784           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28785           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint8_t)));
   28786           0 :         if (!__pyx_t_4) {
   28787             :         } else {
   28788           0 :           goto __pyx_L88_next_and;
   28789             :         }
   28790           0 :         __pyx_L89_next_or:;
   28791           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint8_t)));
   28792           0 :         if (__pyx_t_4) {
   28793             :         } else {
   28794           0 :           __pyx_t_2 = __pyx_t_4;
   28795           0 :           goto __pyx_L87_bool_binop_done;
   28796             :         }
   28797           0 :         __pyx_L88_next_and:;
   28798           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28799           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28800           0 :         __pyx_t_2 = __pyx_t_4;
   28801           0 :         __pyx_L87_bool_binop_done:;
   28802           0 :         if (__pyx_t_2) {
   28803           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint8_t(__pyx_v_arg_as_memoryview, 0); 
   28804           0 :           __pyx_v_memslice = __pyx_t_12;
   28805           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28806           0 :           if (__pyx_t_2) {
   28807           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28808           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint8_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28809           0 :             goto __pyx_L59_try_break;
   28810             :           }
   28811             :           /*else*/ {
   28812           0 :             PyErr_Clear(); 
   28813             :           }
   28814             :         }
   28815           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28816           0 :         if (!__pyx_t_4) {
   28817           0 :           goto __pyx_L95_next_or;
   28818             :         } else {
   28819           0 :         }
   28820           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28821           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint16_t)));
   28822           0 :         if (!__pyx_t_4) {
   28823             :         } else {
   28824           0 :           goto __pyx_L94_next_and;
   28825             :         }
   28826           0 :         __pyx_L95_next_or:;
   28827           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint16_t)));
   28828           0 :         if (__pyx_t_4) {
   28829             :         } else {
   28830           0 :           __pyx_t_2 = __pyx_t_4;
   28831           0 :           goto __pyx_L93_bool_binop_done;
   28832             :         }
   28833           0 :         __pyx_L94_next_and:;
   28834           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28835           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28836           0 :         __pyx_t_2 = __pyx_t_4;
   28837           0 :         __pyx_L93_bool_binop_done:;
   28838           0 :         if (__pyx_t_2) {
   28839           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint16_t(__pyx_v_arg_as_memoryview, 0); 
   28840           0 :           __pyx_v_memslice = __pyx_t_12;
   28841           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28842           0 :           if (__pyx_t_2) {
   28843           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28844           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint16_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28845           0 :             goto __pyx_L59_try_break;
   28846             :           }
   28847             :           /*else*/ {
   28848           0 :             PyErr_Clear(); 
   28849             :           }
   28850             :         }
   28851           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28852           0 :         if (!__pyx_t_4) {
   28853           0 :           goto __pyx_L101_next_or;
   28854             :         } else {
   28855           0 :         }
   28856           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28857           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint32_t)));
   28858           0 :         if (!__pyx_t_4) {
   28859             :         } else {
   28860           0 :           goto __pyx_L100_next_and;
   28861             :         }
   28862           0 :         __pyx_L101_next_or:;
   28863           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint32_t)));
   28864           0 :         if (__pyx_t_4) {
   28865             :         } else {
   28866           0 :           __pyx_t_2 = __pyx_t_4;
   28867           0 :           goto __pyx_L99_bool_binop_done;
   28868             :         }
   28869           0 :         __pyx_L100_next_and:;
   28870           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28871           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28872           0 :         __pyx_t_2 = __pyx_t_4;
   28873           0 :         __pyx_L99_bool_binop_done:;
   28874           0 :         if (__pyx_t_2) {
   28875           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint32_t(__pyx_v_arg_as_memoryview, 0); 
   28876           0 :           __pyx_v_memslice = __pyx_t_12;
   28877           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28878           0 :           if (__pyx_t_2) {
   28879           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28880           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28881           0 :             goto __pyx_L59_try_break;
   28882             :           }
   28883             :           /*else*/ {
   28884           0 :             PyErr_Clear(); 
   28885             :           }
   28886             :         }
   28887           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28888           0 :         if (!__pyx_t_4) {
   28889           0 :           goto __pyx_L107_next_or;
   28890             :         } else {
   28891           0 :         }
   28892           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28893           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_uint64_t)));
   28894           0 :         if (!__pyx_t_4) {
   28895             :         } else {
   28896           0 :           goto __pyx_L106_next_and;
   28897             :         }
   28898           0 :         __pyx_L107_next_or:;
   28899           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_uint64_t)));
   28900           0 :         if (__pyx_t_4) {
   28901             :         } else {
   28902           0 :           __pyx_t_2 = __pyx_t_4;
   28903           0 :           goto __pyx_L105_bool_binop_done;
   28904             :         }
   28905           0 :         __pyx_L106_next_and:;
   28906           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28907           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28908           0 :         __pyx_t_2 = __pyx_t_4;
   28909           0 :         __pyx_L105_bool_binop_done:;
   28910           0 :         if (__pyx_t_2) {
   28911           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint64_t(__pyx_v_arg_as_memoryview, 0); 
   28912           0 :           __pyx_v_memslice = __pyx_t_12;
   28913           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28914           0 :           if (__pyx_t_2) {
   28915           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28916           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_uint64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28917           0 :             goto __pyx_L59_try_break;
   28918             :           }
   28919             :           /*else*/ {
   28920           0 :             PyErr_Clear(); 
   28921             :           }
   28922             :         }
   28923           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28924           0 :         if (!__pyx_t_4) {
   28925           0 :           goto __pyx_L113_next_or;
   28926             :         } else {
   28927           0 :         }
   28928           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28929           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float32_t)));
   28930           0 :         if (!__pyx_t_4) {
   28931             :         } else {
   28932           0 :           goto __pyx_L112_next_and;
   28933             :         }
   28934           0 :         __pyx_L113_next_or:;
   28935           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float32_t)));
   28936           0 :         if (__pyx_t_4) {
   28937             :         } else {
   28938           0 :           __pyx_t_2 = __pyx_t_4;
   28939           0 :           goto __pyx_L111_bool_binop_done;
   28940             :         }
   28941           0 :         __pyx_L112_next_and:;
   28942           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28943           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28944           0 :         __pyx_t_2 = __pyx_t_4;
   28945           0 :         __pyx_L111_bool_binop_done:;
   28946           0 :         if (__pyx_t_2) {
   28947           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float32_t(__pyx_v_arg_as_memoryview, 0); 
   28948           0 :           __pyx_v_memslice = __pyx_t_12;
   28949           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28950           0 :           if (__pyx_t_2) {
   28951           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28952           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float32_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28953           0 :             goto __pyx_L59_try_break;
   28954             :           }
   28955             :           /*else*/ {
   28956           0 :             PyErr_Clear(); 
   28957             :           }
   28958             :         }
   28959           0 :         __pyx_t_4 = (__pyx_v_itemsize == -1L);
   28960           0 :         if (!__pyx_t_4) {
   28961           0 :           goto __pyx_L119_next_or;
   28962             :         } else {
   28963           0 :         }
   28964           0 :         __pyx_t_5 = __Pyx_PyMemoryView_Get_itemsize(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28965           0 :         __pyx_t_4 = (__pyx_t_5 == (sizeof(__pyx_t_5numpy_float64_t)));
   28966           0 :         if (!__pyx_t_4) {
   28967             :         } else {
   28968           0 :           goto __pyx_L118_next_and;
   28969             :         }
   28970           0 :         __pyx_L119_next_or:;
   28971           0 :         __pyx_t_4 = (__pyx_v_itemsize == (sizeof(__pyx_t_5numpy_float64_t)));
   28972           0 :         if (__pyx_t_4) {
   28973             :         } else {
   28974           0 :           __pyx_t_2 = __pyx_t_4;
   28975           0 :           goto __pyx_L117_bool_binop_done;
   28976             :         }
   28977           0 :         __pyx_L118_next_and:;
   28978           0 :         __pyx_t_11 = __Pyx_PyMemoryView_Get_ndim(__pyx_v_arg_as_memoryview); if (unlikely(__pyx_t_11 == ((int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28979           0 :         __pyx_t_4 = (__pyx_t_11 == 1);
   28980           0 :         __pyx_t_2 = __pyx_t_4;
   28981           0 :         __pyx_L117_bool_binop_done:;
   28982           0 :         if (__pyx_t_2) {
   28983           0 :           __pyx_t_12 = __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float64_t(__pyx_v_arg_as_memoryview, 0); 
   28984           0 :           __pyx_v_memslice = __pyx_t_12;
   28985           0 :           __pyx_t_2 = (__pyx_v_memslice.memview != 0);
   28986           0 :           if (__pyx_t_2) {
   28987           0 :             __PYX_XCLEAR_MEMVIEW((&__pyx_v_memslice), 1); 
   28988           0 :             if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, __pyx_n_s_float64_t, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L56_except_error)
   28989           0 :             goto __pyx_L59_try_break;
   28990             :           }
   28991             :           /*else*/ {
   28992           0 :             PyErr_Clear(); 
   28993             :           }
   28994             :         }
   28995             :       }
   28996           0 :       __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   28997           0 :       __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
   28998           0 :       __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
   28999           0 :       goto __pyx_L61_try_end;
   29000           0 :       __pyx_L54_error:;
   29001           0 :       __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   29002           0 :       __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   29003           0 :       __pyx_t_11 = __Pyx_PyErr_ExceptionMatches2(__pyx_builtin_ValueError, __pyx_builtin_TypeError);
   29004           0 :       if (__pyx_t_11) {
   29005           0 :         __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29006           0 :         if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_1, &__pyx_t_13) < 0) __PYX_ERR(0, 99, __pyx_L56_except_error)
   29007           0 :         __Pyx_XGOTREF(__pyx_t_6);
   29008           0 :         __Pyx_XGOTREF(__pyx_t_1);
   29009           0 :         __Pyx_XGOTREF(__pyx_t_13);
   29010           0 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   29011           0 :         __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   29012           0 :         __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0;
   29013           0 :         goto __pyx_L55_exception_handled;
   29014             :       }
   29015           0 :       goto __pyx_L56_except_error;
   29016           0 :       __pyx_L56_except_error:;
   29017           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   29018           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   29019           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   29020           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   29021           0 :       goto __pyx_L1_error;
   29022           0 :       __pyx_L59_try_break:;
   29023           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   29024           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   29025           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   29026           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   29027           0 :       goto __pyx_L10_break;
   29028           0 :       __pyx_L55_exception_handled:;
   29029           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   29030           0 :       __Pyx_XGIVEREF(__pyx_t_9);
   29031           0 :       __Pyx_XGIVEREF(__pyx_t_10);
   29032           0 :       __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
   29033           0 :       __pyx_L61_try_end:;
   29034             :     }
   29035           0 :     if (unlikely((__Pyx_SetItemInt(__pyx_v_dest_sig, 0, Py_None, long, 1, __Pyx_PyInt_From_long, 1, 0, 1) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29036           0 :     goto __pyx_L10_break;
   29037             :   }
   29038         119 :   __pyx_L10_break:;
   29039         119 :   __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v__fused_sigindex); if (unlikely((__pyx_t_2 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29040         119 :   __pyx_t_4 = (!__pyx_t_2);
   29041         119 :   if (__pyx_t_4) {
   29042           1 :     __pyx_t_5 = 0;
   29043           1 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   29044           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   29045           0 :       __PYX_ERR(0, 99, __pyx_L1_error)
   29046             :     }
   29047           2 :     __pyx_t_1 = __Pyx_dict_iterator(((PyObject*)__pyx_v_signatures), 1, ((PyObject *)NULL), (&__pyx_t_14), (&__pyx_t_11)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29048           1 :     __Pyx_GOTREF(__pyx_t_1);
   29049           1 :     __Pyx_XDECREF(__pyx_t_13);
   29050           1 :     __pyx_t_13 = __pyx_t_1;
   29051           1 :     __pyx_t_1 = 0;
   29052          11 :     while (1) {
   29053          11 :       __pyx_t_15 = __Pyx_dict_iter_next(__pyx_t_13, __pyx_t_14, &__pyx_t_5, &__pyx_t_1, NULL, NULL, __pyx_t_11);
   29054          11 :       if (unlikely(__pyx_t_15 == 0)) break;
   29055          10 :       if (unlikely(__pyx_t_15 == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29056          10 :       __Pyx_GOTREF(__pyx_t_1);
   29057          10 :       __Pyx_XDECREF_SET(__pyx_v_sig, __pyx_t_1);
   29058          10 :       __pyx_t_1 = 0;
   29059          10 :       __pyx_t_1 = __pyx_v__fused_sigindex;
   29060          10 :       __Pyx_INCREF(__pyx_t_1);
   29061          10 :       __Pyx_XDECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_1));
   29062          10 :       __pyx_t_1 = 0;
   29063          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_sig, __pyx_n_s_strip); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29064          10 :       __Pyx_GOTREF(__pyx_t_16);
   29065          10 :       __pyx_t_17 = NULL;
   29066          10 :       __pyx_t_18 = 0;
   29067             :       #if CYTHON_UNPACK_METHODS
   29068          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   29069           0 :         __pyx_t_17 = PyMethod_GET_SELF(__pyx_t_16);
   29070           0 :         if (likely(__pyx_t_17)) {
   29071           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   29072           0 :           __Pyx_INCREF(__pyx_t_17);
   29073           0 :           __Pyx_INCREF(function);
   29074           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   29075             :           __pyx_t_18 = 1;
   29076             :         }
   29077             :       }
   29078             :       #endif
   29079             :       {
   29080          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_17, __pyx_kp_s__12};
   29081          10 :         __pyx_t_6 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   29082          10 :         __Pyx_XDECREF(__pyx_t_17); __pyx_t_17 = 0;
   29083          10 :         if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29084          10 :         __Pyx_GOTREF(__pyx_t_6);
   29085          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   29086             :       }
   29087          10 :       __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_split); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29088          10 :       __Pyx_GOTREF(__pyx_t_16);
   29089          10 :       __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   29090          10 :       __pyx_t_6 = NULL;
   29091          10 :       __pyx_t_18 = 0;
   29092             :       #if CYTHON_UNPACK_METHODS
   29093          10 :       if (likely(PyMethod_Check(__pyx_t_16))) {
   29094           0 :         __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_16);
   29095           0 :         if (likely(__pyx_t_6)) {
   29096           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16);
   29097           0 :           __Pyx_INCREF(__pyx_t_6);
   29098           0 :           __Pyx_INCREF(function);
   29099           0 :           __Pyx_DECREF_SET(__pyx_t_16, function);
   29100             :           __pyx_t_18 = 1;
   29101             :         }
   29102             :       }
   29103             :       #endif
   29104             :       {
   29105          10 :         PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_kp_s__13};
   29106          10 :         __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_16, __pyx_callargs+1-__pyx_t_18, 1+__pyx_t_18);
   29107          10 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   29108          10 :         if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29109          10 :         __Pyx_GOTREF(__pyx_t_1);
   29110          10 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   29111             :       }
   29112          20 :       __pyx_t_16 = __Pyx_PySequence_ListKeepNew(__pyx_t_1); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29113          10 :       __Pyx_GOTREF(__pyx_t_16);
   29114          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29115          10 :       __pyx_t_19 = PyList_GET_SIZE(__pyx_t_16);
   29116          10 :       if (unlikely(__pyx_t_19 < 1)) {
   29117           0 :         __Pyx_RaiseNeedMoreValuesError(0+__pyx_t_19); __PYX_ERR(0, 99, __pyx_L1_error)
   29118             :       }
   29119             :       #if CYTHON_COMPILING_IN_CPYTHON
   29120          10 :       __pyx_t_6 = PyList_GET_ITEM(__pyx_t_16, __pyx_t_19-1); 
   29121          10 :       ((PyVarObject*)__pyx_t_16)->ob_size--;
   29122             :       #else
   29123             :       __pyx_t_6 = PySequence_ITEM(__pyx_t_16, __pyx_t_19-1); 
   29124             :       #endif
   29125          10 :       __Pyx_GOTREF(__pyx_t_6);
   29126             :       #if !CYTHON_COMPILING_IN_CPYTHON
   29127             :       __pyx_t_17 = PySequence_GetSlice(__pyx_t_16, 0, __pyx_t_19-1); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 99, __pyx_L1_error)
   29128             :       __Pyx_GOTREF(__pyx_t_17);
   29129             :       __Pyx_DECREF(__pyx_t_16);
   29130             :       __pyx_t_16 = __pyx_t_17; __pyx_t_17 = NULL;
   29131             :       #else
   29132          10 :       CYTHON_UNUSED_VAR(__pyx_t_17);
   29133             :       #endif
   29134          10 :       __Pyx_XDECREF_SET(__pyx_v_sig_series, ((PyObject*)__pyx_t_16));
   29135          10 :       __pyx_t_16 = 0;
   29136          10 :       __Pyx_XDECREF_SET(__pyx_v_last_type, __pyx_t_6);
   29137          10 :       __pyx_t_6 = 0;
   29138          10 :       __pyx_t_1 = __pyx_v_sig_series; __Pyx_INCREF(__pyx_t_1);
   29139             :       __pyx_t_19 = 0;
   29140          10 :       for (;;) {
   29141             :         {
   29142          10 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   29143             :           #if !CYTHON_ASSUME_SAFE_MACROS
   29144             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29145             :           #endif
   29146          10 :           if (__pyx_t_19 >= __pyx_temp) break;
   29147             :         }
   29148             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29149           0 :         __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29150             :         #else
   29151             :         __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29152             :         __Pyx_GOTREF(__pyx_t_6);
   29153             :         #endif
   29154           0 :         __Pyx_XDECREF_SET(__pyx_v_sig_type, __pyx_t_6);
   29155           0 :         __pyx_t_6 = 0;
   29156           0 :         if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   29157           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   29158           0 :           __PYX_ERR(0, 99, __pyx_L1_error)
   29159             :         }
   29160           0 :         __pyx_t_4 = (__Pyx_PyDict_ContainsTF(__pyx_v_sig_type, __pyx_v_sigindex_node, Py_NE)); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29161           0 :         if (__pyx_t_4) {
   29162           0 :           __pyx_t_6 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29163           0 :           __Pyx_GOTREF(__pyx_t_6);
   29164           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   29165             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   29166             :             __PYX_ERR(0, 99, __pyx_L1_error)
   29167             :           }
   29168           0 :           if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_sig_type, __pyx_t_6) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29169           0 :           __Pyx_INCREF(__pyx_t_6);
   29170           0 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, __pyx_t_6);
   29171           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   29172           0 :           goto __pyx_L129;
   29173             :         }
   29174             :         /*else*/ {
   29175           0 :           if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   29176             :             PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   29177             :             __PYX_ERR(0, 99, __pyx_L1_error)
   29178             :           }
   29179           0 :           __pyx_t_6 = __Pyx_PyDict_GetItem(__pyx_v_sigindex_node, __pyx_v_sig_type); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29180           0 :           __Pyx_GOTREF(__pyx_t_6);
   29181           0 :           __pyx_t_16 = __pyx_t_6;
   29182           0 :           __Pyx_INCREF(__pyx_t_16);
   29183           0 :           __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   29184          10 :           __Pyx_DECREF_SET(__pyx_v_sigindex_node, ((PyObject*)__pyx_t_16));
   29185             :           __pyx_t_16 = 0;
   29186             :         }
   29187             :         __pyx_L129:;
   29188             :       }
   29189          10 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29190          10 :       if (unlikely(__pyx_v_sigindex_node == Py_None)) {
   29191           0 :         PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   29192           0 :         __PYX_ERR(0, 99, __pyx_L1_error)
   29193             :       }
   29194          10 :       if (unlikely((PyDict_SetItem(__pyx_v_sigindex_node, __pyx_v_last_type, __pyx_v_sig) < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29195             :     }
   29196           2 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29197             :   }
   29198         119 :   __pyx_t_13 = PyList_New(0); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 99, __pyx_L1_error)
   29199         119 :   __Pyx_GOTREF(__pyx_t_13);
   29200         119 :   __pyx_v_sigindex_matches = ((PyObject*)__pyx_t_13);
   29201         119 :   __pyx_t_13 = 0;
   29202         119 :   __pyx_t_13 = PyList_New(1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 99, __pyx_L1_error)
   29203         119 :   __Pyx_GOTREF(__pyx_t_13);
   29204         119 :   __Pyx_INCREF(__pyx_v__fused_sigindex);
   29205         119 :   __Pyx_GIVEREF(__pyx_v__fused_sigindex);
   29206         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_13, 0, __pyx_v__fused_sigindex)) __PYX_ERR(0, 99, __pyx_L1_error);
   29207         119 :   __pyx_v_sigindex_candidates = ((PyObject*)__pyx_t_13);
   29208         119 :   __pyx_t_13 = 0;
   29209         119 :   __pyx_t_13 = __pyx_v_dest_sig; __Pyx_INCREF(__pyx_t_13);
   29210             :   __pyx_t_14 = 0;
   29211         238 :   for (;;) {
   29212             :     {
   29213         238 :       Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_13);
   29214             :       #if !CYTHON_ASSUME_SAFE_MACROS
   29215             :       if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29216             :       #endif
   29217         238 :       if (__pyx_t_14 >= __pyx_temp) break;
   29218             :     }
   29219             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29220         119 :     __pyx_t_1 = PyList_GET_ITEM(__pyx_t_13, __pyx_t_14); __Pyx_INCREF(__pyx_t_1); __pyx_t_14++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29221             :     #else
   29222             :     __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_13, __pyx_t_14); __pyx_t_14++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29223             :     __Pyx_GOTREF(__pyx_t_1);
   29224             :     #endif
   29225         119 :     __Pyx_XDECREF_SET(__pyx_v_dst_type, __pyx_t_1);
   29226         119 :     __pyx_t_1 = 0;
   29227         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29228         119 :     __Pyx_GOTREF(__pyx_t_1);
   29229         119 :     __Pyx_XDECREF_SET(__pyx_v_found_matches, ((PyObject*)__pyx_t_1));
   29230         119 :     __pyx_t_1 = 0;
   29231         119 :     __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29232         119 :     __Pyx_GOTREF(__pyx_t_1);
   29233         119 :     __Pyx_XDECREF_SET(__pyx_v_found_candidates, ((PyObject*)__pyx_t_1));
   29234         119 :     __pyx_t_1 = 0;
   29235         119 :     __pyx_t_4 = (__pyx_v_dst_type == Py_None);
   29236         119 :     if (__pyx_t_4) {
   29237           0 :       __pyx_t_1 = __pyx_v_sigindex_matches; __Pyx_INCREF(__pyx_t_1);
   29238           0 :       __pyx_t_5 = 0;
   29239           0 :       for (;;) {
   29240             :         {
   29241           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   29242             :           #if !CYTHON_ASSUME_SAFE_MACROS
   29243             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29244             :           #endif
   29245           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   29246             :         }
   29247             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29248           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29249             :         #else
   29250             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29251             :         __Pyx_GOTREF(__pyx_t_16);
   29252             :         #endif
   29253           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   29254           0 :         __pyx_t_16 = 0;
   29255           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   29256           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   29257           0 :           __PYX_ERR(0, 99, __pyx_L1_error)
   29258             :         }
   29259           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29260           0 :         __Pyx_GOTREF(__pyx_t_16);
   29261           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_matches, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   29262           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   29263             :       }
   29264           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29265           0 :       __pyx_t_1 = __pyx_v_sigindex_candidates; __Pyx_INCREF(__pyx_t_1);
   29266           0 :       __pyx_t_5 = 0;
   29267           0 :       for (;;) {
   29268             :         {
   29269           0 :           Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   29270             :           #if !CYTHON_ASSUME_SAFE_MACROS
   29271             :           if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29272             :           #endif
   29273           0 :           if (__pyx_t_5 >= __pyx_temp) break;
   29274             :         }
   29275             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29276           0 :         __pyx_t_16 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_16); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29277             :         #else
   29278             :         __pyx_t_16 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29279             :         __Pyx_GOTREF(__pyx_t_16);
   29280             :         #endif
   29281           0 :         __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_16);
   29282           0 :         __pyx_t_16 = 0;
   29283           0 :         if (unlikely(__pyx_v_sn == Py_None)) {
   29284           0 :           PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "values");
   29285           0 :           __PYX_ERR(0, 99, __pyx_L1_error)
   29286             :         }
   29287           0 :         __pyx_t_16 = __Pyx_PyDict_Values(((PyObject*)__pyx_v_sn)); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29288           0 :         __Pyx_GOTREF(__pyx_t_16);
   29289           0 :         __pyx_t_20 = __Pyx_PyList_Extend(__pyx_v_found_candidates, __pyx_t_16); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   29290           0 :         __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   29291             :       }
   29292           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29293           0 :       goto __pyx_L133;
   29294             :     }
   29295             :     /*else*/ {
   29296         119 :       __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29297         119 :       __Pyx_GOTREF(__pyx_t_1);
   29298         119 :       __Pyx_INCREF(__pyx_v_sigindex_matches);
   29299         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_matches);
   29300         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_sigindex_matches)) __PYX_ERR(0, 99, __pyx_L1_error);
   29301         119 :       __Pyx_INCREF(__pyx_v_sigindex_candidates);
   29302         119 :       __Pyx_GIVEREF(__pyx_v_sigindex_candidates);
   29303         119 :       if (__Pyx_PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_sigindex_candidates)) __PYX_ERR(0, 99, __pyx_L1_error);
   29304         119 :       __pyx_t_16 = __pyx_t_1; __Pyx_INCREF(__pyx_t_16);
   29305         119 :       __pyx_t_5 = 0;
   29306         238 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29307         595 :       for (;;) {
   29308         357 :         if (__pyx_t_5 >= 2) break;
   29309             :         #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29310         238 :         __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_16, __pyx_t_5); __Pyx_INCREF(__pyx_t_1); __pyx_t_5++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29311             :         #else
   29312             :         __pyx_t_1 = __Pyx_PySequence_ITEM(__pyx_t_16, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29313             :         __Pyx_GOTREF(__pyx_t_1);
   29314             :         #endif
   29315         238 :         __Pyx_XDECREF_SET(__pyx_v_search_list, ((PyObject*)__pyx_t_1));
   29316         238 :         __pyx_t_1 = 0;
   29317         238 :         if (unlikely(__pyx_v_search_list == Py_None)) {
   29318           0 :           PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   29319           0 :           __PYX_ERR(0, 99, __pyx_L1_error)
   29320             :         }
   29321         238 :         __pyx_t_1 = __pyx_v_search_list; __Pyx_INCREF(__pyx_t_1);
   29322             :         __pyx_t_19 = 0;
   29323         357 :         for (;;) {
   29324             :           {
   29325         357 :             Py_ssize_t __pyx_temp = __Pyx_PyList_GET_SIZE(__pyx_t_1);
   29326             :             #if !CYTHON_ASSUME_SAFE_MACROS
   29327             :             if (unlikely((__pyx_temp < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29328             :             #endif
   29329         357 :             if (__pyx_t_19 >= __pyx_temp) break;
   29330             :           }
   29331             :           #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   29332         119 :           __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_19); __Pyx_INCREF(__pyx_t_6); __pyx_t_19++; if (unlikely((0 < 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29333             :           #else
   29334             :           __pyx_t_6 = __Pyx_PySequence_ITEM(__pyx_t_1, __pyx_t_19); __pyx_t_19++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29335             :           __Pyx_GOTREF(__pyx_t_6);
   29336             :           #endif
   29337         119 :           __Pyx_XDECREF_SET(__pyx_v_sn, __pyx_t_6);
   29338         119 :           __pyx_t_6 = 0;
   29339         119 :           if (unlikely(__pyx_v_sn == Py_None)) {
   29340           0 :             PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "get");
   29341           0 :             __PYX_ERR(0, 99, __pyx_L1_error)
   29342             :           }
   29343         119 :           __pyx_t_6 = __Pyx_PyDict_GetItemDefault(((PyObject*)__pyx_v_sn), __pyx_v_dst_type, Py_None); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 99, __pyx_L1_error)
   29344         119 :           __Pyx_GOTREF(__pyx_t_6);
   29345         119 :           __Pyx_XDECREF_SET(__pyx_v_type_match, __pyx_t_6);
   29346         119 :           __pyx_t_6 = 0;
   29347         119 :           __pyx_t_4 = (__pyx_v_type_match != Py_None);
   29348         119 :           if (__pyx_t_4) {
   29349         119 :             __pyx_t_20 = __Pyx_PyList_Append(__pyx_v_found_matches, __pyx_v_type_match); if (unlikely(__pyx_t_20 == ((int)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   29350             :           }
   29351             :         }
   29352         476 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   29353             :       }
   29354         119 :       __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
   29355             :     }
   29356         119 :     __pyx_L133:;
   29357         119 :     __Pyx_INCREF(__pyx_v_found_matches);
   29358         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_matches, __pyx_v_found_matches);
   29359         119 :     __Pyx_INCREF(__pyx_v_found_candidates);
   29360         119 :     __Pyx_DECREF_SET(__pyx_v_sigindex_candidates, __pyx_v_found_candidates);
   29361         119 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_matches) != 0);
   29362         119 :     if (!__pyx_t_2) {
   29363           0 :     } else {
   29364         119 :       __pyx_t_4 = __pyx_t_2;
   29365         119 :       goto __pyx_L148_bool_binop_done;
   29366             :     }
   29367           0 :     __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_found_candidates) != 0);
   29368           0 :     __pyx_t_4 = __pyx_t_2;
   29369         119 :     __pyx_L148_bool_binop_done:;
   29370         119 :     __pyx_t_2 = (!__pyx_t_4);
   29371         119 :     if (__pyx_t_2) {
   29372           0 :       goto __pyx_L132_break;
   29373             :     }
   29374             :   }
   29375         119 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29376         119 :   goto __pyx_L150_for_end;
   29377           0 :   __pyx_L132_break:;
   29378           0 :   __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29379           0 :   goto __pyx_L150_for_end;
   29380         119 :   __pyx_L150_for_end:;
   29381         119 :   __Pyx_INCREF(__pyx_v_sigindex_matches);
   29382         119 :   __pyx_v_candidates = __pyx_v_sigindex_matches;
   29383         119 :   __pyx_t_2 = (PyList_GET_SIZE(__pyx_v_candidates) != 0);
   29384         119 :   __pyx_t_4 = (!__pyx_t_2);
   29385         119 :   if (unlikely(__pyx_t_4)) {
   29386           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__14, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 99, __pyx_L1_error)
   29387           0 :     __Pyx_GOTREF(__pyx_t_13);
   29388           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   29389           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29390           0 :     __PYX_ERR(0, 99, __pyx_L1_error)
   29391             :   }
   29392         119 :   __pyx_t_14 = __Pyx_PyList_GET_SIZE(__pyx_v_candidates); if (unlikely(__pyx_t_14 == ((Py_ssize_t)-1))) __PYX_ERR(0, 99, __pyx_L1_error)
   29393         119 :   __pyx_t_4 = (__pyx_t_14 > 1);
   29394         119 :   if (unlikely(__pyx_t_4)) {
   29395           0 :     __pyx_t_13 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__15, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 99, __pyx_L1_error)
   29396           0 :     __Pyx_GOTREF(__pyx_t_13);
   29397           0 :     __Pyx_Raise(__pyx_t_13, 0, 0, 0);
   29398           0 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29399           0 :     __PYX_ERR(0, 99, __pyx_L1_error)
   29400             :   }
   29401             :   /*else*/ {
   29402         119 :     __Pyx_XDECREF(__pyx_r);
   29403         119 :     if (unlikely(__pyx_v_signatures == Py_None)) {
   29404           0 :       PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
   29405           0 :       __PYX_ERR(0, 99, __pyx_L1_error)
   29406             :     }
   29407         119 :     __pyx_t_13 = __Pyx_GetItemInt_List(__pyx_v_candidates, 0, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 99, __pyx_L1_error)
   29408         119 :     __Pyx_GOTREF(__pyx_t_13);
   29409         119 :     __pyx_t_16 = __Pyx_PyDict_GetItem(((PyObject*)__pyx_v_signatures), __pyx_t_13); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 99, __pyx_L1_error)
   29410         119 :     __Pyx_GOTREF(__pyx_t_16);
   29411         119 :     __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
   29412         119 :     __pyx_r = __pyx_t_16;
   29413         119 :     __pyx_t_16 = 0;
   29414         119 :     goto __pyx_L0;
   29415             :   }
   29416             : 
   29417             :   /* function exit code */
   29418           0 :   __pyx_L1_error:;
   29419           0 :   __Pyx_XDECREF(__pyx_t_1);
   29420           0 :   __Pyx_XDECREF(__pyx_t_6);
   29421           0 :   __Pyx_XDECREF(__pyx_t_13);
   29422           0 :   __Pyx_XDECREF(__pyx_t_16);
   29423           0 :   __Pyx_XDECREF(__pyx_t_17);
   29424           0 :   __Pyx_AddTraceback("_ni_label.__pyx_fused_cpdef", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29425           0 :   __pyx_r = NULL;
   29426         119 :   __pyx_L0:;
   29427         119 :   __Pyx_XDECREF(__pyx_v_search_list);
   29428         119 :   __Pyx_XDECREF(__pyx_v_sigindex_node);
   29429         119 :   __Pyx_XDECREF(__pyx_v_dest_sig);
   29430         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_ndarray);
   29431         119 :   __Pyx_XDECREF(__pyx_v_arg_as_memoryview);
   29432         119 :   __Pyx_XDECREF(__pyx_v_arg);
   29433         119 :   __Pyx_XDECREF(__pyx_v_dtype);
   29434         119 :   __Pyx_XDECREF(__pyx_v_arg_base);
   29435         119 :   __Pyx_XDECREF(__pyx_v_sig);
   29436         119 :   __Pyx_XDECREF(__pyx_v_sig_series);
   29437         119 :   __Pyx_XDECREF(__pyx_v_last_type);
   29438         119 :   __Pyx_XDECREF(__pyx_v_sig_type);
   29439         119 :   __Pyx_XDECREF(__pyx_v_sigindex_matches);
   29440         119 :   __Pyx_XDECREF(__pyx_v_sigindex_candidates);
   29441         119 :   __Pyx_XDECREF(__pyx_v_dst_type);
   29442         119 :   __Pyx_XDECREF(__pyx_v_found_matches);
   29443         119 :   __Pyx_XDECREF(__pyx_v_found_candidates);
   29444         119 :   __Pyx_XDECREF(__pyx_v_sn);
   29445         119 :   __Pyx_XDECREF(__pyx_v_type_match);
   29446         119 :   __Pyx_XDECREF(__pyx_v_candidates);
   29447         119 :   __Pyx_XDECREF(__pyx_v_kwargs);
   29448         119 :   __Pyx_XGIVEREF(__pyx_r);
   29449         119 :   __Pyx_RefNannyFinishContext();
   29450         119 :   return __pyx_r;
   29451             : }
   29452             : 
   29453             : /* Python wrapper */
   29454             : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_53get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   29455             : static PyMethodDef __pyx_fuse_0__pyx_mdef_9_ni_label_53get_write_line = {"__pyx_fuse_0get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_0__pyx_pw_9_ni_label_53get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   29456           3 : static PyObject *__pyx_fuse_0__pyx_pw_9_ni_label_53get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   29457           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   29458           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   29459           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   29460           3 :   PyObject* values[1] = {0};
   29461           3 :   int __pyx_lineno = 0;
   29462           3 :   const char *__pyx_filename = NULL;
   29463           3 :   int __pyx_clineno = 0;
   29464           3 :   PyObject *__pyx_r = 0;
   29465             :   __Pyx_RefNannyDeclarations
   29466           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   29467             :   #if CYTHON_ASSUME_SAFE_MACROS
   29468           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   29469             :   #else
   29470             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   29471             :   #endif
   29472           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   29473             :   {
   29474           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   29475           3 :     if (__pyx_kwds) {
   29476           0 :       Py_ssize_t kw_args;
   29477           0 :       switch (__pyx_nargs) {
   29478           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29479           0 :         CYTHON_FALLTHROUGH;
   29480           0 :         case  0: break;
   29481           0 :         default: goto __pyx_L5_argtuple_error;
   29482             :       }
   29483           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   29484           0 :       switch (__pyx_nargs) {
   29485           0 :         case  0:
   29486           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   29487           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   29488           0 :           kw_args--;
   29489             :         }
   29490           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   29491           0 :         else goto __pyx_L5_argtuple_error;
   29492             :       }
   29493           0 :       if (unlikely(kw_args > 0)) {
   29494           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   29495           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   29496             :       }
   29497           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   29498           0 :       goto __pyx_L5_argtuple_error;
   29499             :     } else {
   29500           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29501             :     }
   29502           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   29503             :   }
   29504           3 :   goto __pyx_L6_skip;
   29505           0 :   __pyx_L5_argtuple_error:;
   29506           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   29507           3 :   __pyx_L6_skip:;
   29508           3 :   goto __pyx_L4_argument_unpacking_done;
   29509           0 :   __pyx_L3_error:;
   29510             :   {
   29511           0 :     Py_ssize_t __pyx_temp;
   29512           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29513             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29514             :     }
   29515             :   }
   29516           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29517           0 :   __Pyx_RefNannyFinishContext();
   29518           0 :   return NULL;
   29519           3 :   __pyx_L4_argument_unpacking_done:;
   29520           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29521           3 :   __pyx_r = __pyx_pf_9_ni_label_52get_write_line(__pyx_self, __pyx_v_a);
   29522             : 
   29523             :   /* function exit code */
   29524           3 :   goto __pyx_L0;
   29525           0 :   __pyx_L1_error:;
   29526           0 :   __pyx_r = NULL;
   29527           3 :   __pyx_L0:;
   29528             :   {
   29529           3 :     Py_ssize_t __pyx_temp;
   29530           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29531             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29532             :     }
   29533             :   }
   29534             :   __Pyx_RefNannyFinishContext();
   29535             :   return __pyx_r;
   29536             : }
   29537             : 
   29538           3 : static PyObject *__pyx_pf_9_ni_label_52get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   29539           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   29540           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   29541           3 :   PyObject *__pyx_r = NULL;
   29542             :   __Pyx_RefNannyDeclarations
   29543           3 :   PyObject *__pyx_t_1 = NULL;
   29544           3 :   int __pyx_lineno = 0;
   29545           3 :   const char *__pyx_filename = NULL;
   29546           3 :   int __pyx_clineno = 0;
   29547           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_0get_write_line", 1);
   29548           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   29549           3 :   __pyx_pybuffer_a.refcount = 0;
   29550           3 :   __pyx_pybuffernd_a.data = NULL;
   29551           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   29552             :   {
   29553           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   29554           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29555             :   }
   29556           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   29557             : 
   29558             :   /* "_ni_label.pyx":100
   29559             :  * 
   29560             :  * def get_write_line(np.ndarray[data_t] a):
   29561             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   29562             :  * 
   29563             :  * 
   29564             :  */
   29565           3 :   __Pyx_XDECREF(__pyx_r);
   29566           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_0__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   29567           3 :   __Pyx_GOTREF(__pyx_t_1);
   29568           3 :   __pyx_r = __pyx_t_1;
   29569           3 :   __pyx_t_1 = 0;
   29570           3 :   goto __pyx_L0;
   29571             : 
   29572             :   /* "_ni_label.pyx":99
   29573             :  *     return <Py_intptr_t> fused_read_line[data_t]
   29574             :  * 
   29575             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   29576             :  *     return <Py_intptr_t> fused_write_line[data_t]
   29577             :  * 
   29578             :  */
   29579             : 
   29580             :   /* function exit code */
   29581           0 :   __pyx_L1_error:;
   29582           0 :   __Pyx_XDECREF(__pyx_t_1);
   29583           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   29584           0 :     __Pyx_PyThreadState_declare
   29585           0 :     __Pyx_PyThreadState_assign
   29586           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   29587           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29588           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   29589           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29590           0 :   __pyx_r = NULL;
   29591           0 :   goto __pyx_L2;
   29592           3 :   __pyx_L0:;
   29593           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29594           3 :   __pyx_L2:;
   29595           3 :   __Pyx_XGIVEREF(__pyx_r);
   29596           3 :   __Pyx_RefNannyFinishContext();
   29597           3 :   return __pyx_r;
   29598             : }
   29599             : 
   29600             : /* Python wrapper */
   29601             : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_55get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   29602             : static PyMethodDef __pyx_fuse_1__pyx_mdef_9_ni_label_55get_write_line = {"__pyx_fuse_1get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_1__pyx_pw_9_ni_label_55get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   29603           3 : static PyObject *__pyx_fuse_1__pyx_pw_9_ni_label_55get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   29604           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   29605           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   29606           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   29607           3 :   PyObject* values[1] = {0};
   29608           3 :   int __pyx_lineno = 0;
   29609           3 :   const char *__pyx_filename = NULL;
   29610           3 :   int __pyx_clineno = 0;
   29611           3 :   PyObject *__pyx_r = 0;
   29612             :   __Pyx_RefNannyDeclarations
   29613           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   29614             :   #if CYTHON_ASSUME_SAFE_MACROS
   29615           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   29616             :   #else
   29617             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   29618             :   #endif
   29619           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   29620             :   {
   29621           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   29622           3 :     if (__pyx_kwds) {
   29623           0 :       Py_ssize_t kw_args;
   29624           0 :       switch (__pyx_nargs) {
   29625           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29626           0 :         CYTHON_FALLTHROUGH;
   29627           0 :         case  0: break;
   29628           0 :         default: goto __pyx_L5_argtuple_error;
   29629             :       }
   29630           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   29631           0 :       switch (__pyx_nargs) {
   29632           0 :         case  0:
   29633           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   29634           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   29635           0 :           kw_args--;
   29636             :         }
   29637           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   29638           0 :         else goto __pyx_L5_argtuple_error;
   29639             :       }
   29640           0 :       if (unlikely(kw_args > 0)) {
   29641           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   29642           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   29643             :       }
   29644           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   29645           0 :       goto __pyx_L5_argtuple_error;
   29646             :     } else {
   29647           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29648             :     }
   29649           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   29650             :   }
   29651           3 :   goto __pyx_L6_skip;
   29652           0 :   __pyx_L5_argtuple_error:;
   29653           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   29654           3 :   __pyx_L6_skip:;
   29655           3 :   goto __pyx_L4_argument_unpacking_done;
   29656           0 :   __pyx_L3_error:;
   29657             :   {
   29658           0 :     Py_ssize_t __pyx_temp;
   29659           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29660             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29661             :     }
   29662             :   }
   29663           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29664           0 :   __Pyx_RefNannyFinishContext();
   29665           0 :   return NULL;
   29666           3 :   __pyx_L4_argument_unpacking_done:;
   29667           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29668           3 :   __pyx_r = __pyx_pf_9_ni_label_54get_write_line(__pyx_self, __pyx_v_a);
   29669             : 
   29670             :   /* function exit code */
   29671           3 :   goto __pyx_L0;
   29672           0 :   __pyx_L1_error:;
   29673           0 :   __pyx_r = NULL;
   29674           3 :   __pyx_L0:;
   29675             :   {
   29676           3 :     Py_ssize_t __pyx_temp;
   29677           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29678             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29679             :     }
   29680             :   }
   29681             :   __Pyx_RefNannyFinishContext();
   29682             :   return __pyx_r;
   29683             : }
   29684             : 
   29685           3 : static PyObject *__pyx_pf_9_ni_label_54get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   29686           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   29687           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   29688           3 :   PyObject *__pyx_r = NULL;
   29689             :   __Pyx_RefNannyDeclarations
   29690           3 :   PyObject *__pyx_t_1 = NULL;
   29691           3 :   int __pyx_lineno = 0;
   29692           3 :   const char *__pyx_filename = NULL;
   29693           3 :   int __pyx_clineno = 0;
   29694           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_1get_write_line", 1);
   29695           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   29696           3 :   __pyx_pybuffer_a.refcount = 0;
   29697           3 :   __pyx_pybuffernd_a.data = NULL;
   29698           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   29699             :   {
   29700           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   29701           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29702             :   }
   29703           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   29704             : 
   29705             :   /* "_ni_label.pyx":100
   29706             :  * 
   29707             :  * def get_write_line(np.ndarray[data_t] a):
   29708             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   29709             :  * 
   29710             :  * 
   29711             :  */
   29712           3 :   __Pyx_XDECREF(__pyx_r);
   29713           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_1__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   29714           3 :   __Pyx_GOTREF(__pyx_t_1);
   29715           3 :   __pyx_r = __pyx_t_1;
   29716           3 :   __pyx_t_1 = 0;
   29717           3 :   goto __pyx_L0;
   29718             : 
   29719             :   /* "_ni_label.pyx":99
   29720             :  *     return <Py_intptr_t> fused_read_line[data_t]
   29721             :  * 
   29722             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   29723             :  *     return <Py_intptr_t> fused_write_line[data_t]
   29724             :  * 
   29725             :  */
   29726             : 
   29727             :   /* function exit code */
   29728           0 :   __pyx_L1_error:;
   29729           0 :   __Pyx_XDECREF(__pyx_t_1);
   29730           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   29731           0 :     __Pyx_PyThreadState_declare
   29732           0 :     __Pyx_PyThreadState_assign
   29733           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   29734           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29735           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   29736           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29737           0 :   __pyx_r = NULL;
   29738           0 :   goto __pyx_L2;
   29739           3 :   __pyx_L0:;
   29740           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29741           3 :   __pyx_L2:;
   29742           3 :   __Pyx_XGIVEREF(__pyx_r);
   29743           3 :   __Pyx_RefNannyFinishContext();
   29744           3 :   return __pyx_r;
   29745             : }
   29746             : 
   29747             : /* Python wrapper */
   29748             : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_57get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   29749             : static PyMethodDef __pyx_fuse_2__pyx_mdef_9_ni_label_57get_write_line = {"__pyx_fuse_2get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_2__pyx_pw_9_ni_label_57get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   29750          92 : static PyObject *__pyx_fuse_2__pyx_pw_9_ni_label_57get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   29751          92 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   29752          92 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   29753          92 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   29754          92 :   PyObject* values[1] = {0};
   29755          92 :   int __pyx_lineno = 0;
   29756          92 :   const char *__pyx_filename = NULL;
   29757          92 :   int __pyx_clineno = 0;
   29758          92 :   PyObject *__pyx_r = 0;
   29759             :   __Pyx_RefNannyDeclarations
   29760          92 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   29761             :   #if CYTHON_ASSUME_SAFE_MACROS
   29762          92 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   29763             :   #else
   29764             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   29765             :   #endif
   29766          92 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   29767             :   {
   29768          92 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   29769          92 :     if (__pyx_kwds) {
   29770           0 :       Py_ssize_t kw_args;
   29771           0 :       switch (__pyx_nargs) {
   29772           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29773           0 :         CYTHON_FALLTHROUGH;
   29774           0 :         case  0: break;
   29775           0 :         default: goto __pyx_L5_argtuple_error;
   29776             :       }
   29777           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   29778           0 :       switch (__pyx_nargs) {
   29779           0 :         case  0:
   29780           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   29781           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   29782           0 :           kw_args--;
   29783             :         }
   29784           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   29785           0 :         else goto __pyx_L5_argtuple_error;
   29786             :       }
   29787           0 :       if (unlikely(kw_args > 0)) {
   29788           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   29789           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   29790             :       }
   29791          92 :     } else if (unlikely(__pyx_nargs != 1)) {
   29792           0 :       goto __pyx_L5_argtuple_error;
   29793             :     } else {
   29794          92 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29795             :     }
   29796          92 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   29797             :   }
   29798          92 :   goto __pyx_L6_skip;
   29799           0 :   __pyx_L5_argtuple_error:;
   29800           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   29801          92 :   __pyx_L6_skip:;
   29802          92 :   goto __pyx_L4_argument_unpacking_done;
   29803           0 :   __pyx_L3_error:;
   29804             :   {
   29805           0 :     Py_ssize_t __pyx_temp;
   29806           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29807             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29808             :     }
   29809             :   }
   29810           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29811           0 :   __Pyx_RefNannyFinishContext();
   29812           0 :   return NULL;
   29813          92 :   __pyx_L4_argument_unpacking_done:;
   29814          92 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29815          92 :   __pyx_r = __pyx_pf_9_ni_label_56get_write_line(__pyx_self, __pyx_v_a);
   29816             : 
   29817             :   /* function exit code */
   29818          92 :   goto __pyx_L0;
   29819           0 :   __pyx_L1_error:;
   29820           0 :   __pyx_r = NULL;
   29821          92 :   __pyx_L0:;
   29822             :   {
   29823          92 :     Py_ssize_t __pyx_temp;
   29824          92 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29825             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29826             :     }
   29827             :   }
   29828             :   __Pyx_RefNannyFinishContext();
   29829             :   return __pyx_r;
   29830             : }
   29831             : 
   29832          92 : static PyObject *__pyx_pf_9_ni_label_56get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   29833          92 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   29834          92 :   __Pyx_Buffer __pyx_pybuffer_a;
   29835          92 :   PyObject *__pyx_r = NULL;
   29836             :   __Pyx_RefNannyDeclarations
   29837          92 :   PyObject *__pyx_t_1 = NULL;
   29838          92 :   int __pyx_lineno = 0;
   29839          92 :   const char *__pyx_filename = NULL;
   29840          92 :   int __pyx_clineno = 0;
   29841          92 :   __Pyx_RefNannySetupContext("__pyx_fuse_2get_write_line", 1);
   29842          92 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   29843          92 :   __pyx_pybuffer_a.refcount = 0;
   29844          92 :   __pyx_pybuffernd_a.data = NULL;
   29845          92 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   29846             :   {
   29847          92 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   29848          92 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29849             :   }
   29850          92 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   29851             : 
   29852             :   /* "_ni_label.pyx":100
   29853             :  * 
   29854             :  * def get_write_line(np.ndarray[data_t] a):
   29855             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   29856             :  * 
   29857             :  * 
   29858             :  */
   29859          92 :   __Pyx_XDECREF(__pyx_r);
   29860          92 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_2__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   29861          92 :   __Pyx_GOTREF(__pyx_t_1);
   29862          92 :   __pyx_r = __pyx_t_1;
   29863          92 :   __pyx_t_1 = 0;
   29864          92 :   goto __pyx_L0;
   29865             : 
   29866             :   /* "_ni_label.pyx":99
   29867             :  *     return <Py_intptr_t> fused_read_line[data_t]
   29868             :  * 
   29869             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   29870             :  *     return <Py_intptr_t> fused_write_line[data_t]
   29871             :  * 
   29872             :  */
   29873             : 
   29874             :   /* function exit code */
   29875           0 :   __pyx_L1_error:;
   29876           0 :   __Pyx_XDECREF(__pyx_t_1);
   29877           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   29878           0 :     __Pyx_PyThreadState_declare
   29879           0 :     __Pyx_PyThreadState_assign
   29880           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   29881           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29882           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   29883           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29884           0 :   __pyx_r = NULL;
   29885           0 :   goto __pyx_L2;
   29886          92 :   __pyx_L0:;
   29887          92 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   29888          92 :   __pyx_L2:;
   29889          92 :   __Pyx_XGIVEREF(__pyx_r);
   29890          92 :   __Pyx_RefNannyFinishContext();
   29891          92 :   return __pyx_r;
   29892             : }
   29893             : 
   29894             : /* Python wrapper */
   29895             : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_59get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   29896             : static PyMethodDef __pyx_fuse_3__pyx_mdef_9_ni_label_59get_write_line = {"__pyx_fuse_3get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_3__pyx_pw_9_ni_label_59get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   29897           3 : static PyObject *__pyx_fuse_3__pyx_pw_9_ni_label_59get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   29898           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   29899           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   29900           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   29901           3 :   PyObject* values[1] = {0};
   29902           3 :   int __pyx_lineno = 0;
   29903           3 :   const char *__pyx_filename = NULL;
   29904           3 :   int __pyx_clineno = 0;
   29905           3 :   PyObject *__pyx_r = 0;
   29906             :   __Pyx_RefNannyDeclarations
   29907           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   29908             :   #if CYTHON_ASSUME_SAFE_MACROS
   29909           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   29910             :   #else
   29911             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   29912             :   #endif
   29913           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   29914             :   {
   29915           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   29916           3 :     if (__pyx_kwds) {
   29917           0 :       Py_ssize_t kw_args;
   29918           0 :       switch (__pyx_nargs) {
   29919           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29920           0 :         CYTHON_FALLTHROUGH;
   29921           0 :         case  0: break;
   29922           0 :         default: goto __pyx_L5_argtuple_error;
   29923             :       }
   29924           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   29925           0 :       switch (__pyx_nargs) {
   29926           0 :         case  0:
   29927           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   29928           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   29929           0 :           kw_args--;
   29930             :         }
   29931           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   29932           0 :         else goto __pyx_L5_argtuple_error;
   29933             :       }
   29934           0 :       if (unlikely(kw_args > 0)) {
   29935           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   29936           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   29937             :       }
   29938           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   29939           0 :       goto __pyx_L5_argtuple_error;
   29940             :     } else {
   29941           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   29942             :     }
   29943           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   29944             :   }
   29945           3 :   goto __pyx_L6_skip;
   29946           0 :   __pyx_L5_argtuple_error:;
   29947           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   29948           3 :   __pyx_L6_skip:;
   29949           3 :   goto __pyx_L4_argument_unpacking_done;
   29950           0 :   __pyx_L3_error:;
   29951             :   {
   29952           0 :     Py_ssize_t __pyx_temp;
   29953           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29954             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29955             :     }
   29956             :   }
   29957           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   29958           0 :   __Pyx_RefNannyFinishContext();
   29959           0 :   return NULL;
   29960           3 :   __pyx_L4_argument_unpacking_done:;
   29961           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   29962           3 :   __pyx_r = __pyx_pf_9_ni_label_58get_write_line(__pyx_self, __pyx_v_a);
   29963             : 
   29964             :   /* function exit code */
   29965           3 :   goto __pyx_L0;
   29966           0 :   __pyx_L1_error:;
   29967           0 :   __pyx_r = NULL;
   29968           3 :   __pyx_L0:;
   29969             :   {
   29970           3 :     Py_ssize_t __pyx_temp;
   29971           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   29972             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   29973             :     }
   29974             :   }
   29975             :   __Pyx_RefNannyFinishContext();
   29976             :   return __pyx_r;
   29977             : }
   29978             : 
   29979           3 : static PyObject *__pyx_pf_9_ni_label_58get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   29980           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   29981           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   29982           3 :   PyObject *__pyx_r = NULL;
   29983             :   __Pyx_RefNannyDeclarations
   29984           3 :   PyObject *__pyx_t_1 = NULL;
   29985           3 :   int __pyx_lineno = 0;
   29986           3 :   const char *__pyx_filename = NULL;
   29987           3 :   int __pyx_clineno = 0;
   29988           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_3get_write_line", 1);
   29989           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   29990           3 :   __pyx_pybuffer_a.refcount = 0;
   29991           3 :   __pyx_pybuffernd_a.data = NULL;
   29992           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   29993             :   {
   29994           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   29995           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   29996             :   }
   29997           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   29998             : 
   29999             :   /* "_ni_label.pyx":100
   30000             :  * 
   30001             :  * def get_write_line(np.ndarray[data_t] a):
   30002             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30003             :  * 
   30004             :  * 
   30005             :  */
   30006           3 :   __Pyx_XDECREF(__pyx_r);
   30007           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_3__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30008           3 :   __Pyx_GOTREF(__pyx_t_1);
   30009           3 :   __pyx_r = __pyx_t_1;
   30010           3 :   __pyx_t_1 = 0;
   30011           3 :   goto __pyx_L0;
   30012             : 
   30013             :   /* "_ni_label.pyx":99
   30014             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30015             :  * 
   30016             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30017             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30018             :  * 
   30019             :  */
   30020             : 
   30021             :   /* function exit code */
   30022           0 :   __pyx_L1_error:;
   30023           0 :   __Pyx_XDECREF(__pyx_t_1);
   30024           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30025           0 :     __Pyx_PyThreadState_declare
   30026           0 :     __Pyx_PyThreadState_assign
   30027           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30028           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30029           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30030           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30031           0 :   __pyx_r = NULL;
   30032           0 :   goto __pyx_L2;
   30033           3 :   __pyx_L0:;
   30034           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30035           3 :   __pyx_L2:;
   30036           3 :   __Pyx_XGIVEREF(__pyx_r);
   30037           3 :   __Pyx_RefNannyFinishContext();
   30038           3 :   return __pyx_r;
   30039             : }
   30040             : 
   30041             : /* Python wrapper */
   30042             : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_61get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30043             : static PyMethodDef __pyx_fuse_4__pyx_mdef_9_ni_label_61get_write_line = {"__pyx_fuse_4get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_4__pyx_pw_9_ni_label_61get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30044           3 : static PyObject *__pyx_fuse_4__pyx_pw_9_ni_label_61get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30045           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30046           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30047           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30048           3 :   PyObject* values[1] = {0};
   30049           3 :   int __pyx_lineno = 0;
   30050           3 :   const char *__pyx_filename = NULL;
   30051           3 :   int __pyx_clineno = 0;
   30052           3 :   PyObject *__pyx_r = 0;
   30053             :   __Pyx_RefNannyDeclarations
   30054           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30055             :   #if CYTHON_ASSUME_SAFE_MACROS
   30056           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30057             :   #else
   30058             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30059             :   #endif
   30060           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30061             :   {
   30062           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30063           3 :     if (__pyx_kwds) {
   30064           0 :       Py_ssize_t kw_args;
   30065           0 :       switch (__pyx_nargs) {
   30066           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30067           0 :         CYTHON_FALLTHROUGH;
   30068           0 :         case  0: break;
   30069           0 :         default: goto __pyx_L5_argtuple_error;
   30070             :       }
   30071           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30072           0 :       switch (__pyx_nargs) {
   30073           0 :         case  0:
   30074           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30075           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30076           0 :           kw_args--;
   30077             :         }
   30078           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30079           0 :         else goto __pyx_L5_argtuple_error;
   30080             :       }
   30081           0 :       if (unlikely(kw_args > 0)) {
   30082           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30083           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30084             :       }
   30085           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30086           0 :       goto __pyx_L5_argtuple_error;
   30087             :     } else {
   30088           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30089             :     }
   30090           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30091             :   }
   30092           3 :   goto __pyx_L6_skip;
   30093           0 :   __pyx_L5_argtuple_error:;
   30094           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30095           3 :   __pyx_L6_skip:;
   30096           3 :   goto __pyx_L4_argument_unpacking_done;
   30097           0 :   __pyx_L3_error:;
   30098             :   {
   30099           0 :     Py_ssize_t __pyx_temp;
   30100           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30101             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30102             :     }
   30103             :   }
   30104           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30105           0 :   __Pyx_RefNannyFinishContext();
   30106           0 :   return NULL;
   30107           3 :   __pyx_L4_argument_unpacking_done:;
   30108           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30109           3 :   __pyx_r = __pyx_pf_9_ni_label_60get_write_line(__pyx_self, __pyx_v_a);
   30110             : 
   30111             :   /* function exit code */
   30112           3 :   goto __pyx_L0;
   30113           0 :   __pyx_L1_error:;
   30114           0 :   __pyx_r = NULL;
   30115           3 :   __pyx_L0:;
   30116             :   {
   30117           3 :     Py_ssize_t __pyx_temp;
   30118           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30119             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30120             :     }
   30121             :   }
   30122             :   __Pyx_RefNannyFinishContext();
   30123             :   return __pyx_r;
   30124             : }
   30125             : 
   30126           3 : static PyObject *__pyx_pf_9_ni_label_60get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30127           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30128           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30129           3 :   PyObject *__pyx_r = NULL;
   30130             :   __Pyx_RefNannyDeclarations
   30131           3 :   PyObject *__pyx_t_1 = NULL;
   30132           3 :   int __pyx_lineno = 0;
   30133           3 :   const char *__pyx_filename = NULL;
   30134           3 :   int __pyx_clineno = 0;
   30135           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_4get_write_line", 1);
   30136           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30137           3 :   __pyx_pybuffer_a.refcount = 0;
   30138           3 :   __pyx_pybuffernd_a.data = NULL;
   30139           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30140             :   {
   30141           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30142           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint8_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30143             :   }
   30144           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30145             : 
   30146             :   /* "_ni_label.pyx":100
   30147             :  * 
   30148             :  * def get_write_line(np.ndarray[data_t] a):
   30149             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30150             :  * 
   30151             :  * 
   30152             :  */
   30153           3 :   __Pyx_XDECREF(__pyx_r);
   30154           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_4__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30155           3 :   __Pyx_GOTREF(__pyx_t_1);
   30156           3 :   __pyx_r = __pyx_t_1;
   30157           3 :   __pyx_t_1 = 0;
   30158           3 :   goto __pyx_L0;
   30159             : 
   30160             :   /* "_ni_label.pyx":99
   30161             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30162             :  * 
   30163             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30164             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30165             :  * 
   30166             :  */
   30167             : 
   30168             :   /* function exit code */
   30169           0 :   __pyx_L1_error:;
   30170           0 :   __Pyx_XDECREF(__pyx_t_1);
   30171           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30172           0 :     __Pyx_PyThreadState_declare
   30173           0 :     __Pyx_PyThreadState_assign
   30174           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30175           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30176           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30177           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30178           0 :   __pyx_r = NULL;
   30179           0 :   goto __pyx_L2;
   30180           3 :   __pyx_L0:;
   30181           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30182           3 :   __pyx_L2:;
   30183           3 :   __Pyx_XGIVEREF(__pyx_r);
   30184           3 :   __Pyx_RefNannyFinishContext();
   30185           3 :   return __pyx_r;
   30186             : }
   30187             : 
   30188             : /* Python wrapper */
   30189             : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_63get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30190             : static PyMethodDef __pyx_fuse_5__pyx_mdef_9_ni_label_63get_write_line = {"__pyx_fuse_5get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_5__pyx_pw_9_ni_label_63get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30191           3 : static PyObject *__pyx_fuse_5__pyx_pw_9_ni_label_63get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30192           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30193           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30194           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30195           3 :   PyObject* values[1] = {0};
   30196           3 :   int __pyx_lineno = 0;
   30197           3 :   const char *__pyx_filename = NULL;
   30198           3 :   int __pyx_clineno = 0;
   30199           3 :   PyObject *__pyx_r = 0;
   30200             :   __Pyx_RefNannyDeclarations
   30201           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30202             :   #if CYTHON_ASSUME_SAFE_MACROS
   30203           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30204             :   #else
   30205             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30206             :   #endif
   30207           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30208             :   {
   30209           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30210           3 :     if (__pyx_kwds) {
   30211           0 :       Py_ssize_t kw_args;
   30212           0 :       switch (__pyx_nargs) {
   30213           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30214           0 :         CYTHON_FALLTHROUGH;
   30215           0 :         case  0: break;
   30216           0 :         default: goto __pyx_L5_argtuple_error;
   30217             :       }
   30218           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30219           0 :       switch (__pyx_nargs) {
   30220           0 :         case  0:
   30221           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30222           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30223           0 :           kw_args--;
   30224             :         }
   30225           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30226           0 :         else goto __pyx_L5_argtuple_error;
   30227             :       }
   30228           0 :       if (unlikely(kw_args > 0)) {
   30229           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30230           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30231             :       }
   30232           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30233           0 :       goto __pyx_L5_argtuple_error;
   30234             :     } else {
   30235           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30236             :     }
   30237           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30238             :   }
   30239           3 :   goto __pyx_L6_skip;
   30240           0 :   __pyx_L5_argtuple_error:;
   30241           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30242           3 :   __pyx_L6_skip:;
   30243           3 :   goto __pyx_L4_argument_unpacking_done;
   30244           0 :   __pyx_L3_error:;
   30245             :   {
   30246           0 :     Py_ssize_t __pyx_temp;
   30247           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30248             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30249             :     }
   30250             :   }
   30251           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30252           0 :   __Pyx_RefNannyFinishContext();
   30253           0 :   return NULL;
   30254           3 :   __pyx_L4_argument_unpacking_done:;
   30255           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30256           3 :   __pyx_r = __pyx_pf_9_ni_label_62get_write_line(__pyx_self, __pyx_v_a);
   30257             : 
   30258             :   /* function exit code */
   30259           3 :   goto __pyx_L0;
   30260           0 :   __pyx_L1_error:;
   30261           0 :   __pyx_r = NULL;
   30262           3 :   __pyx_L0:;
   30263             :   {
   30264           3 :     Py_ssize_t __pyx_temp;
   30265           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30266             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30267             :     }
   30268             :   }
   30269             :   __Pyx_RefNannyFinishContext();
   30270             :   return __pyx_r;
   30271             : }
   30272             : 
   30273           3 : static PyObject *__pyx_pf_9_ni_label_62get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30274           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30275           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30276           3 :   PyObject *__pyx_r = NULL;
   30277             :   __Pyx_RefNannyDeclarations
   30278           3 :   PyObject *__pyx_t_1 = NULL;
   30279           3 :   int __pyx_lineno = 0;
   30280           3 :   const char *__pyx_filename = NULL;
   30281           3 :   int __pyx_clineno = 0;
   30282           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_5get_write_line", 1);
   30283           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30284           3 :   __pyx_pybuffer_a.refcount = 0;
   30285           3 :   __pyx_pybuffernd_a.data = NULL;
   30286           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30287             :   {
   30288           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30289           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint16_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30290             :   }
   30291           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30292             : 
   30293             :   /* "_ni_label.pyx":100
   30294             :  * 
   30295             :  * def get_write_line(np.ndarray[data_t] a):
   30296             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30297             :  * 
   30298             :  * 
   30299             :  */
   30300           3 :   __Pyx_XDECREF(__pyx_r);
   30301           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_5__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30302           3 :   __Pyx_GOTREF(__pyx_t_1);
   30303           3 :   __pyx_r = __pyx_t_1;
   30304           3 :   __pyx_t_1 = 0;
   30305           3 :   goto __pyx_L0;
   30306             : 
   30307             :   /* "_ni_label.pyx":99
   30308             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30309             :  * 
   30310             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30311             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30312             :  * 
   30313             :  */
   30314             : 
   30315             :   /* function exit code */
   30316           0 :   __pyx_L1_error:;
   30317           0 :   __Pyx_XDECREF(__pyx_t_1);
   30318           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30319           0 :     __Pyx_PyThreadState_declare
   30320           0 :     __Pyx_PyThreadState_assign
   30321           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30322           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30323           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30324           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30325           0 :   __pyx_r = NULL;
   30326           0 :   goto __pyx_L2;
   30327           3 :   __pyx_L0:;
   30328           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30329           3 :   __pyx_L2:;
   30330           3 :   __Pyx_XGIVEREF(__pyx_r);
   30331           3 :   __Pyx_RefNannyFinishContext();
   30332           3 :   return __pyx_r;
   30333             : }
   30334             : 
   30335             : /* Python wrapper */
   30336             : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_65get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30337             : static PyMethodDef __pyx_fuse_6__pyx_mdef_9_ni_label_65get_write_line = {"__pyx_fuse_6get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_6__pyx_pw_9_ni_label_65get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30338           3 : static PyObject *__pyx_fuse_6__pyx_pw_9_ni_label_65get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30339           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30340           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30341           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30342           3 :   PyObject* values[1] = {0};
   30343           3 :   int __pyx_lineno = 0;
   30344           3 :   const char *__pyx_filename = NULL;
   30345           3 :   int __pyx_clineno = 0;
   30346           3 :   PyObject *__pyx_r = 0;
   30347             :   __Pyx_RefNannyDeclarations
   30348           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30349             :   #if CYTHON_ASSUME_SAFE_MACROS
   30350           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30351             :   #else
   30352             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30353             :   #endif
   30354           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30355             :   {
   30356           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30357           3 :     if (__pyx_kwds) {
   30358           0 :       Py_ssize_t kw_args;
   30359           0 :       switch (__pyx_nargs) {
   30360           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30361           0 :         CYTHON_FALLTHROUGH;
   30362           0 :         case  0: break;
   30363           0 :         default: goto __pyx_L5_argtuple_error;
   30364             :       }
   30365           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30366           0 :       switch (__pyx_nargs) {
   30367           0 :         case  0:
   30368           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30369           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30370           0 :           kw_args--;
   30371             :         }
   30372           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30373           0 :         else goto __pyx_L5_argtuple_error;
   30374             :       }
   30375           0 :       if (unlikely(kw_args > 0)) {
   30376           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30377           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30378             :       }
   30379           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30380           0 :       goto __pyx_L5_argtuple_error;
   30381             :     } else {
   30382           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30383             :     }
   30384           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30385             :   }
   30386           3 :   goto __pyx_L6_skip;
   30387           0 :   __pyx_L5_argtuple_error:;
   30388           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30389           3 :   __pyx_L6_skip:;
   30390           3 :   goto __pyx_L4_argument_unpacking_done;
   30391           0 :   __pyx_L3_error:;
   30392             :   {
   30393           0 :     Py_ssize_t __pyx_temp;
   30394           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30395             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30396             :     }
   30397             :   }
   30398           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30399           0 :   __Pyx_RefNannyFinishContext();
   30400           0 :   return NULL;
   30401           3 :   __pyx_L4_argument_unpacking_done:;
   30402           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30403           3 :   __pyx_r = __pyx_pf_9_ni_label_64get_write_line(__pyx_self, __pyx_v_a);
   30404             : 
   30405             :   /* function exit code */
   30406           3 :   goto __pyx_L0;
   30407           0 :   __pyx_L1_error:;
   30408           0 :   __pyx_r = NULL;
   30409           3 :   __pyx_L0:;
   30410             :   {
   30411           3 :     Py_ssize_t __pyx_temp;
   30412           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30413             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30414             :     }
   30415             :   }
   30416             :   __Pyx_RefNannyFinishContext();
   30417             :   return __pyx_r;
   30418             : }
   30419             : 
   30420           3 : static PyObject *__pyx_pf_9_ni_label_64get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30421           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30422           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30423           3 :   PyObject *__pyx_r = NULL;
   30424             :   __Pyx_RefNannyDeclarations
   30425           3 :   PyObject *__pyx_t_1 = NULL;
   30426           3 :   int __pyx_lineno = 0;
   30427           3 :   const char *__pyx_filename = NULL;
   30428           3 :   int __pyx_clineno = 0;
   30429           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_6get_write_line", 1);
   30430           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30431           3 :   __pyx_pybuffer_a.refcount = 0;
   30432           3 :   __pyx_pybuffernd_a.data = NULL;
   30433           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30434             :   {
   30435           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30436           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30437             :   }
   30438           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30439             : 
   30440             :   /* "_ni_label.pyx":100
   30441             :  * 
   30442             :  * def get_write_line(np.ndarray[data_t] a):
   30443             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30444             :  * 
   30445             :  * 
   30446             :  */
   30447           3 :   __Pyx_XDECREF(__pyx_r);
   30448           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_6__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30449           3 :   __Pyx_GOTREF(__pyx_t_1);
   30450           3 :   __pyx_r = __pyx_t_1;
   30451           3 :   __pyx_t_1 = 0;
   30452           3 :   goto __pyx_L0;
   30453             : 
   30454             :   /* "_ni_label.pyx":99
   30455             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30456             :  * 
   30457             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30458             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30459             :  * 
   30460             :  */
   30461             : 
   30462             :   /* function exit code */
   30463           0 :   __pyx_L1_error:;
   30464           0 :   __Pyx_XDECREF(__pyx_t_1);
   30465           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30466           0 :     __Pyx_PyThreadState_declare
   30467           0 :     __Pyx_PyThreadState_assign
   30468           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30469           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30470           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30471           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30472           0 :   __pyx_r = NULL;
   30473           0 :   goto __pyx_L2;
   30474           3 :   __pyx_L0:;
   30475           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30476           3 :   __pyx_L2:;
   30477           3 :   __Pyx_XGIVEREF(__pyx_r);
   30478           3 :   __Pyx_RefNannyFinishContext();
   30479           3 :   return __pyx_r;
   30480             : }
   30481             : 
   30482             : /* Python wrapper */
   30483             : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_67get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30484             : static PyMethodDef __pyx_fuse_7__pyx_mdef_9_ni_label_67get_write_line = {"__pyx_fuse_7get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_7__pyx_pw_9_ni_label_67get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30485           3 : static PyObject *__pyx_fuse_7__pyx_pw_9_ni_label_67get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30486           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30487           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30488           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30489           3 :   PyObject* values[1] = {0};
   30490           3 :   int __pyx_lineno = 0;
   30491           3 :   const char *__pyx_filename = NULL;
   30492           3 :   int __pyx_clineno = 0;
   30493           3 :   PyObject *__pyx_r = 0;
   30494             :   __Pyx_RefNannyDeclarations
   30495           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30496             :   #if CYTHON_ASSUME_SAFE_MACROS
   30497           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30498             :   #else
   30499             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30500             :   #endif
   30501           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30502             :   {
   30503           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30504           3 :     if (__pyx_kwds) {
   30505           0 :       Py_ssize_t kw_args;
   30506           0 :       switch (__pyx_nargs) {
   30507           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30508           0 :         CYTHON_FALLTHROUGH;
   30509           0 :         case  0: break;
   30510           0 :         default: goto __pyx_L5_argtuple_error;
   30511             :       }
   30512           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30513           0 :       switch (__pyx_nargs) {
   30514           0 :         case  0:
   30515           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30516           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30517           0 :           kw_args--;
   30518             :         }
   30519           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30520           0 :         else goto __pyx_L5_argtuple_error;
   30521             :       }
   30522           0 :       if (unlikely(kw_args > 0)) {
   30523           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30524           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30525             :       }
   30526           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30527           0 :       goto __pyx_L5_argtuple_error;
   30528             :     } else {
   30529           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30530             :     }
   30531           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30532             :   }
   30533           3 :   goto __pyx_L6_skip;
   30534           0 :   __pyx_L5_argtuple_error:;
   30535           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30536           3 :   __pyx_L6_skip:;
   30537           3 :   goto __pyx_L4_argument_unpacking_done;
   30538           0 :   __pyx_L3_error:;
   30539             :   {
   30540           0 :     Py_ssize_t __pyx_temp;
   30541           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30542             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30543             :     }
   30544             :   }
   30545           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30546           0 :   __Pyx_RefNannyFinishContext();
   30547           0 :   return NULL;
   30548           3 :   __pyx_L4_argument_unpacking_done:;
   30549           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30550           3 :   __pyx_r = __pyx_pf_9_ni_label_66get_write_line(__pyx_self, __pyx_v_a);
   30551             : 
   30552             :   /* function exit code */
   30553           3 :   goto __pyx_L0;
   30554           0 :   __pyx_L1_error:;
   30555           0 :   __pyx_r = NULL;
   30556           3 :   __pyx_L0:;
   30557             :   {
   30558           3 :     Py_ssize_t __pyx_temp;
   30559           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30560             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30561             :     }
   30562             :   }
   30563             :   __Pyx_RefNannyFinishContext();
   30564             :   return __pyx_r;
   30565             : }
   30566             : 
   30567           3 : static PyObject *__pyx_pf_9_ni_label_66get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30568           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30569           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30570           3 :   PyObject *__pyx_r = NULL;
   30571             :   __Pyx_RefNannyDeclarations
   30572           3 :   PyObject *__pyx_t_1 = NULL;
   30573           3 :   int __pyx_lineno = 0;
   30574           3 :   const char *__pyx_filename = NULL;
   30575           3 :   int __pyx_clineno = 0;
   30576           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_7get_write_line", 1);
   30577           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30578           3 :   __pyx_pybuffer_a.refcount = 0;
   30579           3 :   __pyx_pybuffernd_a.data = NULL;
   30580           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30581             :   {
   30582           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30583           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30584             :   }
   30585           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30586             : 
   30587             :   /* "_ni_label.pyx":100
   30588             :  * 
   30589             :  * def get_write_line(np.ndarray[data_t] a):
   30590             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30591             :  * 
   30592             :  * 
   30593             :  */
   30594           3 :   __Pyx_XDECREF(__pyx_r);
   30595           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_7__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30596           3 :   __Pyx_GOTREF(__pyx_t_1);
   30597           3 :   __pyx_r = __pyx_t_1;
   30598           3 :   __pyx_t_1 = 0;
   30599           3 :   goto __pyx_L0;
   30600             : 
   30601             :   /* "_ni_label.pyx":99
   30602             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30603             :  * 
   30604             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30605             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30606             :  * 
   30607             :  */
   30608             : 
   30609             :   /* function exit code */
   30610           0 :   __pyx_L1_error:;
   30611           0 :   __Pyx_XDECREF(__pyx_t_1);
   30612           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30613           0 :     __Pyx_PyThreadState_declare
   30614           0 :     __Pyx_PyThreadState_assign
   30615           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30616           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30617           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30618           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30619           0 :   __pyx_r = NULL;
   30620           0 :   goto __pyx_L2;
   30621           3 :   __pyx_L0:;
   30622           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30623           3 :   __pyx_L2:;
   30624           3 :   __Pyx_XGIVEREF(__pyx_r);
   30625           3 :   __Pyx_RefNannyFinishContext();
   30626           3 :   return __pyx_r;
   30627             : }
   30628             : 
   30629             : /* Python wrapper */
   30630             : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_69get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30631             : static PyMethodDef __pyx_fuse_8__pyx_mdef_9_ni_label_69get_write_line = {"__pyx_fuse_8get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_8__pyx_pw_9_ni_label_69get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30632           3 : static PyObject *__pyx_fuse_8__pyx_pw_9_ni_label_69get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30633           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30634           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30635           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30636           3 :   PyObject* values[1] = {0};
   30637           3 :   int __pyx_lineno = 0;
   30638           3 :   const char *__pyx_filename = NULL;
   30639           3 :   int __pyx_clineno = 0;
   30640           3 :   PyObject *__pyx_r = 0;
   30641             :   __Pyx_RefNannyDeclarations
   30642           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30643             :   #if CYTHON_ASSUME_SAFE_MACROS
   30644           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30645             :   #else
   30646             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30647             :   #endif
   30648           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30649             :   {
   30650           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30651           3 :     if (__pyx_kwds) {
   30652           0 :       Py_ssize_t kw_args;
   30653           0 :       switch (__pyx_nargs) {
   30654           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30655           0 :         CYTHON_FALLTHROUGH;
   30656           0 :         case  0: break;
   30657           0 :         default: goto __pyx_L5_argtuple_error;
   30658             :       }
   30659           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30660           0 :       switch (__pyx_nargs) {
   30661           0 :         case  0:
   30662           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30663           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30664           0 :           kw_args--;
   30665             :         }
   30666           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30667           0 :         else goto __pyx_L5_argtuple_error;
   30668             :       }
   30669           0 :       if (unlikely(kw_args > 0)) {
   30670           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30671           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30672             :       }
   30673           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30674           0 :       goto __pyx_L5_argtuple_error;
   30675             :     } else {
   30676           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30677             :     }
   30678           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30679             :   }
   30680           3 :   goto __pyx_L6_skip;
   30681           0 :   __pyx_L5_argtuple_error:;
   30682           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30683           3 :   __pyx_L6_skip:;
   30684           3 :   goto __pyx_L4_argument_unpacking_done;
   30685           0 :   __pyx_L3_error:;
   30686             :   {
   30687           0 :     Py_ssize_t __pyx_temp;
   30688           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30689             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30690             :     }
   30691             :   }
   30692           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30693           0 :   __Pyx_RefNannyFinishContext();
   30694           0 :   return NULL;
   30695           3 :   __pyx_L4_argument_unpacking_done:;
   30696           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30697           3 :   __pyx_r = __pyx_pf_9_ni_label_68get_write_line(__pyx_self, __pyx_v_a);
   30698             : 
   30699             :   /* function exit code */
   30700           3 :   goto __pyx_L0;
   30701           0 :   __pyx_L1_error:;
   30702           0 :   __pyx_r = NULL;
   30703           3 :   __pyx_L0:;
   30704             :   {
   30705           3 :     Py_ssize_t __pyx_temp;
   30706           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30707             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30708             :     }
   30709             :   }
   30710             :   __Pyx_RefNannyFinishContext();
   30711             :   return __pyx_r;
   30712             : }
   30713             : 
   30714           3 : static PyObject *__pyx_pf_9_ni_label_68get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30715           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30716           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30717           3 :   PyObject *__pyx_r = NULL;
   30718             :   __Pyx_RefNannyDeclarations
   30719           3 :   PyObject *__pyx_t_1 = NULL;
   30720           3 :   int __pyx_lineno = 0;
   30721           3 :   const char *__pyx_filename = NULL;
   30722           3 :   int __pyx_clineno = 0;
   30723           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_8get_write_line", 1);
   30724           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30725           3 :   __pyx_pybuffer_a.refcount = 0;
   30726           3 :   __pyx_pybuffernd_a.data = NULL;
   30727           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30728             :   {
   30729           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30730           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30731             :   }
   30732           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30733             : 
   30734             :   /* "_ni_label.pyx":100
   30735             :  * 
   30736             :  * def get_write_line(np.ndarray[data_t] a):
   30737             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30738             :  * 
   30739             :  * 
   30740             :  */
   30741           3 :   __Pyx_XDECREF(__pyx_r);
   30742           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_8__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30743           3 :   __Pyx_GOTREF(__pyx_t_1);
   30744           3 :   __pyx_r = __pyx_t_1;
   30745           3 :   __pyx_t_1 = 0;
   30746           3 :   goto __pyx_L0;
   30747             : 
   30748             :   /* "_ni_label.pyx":99
   30749             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30750             :  * 
   30751             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30752             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30753             :  * 
   30754             :  */
   30755             : 
   30756             :   /* function exit code */
   30757           0 :   __pyx_L1_error:;
   30758           0 :   __Pyx_XDECREF(__pyx_t_1);
   30759           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30760           0 :     __Pyx_PyThreadState_declare
   30761           0 :     __Pyx_PyThreadState_assign
   30762           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30763           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30764           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30765           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30766           0 :   __pyx_r = NULL;
   30767           0 :   goto __pyx_L2;
   30768           3 :   __pyx_L0:;
   30769           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30770           3 :   __pyx_L2:;
   30771           3 :   __Pyx_XGIVEREF(__pyx_r);
   30772           3 :   __Pyx_RefNannyFinishContext();
   30773           3 :   return __pyx_r;
   30774             : }
   30775             : 
   30776             : /* Python wrapper */
   30777             : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_71get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
   30778             : static PyMethodDef __pyx_fuse_9__pyx_mdef_9_ni_label_71get_write_line = {"__pyx_fuse_9get_write_line", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_fuse_9__pyx_pw_9_ni_label_71get_write_line, METH_VARARGS|METH_KEYWORDS, 0};
   30779           3 : static PyObject *__pyx_fuse_9__pyx_pw_9_ni_label_71get_write_line(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
   30780           3 :   CYTHON_UNUSED PyArrayObject *__pyx_v_a = 0;
   30781           3 :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   30782           3 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   30783           3 :   PyObject* values[1] = {0};
   30784           3 :   int __pyx_lineno = 0;
   30785           3 :   const char *__pyx_filename = NULL;
   30786           3 :   int __pyx_clineno = 0;
   30787           3 :   PyObject *__pyx_r = 0;
   30788             :   __Pyx_RefNannyDeclarations
   30789           3 :   __Pyx_RefNannySetupContext("get_write_line (wrapper)", 0);
   30790             :   #if CYTHON_ASSUME_SAFE_MACROS
   30791           3 :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   30792             :   #else
   30793             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   30794             :   #endif
   30795           3 :   __pyx_kwvalues = __Pyx_KwValues_VARARGS(__pyx_args, __pyx_nargs);
   30796             :   {
   30797           3 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_a,0};
   30798           3 :     if (__pyx_kwds) {
   30799           0 :       Py_ssize_t kw_args;
   30800           0 :       switch (__pyx_nargs) {
   30801           0 :         case  1: values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30802           0 :         CYTHON_FALLTHROUGH;
   30803           0 :         case  0: break;
   30804           0 :         default: goto __pyx_L5_argtuple_error;
   30805             :       }
   30806           0 :       kw_args = __Pyx_NumKwargs_VARARGS(__pyx_kwds);
   30807           0 :       switch (__pyx_nargs) {
   30808           0 :         case  0:
   30809           0 :         if (likely((values[0] = __Pyx_GetKwValue_VARARGS(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_a)) != 0)) {
   30810           0 :           (void)__Pyx_Arg_NewRef_VARARGS(values[0]);
   30811           0 :           kw_args--;
   30812             :         }
   30813           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L3_error)
   30814           0 :         else goto __pyx_L5_argtuple_error;
   30815             :       }
   30816           0 :       if (unlikely(kw_args > 0)) {
   30817           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   30818           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "get_write_line") < 0)) __PYX_ERR(0, 99, __pyx_L3_error)
   30819             :       }
   30820           3 :     } else if (unlikely(__pyx_nargs != 1)) {
   30821           0 :       goto __pyx_L5_argtuple_error;
   30822             :     } else {
   30823           3 :       values[0] = __Pyx_Arg_VARARGS(__pyx_args, 0);
   30824             :     }
   30825           3 :     __pyx_v_a = ((PyArrayObject *)values[0]);
   30826             :   }
   30827           3 :   goto __pyx_L6_skip;
   30828           0 :   __pyx_L5_argtuple_error:;
   30829           0 :   __Pyx_RaiseArgtupleInvalid("get_write_line", 1, 1, 1, __pyx_nargs); __PYX_ERR(0, 99, __pyx_L3_error)
   30830           3 :   __pyx_L6_skip:;
   30831           3 :   goto __pyx_L4_argument_unpacking_done;
   30832           0 :   __pyx_L3_error:;
   30833             :   {
   30834           0 :     Py_ssize_t __pyx_temp;
   30835           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30836             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30837             :     }
   30838             :   }
   30839           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30840           0 :   __Pyx_RefNannyFinishContext();
   30841           0 :   return NULL;
   30842           3 :   __pyx_L4_argument_unpacking_done:;
   30843           3 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 99, __pyx_L1_error)
   30844           3 :   __pyx_r = __pyx_pf_9_ni_label_70get_write_line(__pyx_self, __pyx_v_a);
   30845             : 
   30846             :   /* function exit code */
   30847           3 :   goto __pyx_L0;
   30848           0 :   __pyx_L1_error:;
   30849           0 :   __pyx_r = NULL;
   30850           3 :   __pyx_L0:;
   30851             :   {
   30852           3 :     Py_ssize_t __pyx_temp;
   30853           3 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   30854             :       __Pyx_Arg_XDECREF_VARARGS(values[__pyx_temp]);
   30855             :     }
   30856             :   }
   30857             :   __Pyx_RefNannyFinishContext();
   30858             :   return __pyx_r;
   30859             : }
   30860             : 
   30861           3 : static PyObject *__pyx_pf_9_ni_label_70get_write_line(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyArrayObject *__pyx_v_a) {
   30862           3 :   __Pyx_LocalBuf_ND __pyx_pybuffernd_a;
   30863           3 :   __Pyx_Buffer __pyx_pybuffer_a;
   30864           3 :   PyObject *__pyx_r = NULL;
   30865             :   __Pyx_RefNannyDeclarations
   30866           3 :   PyObject *__pyx_t_1 = NULL;
   30867           3 :   int __pyx_lineno = 0;
   30868           3 :   const char *__pyx_filename = NULL;
   30869           3 :   int __pyx_clineno = 0;
   30870           3 :   __Pyx_RefNannySetupContext("__pyx_fuse_9get_write_line", 1);
   30871           3 :   __pyx_pybuffer_a.pybuffer.buf = NULL;
   30872           3 :   __pyx_pybuffer_a.refcount = 0;
   30873           3 :   __pyx_pybuffernd_a.data = NULL;
   30874           3 :   __pyx_pybuffernd_a.rcbuffer = &__pyx_pybuffer_a;
   30875             :   {
   30876           3 :     __Pyx_BufFmt_StackElem __pyx_stack[1];
   30877           3 :     if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_a.rcbuffer->pybuffer, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) __PYX_ERR(0, 99, __pyx_L1_error)
   30878             :   }
   30879           3 :   __pyx_pybuffernd_a.diminfo[0].strides = __pyx_pybuffernd_a.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_a.diminfo[0].shape = __pyx_pybuffernd_a.rcbuffer->pybuffer.shape[0];
   30880             : 
   30881             :   /* "_ni_label.pyx":100
   30882             :  * 
   30883             :  * def get_write_line(np.ndarray[data_t] a):
   30884             :  *     return <Py_intptr_t> fused_write_line[data_t]             # <<<<<<<<<<<<<<
   30885             :  * 
   30886             :  * 
   30887             :  */
   30888           3 :   __Pyx_XDECREF(__pyx_r);
   30889           3 :   __pyx_t_1 = __Pyx_PyInt_From_Py_intptr_t(((Py_intptr_t)__pyx_fuse_9__pyx_f_9_ni_label_fused_write_line)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
   30890           3 :   __Pyx_GOTREF(__pyx_t_1);
   30891           3 :   __pyx_r = __pyx_t_1;
   30892           3 :   __pyx_t_1 = 0;
   30893           3 :   goto __pyx_L0;
   30894             : 
   30895             :   /* "_ni_label.pyx":99
   30896             :  *     return <Py_intptr_t> fused_read_line[data_t]
   30897             :  * 
   30898             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   30899             :  *     return <Py_intptr_t> fused_write_line[data_t]
   30900             :  * 
   30901             :  */
   30902             : 
   30903             :   /* function exit code */
   30904           0 :   __pyx_L1_error:;
   30905           0 :   __Pyx_XDECREF(__pyx_t_1);
   30906           0 :   { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
   30907           0 :     __Pyx_PyThreadState_declare
   30908           0 :     __Pyx_PyThreadState_assign
   30909           0 :     __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
   30910           0 :     __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30911           0 :   __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
   30912           0 :   __Pyx_AddTraceback("_ni_label.get_write_line", __pyx_clineno, __pyx_lineno, __pyx_filename);
   30913           0 :   __pyx_r = NULL;
   30914           0 :   goto __pyx_L2;
   30915           3 :   __pyx_L0:;
   30916           3 :   __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_a.rcbuffer->pybuffer);
   30917           3 :   __pyx_L2:;
   30918           3 :   __Pyx_XGIVEREF(__pyx_r);
   30919           3 :   __Pyx_RefNannyFinishContext();
   30920           3 :   return __pyx_r;
   30921             : }
   30922             : 
   30923             : /* "_ni_label.pyx":117
   30924             :  * # Mark two labels to be merged
   30925             :  * ######################################################################
   30926             :  * cdef inline np.uintp_t mark_for_merge(np.uintp_t a,             # <<<<<<<<<<<<<<
   30927             :  *                                       np.uintp_t b,
   30928             :  *                                       np.uintp_t *mergetable) noexcept nogil:
   30929             :  */
   30930             : 
   30931      853387 : static CYTHON_INLINE __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_mark_for_merge(__pyx_t_5numpy_uintp_t __pyx_v_a, __pyx_t_5numpy_uintp_t __pyx_v_b, __pyx_t_5numpy_uintp_t *__pyx_v_mergetable) {
   30932      853387 :   __pyx_t_5numpy_uintp_t __pyx_v_orig_a;
   30933      853387 :   __pyx_t_5numpy_uintp_t __pyx_v_orig_b;
   30934      853387 :   __pyx_t_5numpy_uintp_t __pyx_v_minlabel;
   30935      853387 :   __pyx_t_5numpy_uintp_t __pyx_r;
   30936      853387 :   int __pyx_t_1;
   30937      853387 :   __pyx_t_5numpy_uintp_t __pyx_t_2;
   30938      853387 :   __pyx_t_5numpy_uintp_t __pyx_t_3;
   30939             : 
   30940             :   /* "_ni_label.pyx":124
   30941             :  *         np.uintp_t orig_a, orig_b, minlabel
   30942             :  * 
   30943             :  *     orig_a = a             # <<<<<<<<<<<<<<
   30944             :  *     orig_b = b
   30945             :  *     # find smallest root for each of a and b
   30946             :  */
   30947      853387 :   __pyx_v_orig_a = __pyx_v_a;
   30948             : 
   30949             :   /* "_ni_label.pyx":125
   30950             :  * 
   30951             :  *     orig_a = a
   30952             :  *     orig_b = b             # <<<<<<<<<<<<<<
   30953             :  *     # find smallest root for each of a and b
   30954             :  *     while a != mergetable[a]:
   30955             :  */
   30956      853387 :   __pyx_v_orig_b = __pyx_v_b;
   30957             : 
   30958             :   /* "_ni_label.pyx":127
   30959             :  *     orig_b = b
   30960             :  *     # find smallest root for each of a and b
   30961             :  *     while a != mergetable[a]:             # <<<<<<<<<<<<<<
   30962             :  *         a = mergetable[a]
   30963             :  *     while b != mergetable[b]:
   30964             :  */
   30965     1437888 :   while (1) {
   30966     1437888 :     __pyx_t_1 = (__pyx_v_a != (__pyx_v_mergetable[__pyx_v_a]));
   30967     1437888 :     if (!__pyx_t_1) break;
   30968             : 
   30969             :     /* "_ni_label.pyx":128
   30970             :  *     # find smallest root for each of a and b
   30971             :  *     while a != mergetable[a]:
   30972             :  *         a = mergetable[a]             # <<<<<<<<<<<<<<
   30973             :  *     while b != mergetable[b]:
   30974             :  *         b = mergetable[b]
   30975             :  */
   30976             :     __pyx_v_a = (__pyx_v_mergetable[__pyx_v_a]);
   30977             :   }
   30978             : 
   30979             :   /* "_ni_label.pyx":129
   30980             :  *     while a != mergetable[a]:
   30981             :  *         a = mergetable[a]
   30982             :  *     while b != mergetable[b]:             # <<<<<<<<<<<<<<
   30983             :  *         b = mergetable[b]
   30984             :  *     minlabel = a if (a < b) else b
   30985             :  */
   30986     1458905 :   while (1) {
   30987     1458905 :     __pyx_t_1 = (__pyx_v_b != (__pyx_v_mergetable[__pyx_v_b]));
   30988     1458905 :     if (!__pyx_t_1) break;
   30989             : 
   30990             :     /* "_ni_label.pyx":130
   30991             :  *         a = mergetable[a]
   30992             :  *     while b != mergetable[b]:
   30993             :  *         b = mergetable[b]             # <<<<<<<<<<<<<<
   30994             :  *     minlabel = a if (a < b) else b
   30995             :  * 
   30996             :  */
   30997             :     __pyx_v_b = (__pyx_v_mergetable[__pyx_v_b]);
   30998             :   }
   30999             : 
   31000             :   /* "_ni_label.pyx":131
   31001             :  *     while b != mergetable[b]:
   31002             :  *         b = mergetable[b]
   31003             :  *     minlabel = a if (a < b) else b             # <<<<<<<<<<<<<<
   31004             :  * 
   31005             :  *     # merge roots
   31006             :  */
   31007      853387 :   __pyx_t_1 = (__pyx_v_a < __pyx_v_b);
   31008      853387 :   if (__pyx_t_1) {
   31009             :     __pyx_t_2 = __pyx_v_a;
   31010             :   } else {
   31011             :     __pyx_t_2 = __pyx_v_b;
   31012             :   }
   31013      853387 :   __pyx_v_minlabel = __pyx_t_2;
   31014             : 
   31015             :   /* "_ni_label.pyx":134
   31016             :  * 
   31017             :  *     # merge roots
   31018             :  *     mergetable[a] = mergetable[b] = minlabel             # <<<<<<<<<<<<<<
   31019             :  * 
   31020             :  *     # merge every step to minlabel
   31021             :  */
   31022      853387 :   (__pyx_v_mergetable[__pyx_v_a]) = __pyx_v_minlabel;
   31023      853387 :   (__pyx_v_mergetable[__pyx_v_b]) = __pyx_v_minlabel;
   31024             : 
   31025             :   /* "_ni_label.pyx":137
   31026             :  * 
   31027             :  *     # merge every step to minlabel
   31028             :  *     a = orig_a             # <<<<<<<<<<<<<<
   31029             :  *     b = orig_b
   31030             :  *     while a != minlabel:
   31031             :  */
   31032      853387 :   __pyx_v_a = __pyx_v_orig_a;
   31033             : 
   31034             :   /* "_ni_label.pyx":138
   31035             :  *     # merge every step to minlabel
   31036             :  *     a = orig_a
   31037             :  *     b = orig_b             # <<<<<<<<<<<<<<
   31038             :  *     while a != minlabel:
   31039             :  *         a, mergetable[a] = mergetable[a], minlabel
   31040             :  */
   31041      853387 :   __pyx_v_b = __pyx_v_orig_b;
   31042             : 
   31043             :   /* "_ni_label.pyx":139
   31044             :  *     a = orig_a
   31045             :  *     b = orig_b
   31046             :  *     while a != minlabel:             # <<<<<<<<<<<<<<
   31047             :  *         a, mergetable[a] = mergetable[a], minlabel
   31048             :  *     while b != minlabel:
   31049             :  */
   31050     2192585 :   while (1) {
   31051     1522986 :     __pyx_t_1 = (__pyx_v_a != __pyx_v_minlabel);
   31052     1522986 :     if (!__pyx_t_1) break;
   31053             : 
   31054             :     /* "_ni_label.pyx":140
   31055             :  *     b = orig_b
   31056             :  *     while a != minlabel:
   31057             :  *         a, mergetable[a] = mergetable[a], minlabel             # <<<<<<<<<<<<<<
   31058             :  *     while b != minlabel:
   31059             :  *         b, mergetable[b] = mergetable[b], minlabel
   31060             :  */
   31061      669599 :     __pyx_t_2 = (__pyx_v_mergetable[__pyx_v_a]);
   31062      669599 :     __pyx_t_3 = __pyx_v_minlabel;
   31063      669599 :     __pyx_v_a = __pyx_t_2;
   31064      669599 :     (__pyx_v_mergetable[__pyx_v_a]) = __pyx_t_3;
   31065             :   }
   31066             : 
   31067             :   /* "_ni_label.pyx":141
   31068             :  *     while a != minlabel:
   31069             :  *         a, mergetable[a] = mergetable[a], minlabel
   31070             :  *     while b != minlabel:             # <<<<<<<<<<<<<<
   31071             :  *         b, mergetable[b] = mergetable[b], minlabel
   31072             :  * 
   31073             :  */
   31074     2116315 :   while (1) {
   31075     1484851 :     __pyx_t_1 = (__pyx_v_b != __pyx_v_minlabel);
   31076     1484851 :     if (!__pyx_t_1) break;
   31077             : 
   31078             :     /* "_ni_label.pyx":142
   31079             :  *         a, mergetable[a] = mergetable[a], minlabel
   31080             :  *     while b != minlabel:
   31081             :  *         b, mergetable[b] = mergetable[b], minlabel             # <<<<<<<<<<<<<<
   31082             :  * 
   31083             :  *     return minlabel
   31084             :  */
   31085      631464 :     __pyx_t_3 = (__pyx_v_mergetable[__pyx_v_b]);
   31086      631464 :     __pyx_t_2 = __pyx_v_minlabel;
   31087      631464 :     __pyx_v_b = __pyx_t_3;
   31088      631464 :     (__pyx_v_mergetable[__pyx_v_b]) = __pyx_t_2;
   31089             :   }
   31090             : 
   31091             :   /* "_ni_label.pyx":144
   31092             :  *         b, mergetable[b] = mergetable[b], minlabel
   31093             :  * 
   31094             :  *     return minlabel             # <<<<<<<<<<<<<<
   31095             :  * 
   31096             :  * 
   31097             :  */
   31098      853387 :   __pyx_r = __pyx_v_minlabel;
   31099      853387 :   goto __pyx_L0;
   31100             : 
   31101             :   /* "_ni_label.pyx":117
   31102             :  * # Mark two labels to be merged
   31103             :  * ######################################################################
   31104             :  * cdef inline np.uintp_t mark_for_merge(np.uintp_t a,             # <<<<<<<<<<<<<<
   31105             :  *                                       np.uintp_t b,
   31106             :  *                                       np.uintp_t *mergetable) noexcept nogil:
   31107             :  */
   31108             : 
   31109             :   /* function exit code */
   31110      853387 :   __pyx_L0:;
   31111      853387 :   return __pyx_r;
   31112             : }
   31113             : 
   31114             : /* "_ni_label.pyx":150
   31115             :  * # Take the label of a neighbor, or mark them for merging
   31116             :  * ######################################################################
   31117             :  * cdef inline np.uintp_t take_label_or_merge(np.uintp_t cur_label,             # <<<<<<<<<<<<<<
   31118             :  *                                            np.uintp_t neighbor_label,
   31119             :  *                                            np.uintp_t *mergetable) noexcept nogil:
   31120             :  */
   31121             : 
   31122    13893152 : static CYTHON_INLINE __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_take_label_or_merge(__pyx_t_5numpy_uintp_t __pyx_v_cur_label, __pyx_t_5numpy_uintp_t __pyx_v_neighbor_label, __pyx_t_5numpy_uintp_t *__pyx_v_mergetable) {
   31123    13893152 :   __pyx_t_5numpy_uintp_t __pyx_r;
   31124    13893152 :   int __pyx_t_1;
   31125             : 
   31126             :   /* "_ni_label.pyx":153
   31127             :  *                                            np.uintp_t neighbor_label,
   31128             :  *                                            np.uintp_t *mergetable) noexcept nogil:
   31129             :  *     if neighbor_label == BACKGROUND:             # <<<<<<<<<<<<<<
   31130             :  *         return cur_label
   31131             :  *     if cur_label == FOREGROUND:
   31132             :  */
   31133    13893152 :   __pyx_t_1 = (__pyx_v_neighbor_label == __pyx_e_9_ni_label_BACKGROUND);
   31134    13893152 :   if (__pyx_t_1) {
   31135             : 
   31136             :     /* "_ni_label.pyx":154
   31137             :  *                                            np.uintp_t *mergetable) noexcept nogil:
   31138             :  *     if neighbor_label == BACKGROUND:
   31139             :  *         return cur_label             # <<<<<<<<<<<<<<
   31140             :  *     if cur_label == FOREGROUND:
   31141             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31142             :  */
   31143     9676979 :     __pyx_r = __pyx_v_cur_label;
   31144     9676979 :     goto __pyx_L0;
   31145             : 
   31146             :     /* "_ni_label.pyx":153
   31147             :  *                                            np.uintp_t neighbor_label,
   31148             :  *                                            np.uintp_t *mergetable) noexcept nogil:
   31149             :  *     if neighbor_label == BACKGROUND:             # <<<<<<<<<<<<<<
   31150             :  *         return cur_label
   31151             :  *     if cur_label == FOREGROUND:
   31152             :  */
   31153             :   }
   31154             : 
   31155             :   /* "_ni_label.pyx":155
   31156             :  *     if neighbor_label == BACKGROUND:
   31157             :  *         return cur_label
   31158             :  *     if cur_label == FOREGROUND:             # <<<<<<<<<<<<<<
   31159             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31160             :  *     if neighbor_label:
   31161             :  */
   31162     4216173 :   __pyx_t_1 = (__pyx_v_cur_label == __pyx_e_9_ni_label_FOREGROUND);
   31163     4216173 :   if (__pyx_t_1) {
   31164             : 
   31165             :     /* "_ni_label.pyx":156
   31166             :  *         return cur_label
   31167             :  *     if cur_label == FOREGROUND:
   31168             :  *         return neighbor_label  # neighbor is not BACKGROUND             # <<<<<<<<<<<<<<
   31169             :  *     if neighbor_label:
   31170             :  *         if cur_label != neighbor_label:
   31171             :  */
   31172     1282535 :     __pyx_r = __pyx_v_neighbor_label;
   31173     1282535 :     goto __pyx_L0;
   31174             : 
   31175             :     /* "_ni_label.pyx":155
   31176             :  *     if neighbor_label == BACKGROUND:
   31177             :  *         return cur_label
   31178             :  *     if cur_label == FOREGROUND:             # <<<<<<<<<<<<<<
   31179             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31180             :  *     if neighbor_label:
   31181             :  */
   31182             :   }
   31183             : 
   31184             :   /* "_ni_label.pyx":157
   31185             :  *     if cur_label == FOREGROUND:
   31186             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31187             :  *     if neighbor_label:             # <<<<<<<<<<<<<<
   31188             :  *         if cur_label != neighbor_label:
   31189             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)
   31190             :  */
   31191     2933638 :   __pyx_t_1 = (__pyx_v_neighbor_label != 0);
   31192     2933638 :   if (__pyx_t_1) {
   31193             : 
   31194             :     /* "_ni_label.pyx":158
   31195             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31196             :  *     if neighbor_label:
   31197             :  *         if cur_label != neighbor_label:             # <<<<<<<<<<<<<<
   31198             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)
   31199             :  *     return cur_label
   31200             :  */
   31201     2933638 :     __pyx_t_1 = (__pyx_v_cur_label != __pyx_v_neighbor_label);
   31202     2933638 :     if (__pyx_t_1) {
   31203             : 
   31204             :       /* "_ni_label.pyx":159
   31205             :  *     if neighbor_label:
   31206             :  *         if cur_label != neighbor_label:
   31207             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)             # <<<<<<<<<<<<<<
   31208             :  *     return cur_label
   31209             :  * 
   31210             :  */
   31211      853387 :       __pyx_v_cur_label = __pyx_f_9_ni_label_mark_for_merge(__pyx_v_neighbor_label, __pyx_v_cur_label, __pyx_v_mergetable);
   31212             : 
   31213             :       /* "_ni_label.pyx":158
   31214             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31215             :  *     if neighbor_label:
   31216             :  *         if cur_label != neighbor_label:             # <<<<<<<<<<<<<<
   31217             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)
   31218             :  *     return cur_label
   31219             :  */
   31220             :     }
   31221             : 
   31222             :     /* "_ni_label.pyx":157
   31223             :  *     if cur_label == FOREGROUND:
   31224             :  *         return neighbor_label  # neighbor is not BACKGROUND
   31225             :  *     if neighbor_label:             # <<<<<<<<<<<<<<
   31226             :  *         if cur_label != neighbor_label:
   31227             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)
   31228             :  */
   31229             :   }
   31230             : 
   31231             :   /* "_ni_label.pyx":160
   31232             :  *         if cur_label != neighbor_label:
   31233             :  *             cur_label = mark_for_merge(neighbor_label, cur_label, mergetable)
   31234             :  *     return cur_label             # <<<<<<<<<<<<<<
   31235             :  * 
   31236             :  * 
   31237             :  */
   31238     2933638 :   __pyx_r = __pyx_v_cur_label;
   31239     2933638 :   goto __pyx_L0;
   31240             : 
   31241             :   /* "_ni_label.pyx":150
   31242             :  * # Take the label of a neighbor, or mark them for merging
   31243             :  * ######################################################################
   31244             :  * cdef inline np.uintp_t take_label_or_merge(np.uintp_t cur_label,             # <<<<<<<<<<<<<<
   31245             :  *                                            np.uintp_t neighbor_label,
   31246             :  *                                            np.uintp_t *mergetable) noexcept nogil:
   31247             :  */
   31248             : 
   31249             :   /* function exit code */
   31250    13893152 :   __pyx_L0:;
   31251    13893152 :   return __pyx_r;
   31252             : }
   31253             : 
   31254             : /* "_ni_label.pyx":166
   31255             :  * # Label one line of input, using a neighbor line that has already been labeled.
   31256             :  * ######################################################################
   31257             :  * cdef np.uintp_t label_line_with_neighbor(np.uintp_t *line,             # <<<<<<<<<<<<<<
   31258             :  *                                          np.uintp_t *neighbor,
   31259             :  *                                          int neighbor_use_previous,
   31260             :  */
   31261             : 
   31262       11896 : static __pyx_t_5numpy_uintp_t __pyx_f_9_ni_label_label_line_with_neighbor(__pyx_t_5numpy_uintp_t *__pyx_v_line, __pyx_t_5numpy_uintp_t *__pyx_v_neighbor, int __pyx_v_neighbor_use_previous, int __pyx_v_neighbor_use_adjacent, int __pyx_v_neighbor_use_next, __pyx_t_5numpy_intp_t __pyx_v_L, int __pyx_v_label_unlabeled, int __pyx_v_use_previous, __pyx_t_5numpy_uintp_t __pyx_v_next_region, __pyx_t_5numpy_uintp_t *__pyx_v_mergetable) {
   31263       11896 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   31264       11896 :   __pyx_t_5numpy_uintp_t __pyx_r;
   31265       11896 :   __pyx_t_5numpy_intp_t __pyx_t_1;
   31266       11896 :   __pyx_t_5numpy_intp_t __pyx_t_2;
   31267       11896 :   __pyx_t_5numpy_intp_t __pyx_t_3;
   31268       11896 :   int __pyx_t_4;
   31269             : 
   31270             :   /* "_ni_label.pyx":179
   31271             :  *         np.intp_t i
   31272             :  * 
   31273             :  *     for i in range(L):             # <<<<<<<<<<<<<<
   31274             :  *         if line[i] != BACKGROUND:
   31275             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31276             :  */
   31277       11896 :   __pyx_t_1 = __pyx_v_L;
   31278       11896 :   __pyx_t_2 = __pyx_t_1;
   31279    13870799 :   for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
   31280    13858903 :     __pyx_v_i = __pyx_t_3;
   31281             : 
   31282             :     /* "_ni_label.pyx":180
   31283             :  * 
   31284             :  *     for i in range(L):
   31285             :  *         if line[i] != BACKGROUND:             # <<<<<<<<<<<<<<
   31286             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31287             :  *             if neighbor_use_previous:
   31288             :  */
   31289    13858903 :     __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) != __pyx_e_9_ni_label_BACKGROUND);
   31290    13858903 :     if (__pyx_t_4) {
   31291             : 
   31292             :       /* "_ni_label.pyx":182
   31293             :  *         if line[i] != BACKGROUND:
   31294             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31295             :  *             if neighbor_use_previous:             # <<<<<<<<<<<<<<
   31296             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)
   31297             :  *             if neighbor_use_adjacent:
   31298             :  */
   31299     4166502 :       __pyx_t_4 = (__pyx_v_neighbor_use_previous != 0);
   31300     4166502 :       if (__pyx_t_4) {
   31301             : 
   31302             :         /* "_ni_label.pyx":183
   31303             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31304             :  *             if neighbor_use_previous:
   31305             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)             # <<<<<<<<<<<<<<
   31306             :  *             if neighbor_use_adjacent:
   31307             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31308             :  */
   31309     4163185 :         (__pyx_v_line[__pyx_v_i]) = __pyx_f_9_ni_label_take_label_or_merge((__pyx_v_line[__pyx_v_i]), (__pyx_v_neighbor[(__pyx_v_i - 1)]), __pyx_v_mergetable);
   31310             : 
   31311             :         /* "_ni_label.pyx":182
   31312             :  *         if line[i] != BACKGROUND:
   31313             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31314             :  *             if neighbor_use_previous:             # <<<<<<<<<<<<<<
   31315             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)
   31316             :  *             if neighbor_use_adjacent:
   31317             :  */
   31318             :       }
   31319             : 
   31320             :       /* "_ni_label.pyx":184
   31321             :  *             if neighbor_use_previous:
   31322             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)
   31323             :  *             if neighbor_use_adjacent:             # <<<<<<<<<<<<<<
   31324             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31325             :  *             if neighbor_use_next:
   31326             :  */
   31327     4166502 :       __pyx_t_4 = (__pyx_v_neighbor_use_adjacent != 0);
   31328     4166502 :       if (__pyx_t_4) {
   31329             : 
   31330             :         /* "_ni_label.pyx":185
   31331             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)
   31332             :  *             if neighbor_use_adjacent:
   31333             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)             # <<<<<<<<<<<<<<
   31334             :  *             if neighbor_use_next:
   31335             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31336             :  */
   31337     4163977 :         (__pyx_v_line[__pyx_v_i]) = __pyx_f_9_ni_label_take_label_or_merge((__pyx_v_line[__pyx_v_i]), (__pyx_v_neighbor[__pyx_v_i]), __pyx_v_mergetable);
   31338             : 
   31339             :         /* "_ni_label.pyx":184
   31340             :  *             if neighbor_use_previous:
   31341             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i - 1], mergetable)
   31342             :  *             if neighbor_use_adjacent:             # <<<<<<<<<<<<<<
   31343             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31344             :  *             if neighbor_use_next:
   31345             :  */
   31346             :       }
   31347             : 
   31348             :       /* "_ni_label.pyx":186
   31349             :  *             if neighbor_use_adjacent:
   31350             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31351             :  *             if neighbor_use_next:             # <<<<<<<<<<<<<<
   31352             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31353             :  *             if label_unlabeled:
   31354             :  */
   31355     4166502 :       __pyx_t_4 = (__pyx_v_neighbor_use_next != 0);
   31356     4166502 :       if (__pyx_t_4) {
   31357             : 
   31358             :         /* "_ni_label.pyx":187
   31359             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31360             :  *             if neighbor_use_next:
   31361             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)             # <<<<<<<<<<<<<<
   31362             :  *             if label_unlabeled:
   31363             :  *                 if use_previous:
   31364             :  */
   31365     4163185 :         (__pyx_v_line[__pyx_v_i]) = __pyx_f_9_ni_label_take_label_or_merge((__pyx_v_line[__pyx_v_i]), (__pyx_v_neighbor[(__pyx_v_i + 1)]), __pyx_v_mergetable);
   31366             : 
   31367             :         /* "_ni_label.pyx":186
   31368             :  *             if neighbor_use_adjacent:
   31369             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i], mergetable)
   31370             :  *             if neighbor_use_next:             # <<<<<<<<<<<<<<
   31371             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31372             :  *             if label_unlabeled:
   31373             :  */
   31374             :       }
   31375             : 
   31376             :       /* "_ni_label.pyx":188
   31377             :  *             if neighbor_use_next:
   31378             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31379             :  *             if label_unlabeled:             # <<<<<<<<<<<<<<
   31380             :  *                 if use_previous:
   31381             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31382             :  */
   31383     4166502 :       if (__pyx_v_label_unlabeled) {
   31384             : 
   31385             :         /* "_ni_label.pyx":189
   31386             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31387             :  *             if label_unlabeled:
   31388             :  *                 if use_previous:             # <<<<<<<<<<<<<<
   31389             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31390             :  *                 if line[i] == FOREGROUND:  # still needs a label
   31391             :  */
   31392     1403526 :         if (__pyx_v_use_previous) {
   31393             : 
   31394             :           /* "_ni_label.pyx":190
   31395             :  *             if label_unlabeled:
   31396             :  *                 if use_previous:
   31397             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)             # <<<<<<<<<<<<<<
   31398             :  *                 if line[i] == FOREGROUND:  # still needs a label
   31399             :  *                     line[i] = next_region
   31400             :  */
   31401     1402805 :           (__pyx_v_line[__pyx_v_i]) = __pyx_f_9_ni_label_take_label_or_merge((__pyx_v_line[__pyx_v_i]), (__pyx_v_line[(__pyx_v_i - 1)]), __pyx_v_mergetable);
   31402             : 
   31403             :           /* "_ni_label.pyx":189
   31404             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31405             :  *             if label_unlabeled:
   31406             :  *                 if use_previous:             # <<<<<<<<<<<<<<
   31407             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31408             :  *                 if line[i] == FOREGROUND:  # still needs a label
   31409             :  */
   31410             :         }
   31411             : 
   31412             :         /* "_ni_label.pyx":191
   31413             :  *                 if use_previous:
   31414             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31415             :  *                 if line[i] == FOREGROUND:  # still needs a label             # <<<<<<<<<<<<<<
   31416             :  *                     line[i] = next_region
   31417             :  *                     mergetable[next_region] = next_region
   31418             :  */
   31419     1403526 :         __pyx_t_4 = ((__pyx_v_line[__pyx_v_i]) == __pyx_e_9_ni_label_FOREGROUND);
   31420     1403526 :         if (__pyx_t_4) {
   31421             : 
   31422             :           /* "_ni_label.pyx":192
   31423             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31424             :  *                 if line[i] == FOREGROUND:  # still needs a label
   31425             :  *                     line[i] = next_region             # <<<<<<<<<<<<<<
   31426             :  *                     mergetable[next_region] = next_region
   31427             :  *                     next_region += 1
   31428             :  */
   31429      120991 :           (__pyx_v_line[__pyx_v_i]) = __pyx_v_next_region;
   31430             : 
   31431             :           /* "_ni_label.pyx":193
   31432             :  *                 if line[i] == FOREGROUND:  # still needs a label
   31433             :  *                     line[i] = next_region
   31434             :  *                     mergetable[next_region] = next_region             # <<<<<<<<<<<<<<
   31435             :  *                     next_region += 1
   31436             :  *     return next_region
   31437             :  */
   31438      120991 :           (__pyx_v_mergetable[__pyx_v_next_region]) = __pyx_v_next_region;
   31439             : 
   31440             :           /* "_ni_label.pyx":194
   31441             :  *                     line[i] = next_region
   31442             :  *                     mergetable[next_region] = next_region
   31443             :  *                     next_region += 1             # <<<<<<<<<<<<<<
   31444             :  *     return next_region
   31445             :  * 
   31446             :  */
   31447      120991 :           __pyx_v_next_region = (__pyx_v_next_region + 1);
   31448             : 
   31449             :           /* "_ni_label.pyx":191
   31450             :  *                 if use_previous:
   31451             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31452             :  *                 if line[i] == FOREGROUND:  # still needs a label             # <<<<<<<<<<<<<<
   31453             :  *                     line[i] = next_region
   31454             :  *                     mergetable[next_region] = next_region
   31455             :  */
   31456             :         }
   31457             : 
   31458             :         /* "_ni_label.pyx":188
   31459             :  *             if neighbor_use_next:
   31460             :  *                 line[i] = take_label_or_merge(line[i], neighbor[i + 1], mergetable)
   31461             :  *             if label_unlabeled:             # <<<<<<<<<<<<<<
   31462             :  *                 if use_previous:
   31463             :  *                     line[i] = take_label_or_merge(line[i], line[i - 1], mergetable)
   31464             :  */
   31465             :       }
   31466             : 
   31467             :       /* "_ni_label.pyx":180
   31468             :  * 
   31469             :  *     for i in range(L):
   31470             :  *         if line[i] != BACKGROUND:             # <<<<<<<<<<<<<<
   31471             :  *             # See allocation of line_buffer for why this is valid when i = 0
   31472             :  *             if neighbor_use_previous:
   31473             :  */
   31474             :     }
   31475             :   }
   31476             : 
   31477             :   /* "_ni_label.pyx":195
   31478             :  *                     mergetable[next_region] = next_region
   31479             :  *                     next_region += 1
   31480             :  *     return next_region             # <<<<<<<<<<<<<<
   31481             :  * 
   31482             :  * ######################################################################
   31483             :  */
   31484       11896 :   __pyx_r = __pyx_v_next_region;
   31485       11896 :   goto __pyx_L0;
   31486             : 
   31487             :   /* "_ni_label.pyx":166
   31488             :  * # Label one line of input, using a neighbor line that has already been labeled.
   31489             :  * ######################################################################
   31490             :  * cdef np.uintp_t label_line_with_neighbor(np.uintp_t *line,             # <<<<<<<<<<<<<<
   31491             :  *                                          np.uintp_t *neighbor,
   31492             :  *                                          int neighbor_use_previous,
   31493             :  */
   31494             : 
   31495             :   /* function exit code */
   31496       11896 :   __pyx_L0:;
   31497       11896 :   return __pyx_r;
   31498             : }
   31499             : 
   31500             : /* "_ni_label.pyx":200
   31501             :  * # Label regions
   31502             :  * ######################################################################
   31503             :  * cpdef _label(np.ndarray input,             # <<<<<<<<<<<<<<
   31504             :  *              np.ndarray structure,
   31505             :  *              np.ndarray output):
   31506             :  */
   31507             : 
   31508             : static PyObject *__pyx_pw_9_ni_label_7_label(PyObject *__pyx_self, 
   31509             : #if CYTHON_METH_FASTCALL
   31510             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   31511             : #else
   31512             : PyObject *__pyx_args, PyObject *__pyx_kwds
   31513             : #endif
   31514             : ); /*proto*/
   31515         119 : static PyObject *__pyx_f_9_ni_label__label(PyArrayObject *__pyx_v_input, PyArrayObject *__pyx_v_structure, PyArrayObject *__pyx_v_output, CYTHON_UNUSED int __pyx_skip_dispatch) {
   31516         119 :   __pyx_t_9_ni_label_nonzero_line_func_t __pyx_v_nonzero_line;
   31517         119 :   __pyx_t_9_ni_label_read_line_func_t __pyx_v_read_line;
   31518         119 :   __pyx_t_9_ni_label_write_line_func_t __pyx_v_write_line;
   31519         119 :   PyArrayIterObject *__pyx_v__iti = 0;
   31520         119 :   PyArrayIterObject *__pyx_v__ito = 0;
   31521         119 :   PyArrayIterObject *__pyx_v__itstruct = 0;
   31522         119 :   PyArrayIterObject *__pyx_v_iti;
   31523         119 :   PyArrayIterObject *__pyx_v_ito;
   31524         119 :   PyArrayIterObject *__pyx_v_itstruct;
   31525         119 :   int __pyx_v_axis;
   31526         119 :   int __pyx_v_idim;
   31527         119 :   int __pyx_v_num_neighbors;
   31528         119 :   int __pyx_v_ni;
   31529         119 :   __pyx_t_5numpy_intp_t __pyx_v_L;
   31530         119 :   __pyx_t_5numpy_intp_t __pyx_v_delta;
   31531         119 :   __pyx_t_5numpy_intp_t __pyx_v_i;
   31532         119 :   __pyx_t_5numpy_intp_t __pyx_v_si;
   31533         119 :   __pyx_t_5numpy_intp_t __pyx_v_so;
   31534         119 :   __pyx_t_5numpy_intp_t __pyx_v_ss;
   31535         119 :   __pyx_t_5numpy_intp_t __pyx_v_total_offset;
   31536         119 :   __pyx_t_5numpy_intp_t __pyx_v_output_ndim;
   31537         119 :   __pyx_t_5numpy_intp_t __pyx_v_structure_ndim;
   31538         119 :   int __pyx_v_needs_self_labeling;
   31539         119 :   int __pyx_v_valid;
   31540         119 :   int __pyx_v_use_previous;
   31541         119 :   int __pyx_v_overflowed;
   31542         119 :   PyArrayObject *__pyx_v__line_buffer = 0;
   31543         119 :   PyArrayObject *__pyx_v__neighbor_buffer = 0;
   31544         119 :   __pyx_t_5numpy_uintp_t *__pyx_v_line_buffer;
   31545         119 :   __pyx_t_5numpy_uintp_t *__pyx_v_neighbor_buffer;
   31546         119 :   __pyx_t_5numpy_uintp_t *__pyx_v_tmp;
   31547         119 :   __pyx_t_5numpy_uintp_t __pyx_v_next_region;
   31548         119 :   __pyx_t_5numpy_uintp_t __pyx_v_src_label;
   31549         119 :   __pyx_t_5numpy_uintp_t __pyx_v_dest_label;
   31550         119 :   __pyx_t_5numpy_uintp_t __pyx_v_mergetable_size;
   31551         119 :   __pyx_t_5numpy_uintp_t *__pyx_v_mergetable;
   31552         119 :   PyObject *__pyx_v_temp = NULL;
   31553         119 :   npy_intp *__pyx_v_output_shape;
   31554         119 :   npy_intp *__pyx_v_output_strides;
   31555         119 :   npy_bool __pyx_v_neighbor_use_prev;
   31556         119 :   npy_bool __pyx_v_neighbor_use_adjacent;
   31557         119 :   npy_bool __pyx_v_neighbor_use_next;
   31558         119 :   PyObject *__pyx_r = NULL;
   31559             :   __Pyx_RefNannyDeclarations
   31560         119 :   PyObject *__pyx_t_1 = NULL;
   31561         119 :   PyObject *__pyx_t_2 = NULL;
   31562         119 :   PyObject *__pyx_t_3 = NULL;
   31563         119 :   int __pyx_t_4;
   31564         119 :   PyObject *__pyx_t_5 = NULL;
   31565         119 :   PyObject *__pyx_t_6 = NULL;
   31566         119 :   unsigned int __pyx_t_7;
   31567         119 :   PyObject *__pyx_t_8 = NULL;
   31568         119 :   int __pyx_t_9;
   31569         119 :   int __pyx_t_10;
   31570         119 :   Py_intptr_t __pyx_t_11;
   31571         119 :   PyObject *__pyx_t_12 = NULL;
   31572         119 :   PyObject *__pyx_t_13 = NULL;
   31573         119 :   PyObject *__pyx_t_14 = NULL;
   31574         119 :   int __pyx_t_15;
   31575         119 :   int __pyx_t_16;
   31576         119 :   __pyx_t_5numpy_intp_t __pyx_t_17;
   31577         119 :   __pyx_t_5numpy_intp_t __pyx_t_18;
   31578         119 :   int __pyx_t_19;
   31579         119 :   __pyx_t_5numpy_intp_t __pyx_t_20;
   31580         119 :   __pyx_t_5numpy_uintp_t __pyx_t_21;
   31581         119 :   __pyx_t_5numpy_uintp_t __pyx_t_22;
   31582         119 :   __pyx_t_5numpy_uintp_t __pyx_t_23;
   31583         119 :   int __pyx_lineno = 0;
   31584         119 :   const char *__pyx_filename = NULL;
   31585         119 :   int __pyx_clineno = 0;
   31586         119 :   __Pyx_RefNannySetupContext("_label", 0);
   31587         119 :   __Pyx_INCREF((PyObject *)__pyx_v_input);
   31588         119 :   __Pyx_INCREF((PyObject *)__pyx_v_structure);
   31589         119 :   __Pyx_INCREF((PyObject *)__pyx_v_output);
   31590             : 
   31591             :   /* "_ni_label.pyx":206
   31592             :  *     # To understand the need for the casts to object in order to use
   31593             :  *     # tuple.__eq__, see https://github.com/cython/cython/issues/863
   31594             :  *     assert (<object> input).shape == (<object> output).shape, \             # <<<<<<<<<<<<<<
   31595             :  *         ("Shapes must match for input and output,"
   31596             :  *          "{} != {}".format((<object> input).shape, (<object> output).shape))
   31597             :  */
   31598             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   31599         119 :   if (unlikely(__pyx_assertions_enabled())) {
   31600         119 :     __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_input), __pyx_n_s_shape); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 206, __pyx_L1_error)
   31601         119 :     __Pyx_GOTREF(__pyx_t_1);
   31602         119 :     __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_shape); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 206, __pyx_L1_error)
   31603         119 :     __Pyx_GOTREF(__pyx_t_2);
   31604         119 :     __pyx_t_3 = PyObject_RichCompare(__pyx_t_1, __pyx_t_2, Py_EQ); __Pyx_XGOTREF(__pyx_t_3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 206, __pyx_L1_error)
   31605         119 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31606         119 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31607         119 :     __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 206, __pyx_L1_error)
   31608         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31609         119 :     if (unlikely(!__pyx_t_4)) {
   31610             : 
   31611             :       /* "_ni_label.pyx":208
   31612             :  *     assert (<object> input).shape == (<object> output).shape, \
   31613             :  *         ("Shapes must match for input and output,"
   31614             :  *          "{} != {}".format((<object> input).shape, (<object> output).shape))             # <<<<<<<<<<<<<<
   31615             :  * 
   31616             :  *     structure = np.asanyarray(structure, dtype=np.bool_).copy()
   31617             :  */
   31618           0 :       __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_Shapes_must_match_for_input_and, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 208, __pyx_L1_error)
   31619           0 :       __Pyx_GOTREF(__pyx_t_2);
   31620           0 :       __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_input), __pyx_n_s_shape); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 208, __pyx_L1_error)
   31621           0 :       __Pyx_GOTREF(__pyx_t_1);
   31622           0 :       __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_shape); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 208, __pyx_L1_error)
   31623           0 :       __Pyx_GOTREF(__pyx_t_5);
   31624           0 :       __pyx_t_6 = NULL;
   31625           0 :       __pyx_t_7 = 0;
   31626             :       #if CYTHON_UNPACK_METHODS
   31627           0 :       if (likely(PyMethod_Check(__pyx_t_2))) {
   31628           0 :         __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2);
   31629           0 :         if (likely(__pyx_t_6)) {
   31630           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
   31631           0 :           __Pyx_INCREF(__pyx_t_6);
   31632           0 :           __Pyx_INCREF(function);
   31633           0 :           __Pyx_DECREF_SET(__pyx_t_2, function);
   31634             :           __pyx_t_7 = 1;
   31635             :         }
   31636             :       }
   31637             :       #endif
   31638             :       {
   31639           0 :         PyObject *__pyx_callargs[3] = {__pyx_t_6, __pyx_t_1, __pyx_t_5};
   31640           0 :         __pyx_t_3 = __Pyx_PyObject_FastCall(__pyx_t_2, __pyx_callargs+1-__pyx_t_7, 2+__pyx_t_7);
   31641           0 :         __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   31642           0 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31643           0 :         __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   31644           0 :         if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 208, __pyx_L1_error)
   31645           0 :         __Pyx_GOTREF(__pyx_t_3);
   31646           0 :         __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31647             :       }
   31648           0 :       __pyx_t_2 = PyTuple_Pack(1, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 208, __pyx_L1_error)
   31649           0 :       __Pyx_GOTREF(__pyx_t_2);
   31650           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31651           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, __pyx_t_2, 0, 0);
   31652           0 :       __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31653           0 :       __PYX_ERR(0, 206, __pyx_L1_error)
   31654             :     }
   31655             :   }
   31656             :   #else
   31657             :   if ((1)); else __PYX_ERR(0, 206, __pyx_L1_error)
   31658             :   #endif
   31659             : 
   31660             :   /* "_ni_label.pyx":210
   31661             :  *          "{} != {}".format((<object> input).shape, (<object> output).shape))
   31662             :  * 
   31663             :  *     structure = np.asanyarray(structure, dtype=np.bool_).copy()             # <<<<<<<<<<<<<<
   31664             :  *     assert input.ndim == structure.ndim, \
   31665             :  *         ("Structuring element must have same "
   31666             :  */
   31667         119 :   __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 210, __pyx_L1_error)
   31668         119 :   __Pyx_GOTREF(__pyx_t_3);
   31669         119 :   __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asanyarray); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 210, __pyx_L1_error)
   31670         119 :   __Pyx_GOTREF(__pyx_t_5);
   31671         119 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31672         119 :   __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 210, __pyx_L1_error)
   31673         119 :   __Pyx_GOTREF(__pyx_t_3);
   31674         119 :   __Pyx_INCREF((PyObject *)__pyx_v_structure);
   31675         119 :   __Pyx_GIVEREF((PyObject *)__pyx_v_structure);
   31676         119 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_v_structure))) __PYX_ERR(0, 210, __pyx_L1_error);
   31677         119 :   __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 210, __pyx_L1_error)
   31678         119 :   __Pyx_GOTREF(__pyx_t_1);
   31679         119 :   __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_np); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 210, __pyx_L1_error)
   31680         119 :   __Pyx_GOTREF(__pyx_t_6);
   31681         119 :   __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_bool); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 210, __pyx_L1_error)
   31682         119 :   __Pyx_GOTREF(__pyx_t_8);
   31683         119 :   __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
   31684         119 :   if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_dtype, __pyx_t_8) < 0) __PYX_ERR(0, 210, __pyx_L1_error)
   31685         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31686         119 :   __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_3, __pyx_t_1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 210, __pyx_L1_error)
   31687         119 :   __Pyx_GOTREF(__pyx_t_8);
   31688         119 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   31689         119 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31690         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31691         119 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_copy); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 210, __pyx_L1_error)
   31692         119 :   __Pyx_GOTREF(__pyx_t_1);
   31693         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31694         119 :   __pyx_t_8 = NULL;
   31695         119 :   __pyx_t_7 = 0;
   31696             :   #if CYTHON_UNPACK_METHODS
   31697         119 :   if (likely(PyMethod_Check(__pyx_t_1))) {
   31698           0 :     __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_1);
   31699           0 :     if (likely(__pyx_t_8)) {
   31700           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
   31701           0 :       __Pyx_INCREF(__pyx_t_8);
   31702           0 :       __Pyx_INCREF(function);
   31703           0 :       __Pyx_DECREF_SET(__pyx_t_1, function);
   31704             :       __pyx_t_7 = 1;
   31705             :     }
   31706             :   }
   31707             :   #endif
   31708             :   {
   31709         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_8, NULL};
   31710         119 :     __pyx_t_2 = __Pyx_PyObject_FastCall(__pyx_t_1, __pyx_callargs+1-__pyx_t_7, 0+__pyx_t_7);
   31711         119 :     __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   31712         119 :     if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 210, __pyx_L1_error)
   31713         119 :     __Pyx_GOTREF(__pyx_t_2);
   31714         119 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31715             :   }
   31716         119 :   if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(0, 210, __pyx_L1_error)
   31717         119 :   __Pyx_DECREF_SET(__pyx_v_structure, ((PyArrayObject *)__pyx_t_2));
   31718         119 :   __pyx_t_2 = 0;
   31719             : 
   31720             :   /* "_ni_label.pyx":211
   31721             :  * 
   31722             :  *     structure = np.asanyarray(structure, dtype=np.bool_).copy()
   31723             :  *     assert input.ndim == structure.ndim, \             # <<<<<<<<<<<<<<
   31724             :  *         ("Structuring element must have same "
   31725             :  *          "# of dimensions as input, "
   31726             :  */
   31727             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   31728         119 :   if (unlikely(__pyx_assertions_enabled())) {
   31729         119 :     __pyx_t_4 = (__pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_input) == __pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_structure));
   31730         119 :     if (unlikely(!__pyx_t_4)) {
   31731             : 
   31732             :       /* "_ni_label.pyx":214
   31733             :  *         ("Structuring element must have same "
   31734             :  *          "# of dimensions as input, "
   31735             :  *          "{:d} != {:d}".format(input.ndim, structure.ndim))             # <<<<<<<<<<<<<<
   31736             :  * 
   31737             :  *     # Check that structuring element is of size 3 in every dimension
   31738             :  */
   31739           0 :       __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_Structuring_element_must_have_sa, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 214, __pyx_L1_error)
   31740           0 :       __Pyx_GOTREF(__pyx_t_1);
   31741           0 :       __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_input)); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 214, __pyx_L1_error)
   31742           0 :       __Pyx_GOTREF(__pyx_t_8);
   31743           0 :       __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_structure)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 214, __pyx_L1_error)
   31744           0 :       __Pyx_GOTREF(__pyx_t_3);
   31745           0 :       __pyx_t_5 = NULL;
   31746           0 :       __pyx_t_7 = 0;
   31747             :       #if CYTHON_UNPACK_METHODS
   31748           0 :       if (likely(PyMethod_Check(__pyx_t_1))) {
   31749           0 :         __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_1);
   31750           0 :         if (likely(__pyx_t_5)) {
   31751           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
   31752           0 :           __Pyx_INCREF(__pyx_t_5);
   31753           0 :           __Pyx_INCREF(function);
   31754           0 :           __Pyx_DECREF_SET(__pyx_t_1, function);
   31755             :           __pyx_t_7 = 1;
   31756             :         }
   31757             :       }
   31758             :       #endif
   31759             :       {
   31760           0 :         PyObject *__pyx_callargs[3] = {__pyx_t_5, __pyx_t_8, __pyx_t_3};
   31761           0 :         __pyx_t_2 = __Pyx_PyObject_FastCall(__pyx_t_1, __pyx_callargs+1-__pyx_t_7, 2+__pyx_t_7);
   31762           0 :         __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   31763           0 :         __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31764           0 :         __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31765           0 :         if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 214, __pyx_L1_error)
   31766           0 :         __Pyx_GOTREF(__pyx_t_2);
   31767           0 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31768             :       }
   31769           0 :       __pyx_t_1 = PyTuple_Pack(1, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 214, __pyx_L1_error)
   31770           0 :       __Pyx_GOTREF(__pyx_t_1);
   31771           0 :       __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31772           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, __pyx_t_1, 0, 0);
   31773           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31774           0 :       __PYX_ERR(0, 211, __pyx_L1_error)
   31775             :     }
   31776             :   }
   31777             :   #else
   31778             :   if ((1)); else __PYX_ERR(0, 211, __pyx_L1_error)
   31779             :   #endif
   31780             : 
   31781             :   /* "_ni_label.pyx":217
   31782             :  * 
   31783             :  *     # Check that structuring element is of size 3 in every dimension
   31784             :  *     assert set((<object> structure).shape) <= set([3]), \             # <<<<<<<<<<<<<<
   31785             :  *         ("Structuring element must be size 3 in every dimension, "
   31786             :  *          "was {}".format((<object> structure).shape))
   31787             :  */
   31788             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   31789         119 :   if (unlikely(__pyx_assertions_enabled())) {
   31790         119 :     __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_structure), __pyx_n_s_shape); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 217, __pyx_L1_error)
   31791         119 :     __Pyx_GOTREF(__pyx_t_1);
   31792         119 :     __pyx_t_2 = PySet_New(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 217, __pyx_L1_error)
   31793         119 :     __Pyx_GOTREF(__pyx_t_2);
   31794         119 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31795         119 :     __pyx_t_1 = PySet_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 217, __pyx_L1_error)
   31796         119 :     __Pyx_GOTREF(__pyx_t_1);
   31797         119 :     if (PySet_Add(__pyx_t_1, __pyx_int_3) < 0) __PYX_ERR(0, 217, __pyx_L1_error)
   31798         119 :     __pyx_t_3 = PyObject_RichCompare(__pyx_t_2, __pyx_t_1, Py_LE); __Pyx_XGOTREF(__pyx_t_3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 217, __pyx_L1_error)
   31799         119 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31800         119 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31801         119 :     __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 217, __pyx_L1_error)
   31802         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31803         119 :     if (unlikely(!__pyx_t_4)) {
   31804             : 
   31805             :       /* "_ni_label.pyx":219
   31806             :  *     assert set((<object> structure).shape) <= set([3]), \
   31807             :  *         ("Structuring element must be size 3 in every dimension, "
   31808             :  *          "was {}".format((<object> structure).shape))             # <<<<<<<<<<<<<<
   31809             :  * 
   31810             :  *     # check structuring element for symmetry
   31811             :  */
   31812           0 :       __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_Structuring_element_must_be_size, __pyx_n_s_format); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 219, __pyx_L1_error)
   31813           0 :       __Pyx_GOTREF(__pyx_t_1);
   31814           0 :       __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_structure), __pyx_n_s_shape); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 219, __pyx_L1_error)
   31815           0 :       __Pyx_GOTREF(__pyx_t_2);
   31816           0 :       __pyx_t_8 = NULL;
   31817           0 :       __pyx_t_7 = 0;
   31818             :       #if CYTHON_UNPACK_METHODS
   31819           0 :       if (likely(PyMethod_Check(__pyx_t_1))) {
   31820           0 :         __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_1);
   31821           0 :         if (likely(__pyx_t_8)) {
   31822           0 :           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
   31823           0 :           __Pyx_INCREF(__pyx_t_8);
   31824           0 :           __Pyx_INCREF(function);
   31825           0 :           __Pyx_DECREF_SET(__pyx_t_1, function);
   31826             :           __pyx_t_7 = 1;
   31827             :         }
   31828             :       }
   31829             :       #endif
   31830             :       {
   31831           0 :         PyObject *__pyx_callargs[2] = {__pyx_t_8, __pyx_t_2};
   31832           0 :         __pyx_t_3 = __Pyx_PyObject_FastCall(__pyx_t_1, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   31833           0 :         __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   31834           0 :         __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31835           0 :         if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 219, __pyx_L1_error)
   31836           0 :         __Pyx_GOTREF(__pyx_t_3);
   31837           0 :         __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31838             :       }
   31839           0 :       __pyx_t_1 = PyTuple_Pack(1, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 219, __pyx_L1_error)
   31840           0 :       __Pyx_GOTREF(__pyx_t_1);
   31841           0 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31842           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, __pyx_t_1, 0, 0);
   31843           0 :       __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31844           0 :       __PYX_ERR(0, 217, __pyx_L1_error)
   31845             :     }
   31846             :   }
   31847             :   #else
   31848             :   if ((1)); else __PYX_ERR(0, 217, __pyx_L1_error)
   31849             :   #endif
   31850             : 
   31851             :   /* "_ni_label.pyx":222
   31852             :  * 
   31853             :  *     # check structuring element for symmetry
   31854             :  *     assert np.all(structure == structure[(np.s_[::-1],) * structure.ndim]), \             # <<<<<<<<<<<<<<
   31855             :  *         "Structuring element is not symmetric"
   31856             :  * 
   31857             :  */
   31858             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   31859         119 :   if (unlikely(__pyx_assertions_enabled())) {
   31860         119 :     __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error)
   31861         119 :     __Pyx_GOTREF(__pyx_t_3);
   31862         119 :     __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_all); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error)
   31863         119 :     __Pyx_GOTREF(__pyx_t_2);
   31864         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31865         119 :     __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error)
   31866         119 :     __Pyx_GOTREF(__pyx_t_3);
   31867         119 :     __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_s); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 222, __pyx_L1_error)
   31868         119 :     __Pyx_GOTREF(__pyx_t_8);
   31869         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31870         119 :     __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_t_8, __pyx_slice__16); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error)
   31871         119 :     __Pyx_GOTREF(__pyx_t_3);
   31872         119 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31873         119 :     __pyx_t_9 = __pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_structure);
   31874         119 :     __pyx_t_8 = PyTuple_New(1 * ((__pyx_t_9<0) ? 0:__pyx_t_9)); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 222, __pyx_L1_error)
   31875             :     __Pyx_GOTREF(__pyx_t_8);
   31876             :     { Py_ssize_t __pyx_temp;
   31877         334 :       for (__pyx_temp=0; __pyx_temp < __pyx_t_9; __pyx_temp++) {
   31878         215 :         __Pyx_INCREF(__pyx_t_3);
   31879         215 :         __Pyx_GIVEREF(__pyx_t_3);
   31880         215 :         if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, __pyx_temp, __pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error);
   31881             :       }
   31882             :     }
   31883         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31884         119 :     __pyx_t_3 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_structure), __pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error)
   31885         119 :     __Pyx_GOTREF(__pyx_t_3);
   31886         119 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31887         119 :     __pyx_t_8 = PyObject_RichCompare(((PyObject *)__pyx_v_structure), __pyx_t_3, Py_EQ); __Pyx_XGOTREF(__pyx_t_8); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 222, __pyx_L1_error)
   31888         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31889         119 :     __pyx_t_3 = NULL;
   31890         119 :     __pyx_t_7 = 0;
   31891             :     #if CYTHON_UNPACK_METHODS
   31892         119 :     if (unlikely(PyMethod_Check(__pyx_t_2))) {
   31893           0 :       __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
   31894           0 :       if (likely(__pyx_t_3)) {
   31895           0 :         PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
   31896           0 :         __Pyx_INCREF(__pyx_t_3);
   31897           0 :         __Pyx_INCREF(function);
   31898           0 :         __Pyx_DECREF_SET(__pyx_t_2, function);
   31899             :         __pyx_t_7 = 1;
   31900             :       }
   31901             :     }
   31902             :     #endif
   31903             :     {
   31904         119 :       PyObject *__pyx_callargs[2] = {__pyx_t_3, __pyx_t_8};
   31905         119 :       __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_2, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   31906         119 :       __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   31907         119 :       __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31908         119 :       if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 222, __pyx_L1_error)
   31909         119 :       __Pyx_GOTREF(__pyx_t_1);
   31910         119 :       __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31911             :     }
   31912         119 :     __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 222, __pyx_L1_error)
   31913         119 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31914         119 :     if (unlikely(!__pyx_t_4)) {
   31915           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, __pyx_kp_u_Structuring_element_is_not_symme, 0, 0);
   31916           0 :       __PYX_ERR(0, 222, __pyx_L1_error)
   31917             :     }
   31918             :   }
   31919             :   #else
   31920             :   if ((1)); else __PYX_ERR(0, 222, __pyx_L1_error)
   31921             :   #endif
   31922             : 
   31923             :   /* "_ni_label.pyx":226
   31924             :  * 
   31925             :  *     # make sure we're dealing with a non-empty, non-scalar array
   31926             :  *     assert input.ndim > 0 and input.size > 0, "Cannot label scalars or empty arrays"             # <<<<<<<<<<<<<<
   31927             :  * 
   31928             :  *     # if we're handed booleans, we treat them as uint8s
   31929             :  */
   31930             :   #ifndef CYTHON_WITHOUT_ASSERTIONS
   31931         119 :   if (unlikely(__pyx_assertions_enabled())) {
   31932         119 :     __pyx_t_10 = (__pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_input) > 0);
   31933         119 :     if (__pyx_t_10) {
   31934         119 :     } else {
   31935           0 :       __pyx_t_4 = __pyx_t_10;
   31936           0 :       goto __pyx_L3_bool_binop_done;
   31937             :     }
   31938         119 :     __pyx_t_10 = (__pyx_f_5numpy_7ndarray_4size_size(__pyx_v_input) > 0);
   31939         119 :     __pyx_t_4 = __pyx_t_10;
   31940         119 :     __pyx_L3_bool_binop_done:;
   31941         119 :     if (unlikely(!__pyx_t_4)) {
   31942           0 :       __Pyx_Raise(__pyx_builtin_AssertionError, __pyx_kp_u_Cannot_label_scalars_or_empty_ar, 0, 0);
   31943           0 :       __PYX_ERR(0, 226, __pyx_L1_error)
   31944             :     }
   31945             :   }
   31946             :   #else
   31947             :   if ((1)); else __PYX_ERR(0, 226, __pyx_L1_error)
   31948             :   #endif
   31949             : 
   31950             :   /* "_ni_label.pyx":229
   31951             :  * 
   31952             :  *     # if we're handed booleans, we treat them as uint8s
   31953             :  *     if input.dtype == np.bool_:             # <<<<<<<<<<<<<<
   31954             :  *         input = input.view(dtype=np.uint8)
   31955             :  *     if output.dtype == np.bool_:
   31956             :  */
   31957         119 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_input), __pyx_n_s_dtype); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 229, __pyx_L1_error)
   31958         119 :   __Pyx_GOTREF(__pyx_t_1);
   31959         119 :   __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 229, __pyx_L1_error)
   31960         119 :   __Pyx_GOTREF(__pyx_t_2);
   31961         119 :   __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_bool); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 229, __pyx_L1_error)
   31962         119 :   __Pyx_GOTREF(__pyx_t_8);
   31963         119 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31964         119 :   __pyx_t_2 = PyObject_RichCompare(__pyx_t_1, __pyx_t_8, Py_EQ); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 229, __pyx_L1_error)
   31965         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31966         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31967         119 :   __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 229, __pyx_L1_error)
   31968         119 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31969         119 :   if (__pyx_t_4) {
   31970             : 
   31971             :     /* "_ni_label.pyx":230
   31972             :  *     # if we're handed booleans, we treat them as uint8s
   31973             :  *     if input.dtype == np.bool_:
   31974             :  *         input = input.view(dtype=np.uint8)             # <<<<<<<<<<<<<<
   31975             :  *     if output.dtype == np.bool_:
   31976             :  *         # XXX - trigger special check for bit depth?
   31977             :  */
   31978           8 :     __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_input), __pyx_n_s_view); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 230, __pyx_L1_error)
   31979           8 :     __Pyx_GOTREF(__pyx_t_2);
   31980           8 :     __pyx_t_8 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 230, __pyx_L1_error)
   31981           8 :     __Pyx_GOTREF(__pyx_t_8);
   31982           8 :     __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_np); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 230, __pyx_L1_error)
   31983           8 :     __Pyx_GOTREF(__pyx_t_1);
   31984           8 :     __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_uint8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 230, __pyx_L1_error)
   31985           8 :     __Pyx_GOTREF(__pyx_t_3);
   31986           8 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   31987           8 :     if (PyDict_SetItem(__pyx_t_8, __pyx_n_s_dtype, __pyx_t_3) < 0) __PYX_ERR(0, 230, __pyx_L1_error)
   31988           8 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   31989           8 :     __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 230, __pyx_L1_error)
   31990           8 :     __Pyx_GOTREF(__pyx_t_3);
   31991           8 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   31992           8 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   31993           8 :     if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(0, 230, __pyx_L1_error)
   31994           8 :     __Pyx_DECREF_SET(__pyx_v_input, ((PyArrayObject *)__pyx_t_3));
   31995           8 :     __pyx_t_3 = 0;
   31996             : 
   31997             :     /* "_ni_label.pyx":229
   31998             :  * 
   31999             :  *     # if we're handed booleans, we treat them as uint8s
   32000             :  *     if input.dtype == np.bool_:             # <<<<<<<<<<<<<<
   32001             :  *         input = input.view(dtype=np.uint8)
   32002             :  *     if output.dtype == np.bool_:
   32003             :  */
   32004             :   }
   32005             : 
   32006             :   /* "_ni_label.pyx":231
   32007             :  *     if input.dtype == np.bool_:
   32008             :  *         input = input.view(dtype=np.uint8)
   32009             :  *     if output.dtype == np.bool_:             # <<<<<<<<<<<<<<
   32010             :  *         # XXX - trigger special check for bit depth?
   32011             :  *         output = output.view(dtype=np.uint8)
   32012             :  */
   32013         119 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_dtype); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 231, __pyx_L1_error)
   32014         119 :   __Pyx_GOTREF(__pyx_t_3);
   32015         119 :   __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_np); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 231, __pyx_L1_error)
   32016         119 :   __Pyx_GOTREF(__pyx_t_8);
   32017         119 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_bool); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 231, __pyx_L1_error)
   32018         119 :   __Pyx_GOTREF(__pyx_t_2);
   32019         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32020         119 :   __pyx_t_8 = PyObject_RichCompare(__pyx_t_3, __pyx_t_2, Py_EQ); __Pyx_XGOTREF(__pyx_t_8); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 231, __pyx_L1_error)
   32021         119 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32022         119 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32023         119 :   __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_8); if (unlikely((__pyx_t_4 < 0))) __PYX_ERR(0, 231, __pyx_L1_error)
   32024         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32025         119 :   if (__pyx_t_4) {
   32026             : 
   32027             :     /* "_ni_label.pyx":233
   32028             :  *     if output.dtype == np.bool_:
   32029             :  *         # XXX - trigger special check for bit depth?
   32030             :  *         output = output.view(dtype=np.uint8)             # <<<<<<<<<<<<<<
   32031             :  * 
   32032             :  *     cdef:
   32033             :  */
   32034           0 :     __pyx_t_8 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_view); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 233, __pyx_L1_error)
   32035           0 :     __Pyx_GOTREF(__pyx_t_8);
   32036           0 :     __pyx_t_2 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 233, __pyx_L1_error)
   32037           0 :     __Pyx_GOTREF(__pyx_t_2);
   32038           0 :     __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 233, __pyx_L1_error)
   32039           0 :     __Pyx_GOTREF(__pyx_t_3);
   32040           0 :     __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_uint8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 233, __pyx_L1_error)
   32041           0 :     __Pyx_GOTREF(__pyx_t_1);
   32042           0 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32043           0 :     if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_dtype, __pyx_t_1) < 0) __PYX_ERR(0, 233, __pyx_L1_error)
   32044           0 :     __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32045           0 :     __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_empty_tuple, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 233, __pyx_L1_error)
   32046           0 :     __Pyx_GOTREF(__pyx_t_1);
   32047           0 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32048           0 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32049           0 :     if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(0, 233, __pyx_L1_error)
   32050           0 :     __Pyx_DECREF_SET(__pyx_v_output, ((PyArrayObject *)__pyx_t_1));
   32051             :     __pyx_t_1 = 0;
   32052             : 
   32053             :     /* "_ni_label.pyx":231
   32054             :  *     if input.dtype == np.bool_:
   32055             :  *         input = input.view(dtype=np.uint8)
   32056             :  *     if output.dtype == np.bool_:             # <<<<<<<<<<<<<<
   32057             :  *         # XXX - trigger special check for bit depth?
   32058             :  *         output = output.view(dtype=np.uint8)
   32059             :  */
   32060             :   }
   32061             : 
   32062             :   /* "_ni_label.pyx":237
   32063             :  *     cdef:
   32064             :  *         nonzero_line_func_t nonzero_line = \
   32065             :  *             <nonzero_line_func_t> <void *> <Py_intptr_t> get_nonzero_line(input.take([0]))             # <<<<<<<<<<<<<<
   32066             :  *         read_line_func_t read_line = \
   32067             :  *             <read_line_func_t> <void *> <Py_intptr_t> get_read_line(output.take([0]))
   32068             :  */
   32069         119 :   __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_get_nonzero_line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 237, __pyx_L1_error)
   32070         119 :   __Pyx_GOTREF(__pyx_t_2);
   32071         119 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_input), __pyx_n_s_take); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 237, __pyx_L1_error)
   32072         119 :   __Pyx_GOTREF(__pyx_t_3);
   32073         119 :   __pyx_t_5 = PyList_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 237, __pyx_L1_error)
   32074         119 :   __Pyx_GOTREF(__pyx_t_5);
   32075         119 :   __Pyx_INCREF(__pyx_int_0);
   32076         119 :   __Pyx_GIVEREF(__pyx_int_0);
   32077         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_5, 0, __pyx_int_0)) __PYX_ERR(0, 237, __pyx_L1_error);
   32078         119 :   __pyx_t_6 = NULL;
   32079         119 :   __pyx_t_7 = 0;
   32080             :   #if CYTHON_UNPACK_METHODS
   32081         119 :   if (likely(PyMethod_Check(__pyx_t_3))) {
   32082           0 :     __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_3);
   32083           0 :     if (likely(__pyx_t_6)) {
   32084           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
   32085           0 :       __Pyx_INCREF(__pyx_t_6);
   32086           0 :       __Pyx_INCREF(function);
   32087           0 :       __Pyx_DECREF_SET(__pyx_t_3, function);
   32088             :       __pyx_t_7 = 1;
   32089             :     }
   32090             :   }
   32091             :   #endif
   32092             :   {
   32093         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_t_5};
   32094         119 :     __pyx_t_8 = __Pyx_PyObject_FastCall(__pyx_t_3, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32095         119 :     __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   32096         119 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32097         119 :     if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 237, __pyx_L1_error)
   32098         119 :     __Pyx_GOTREF(__pyx_t_8);
   32099         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32100             :   }
   32101         119 :   __pyx_t_3 = NULL;
   32102         119 :   __pyx_t_7 = 0;
   32103             :   #if CYTHON_UNPACK_METHODS
   32104         119 :   if (unlikely(PyMethod_Check(__pyx_t_2))) {
   32105           0 :     __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
   32106           0 :     if (likely(__pyx_t_3)) {
   32107           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
   32108           0 :       __Pyx_INCREF(__pyx_t_3);
   32109           0 :       __Pyx_INCREF(function);
   32110           0 :       __Pyx_DECREF_SET(__pyx_t_2, function);
   32111             :       __pyx_t_7 = 1;
   32112             :     }
   32113             :   }
   32114             :   #endif
   32115             :   {
   32116         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_3, __pyx_t_8};
   32117         119 :     __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_2, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32118         119 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   32119         119 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32120         119 :     if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 237, __pyx_L1_error)
   32121         119 :     __Pyx_GOTREF(__pyx_t_1);
   32122         119 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32123             :   }
   32124         119 :   __pyx_t_11 = __Pyx_PyInt_As_Py_intptr_t(__pyx_t_1); if (unlikely((__pyx_t_11 == ((Py_intptr_t)-1)) && PyErr_Occurred())) __PYX_ERR(0, 237, __pyx_L1_error)
   32125         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32126         119 :   __pyx_v_nonzero_line = ((__pyx_t_9_ni_label_nonzero_line_func_t)((void *)((Py_intptr_t)__pyx_t_11)));
   32127             : 
   32128             :   /* "_ni_label.pyx":239
   32129             :  *             <nonzero_line_func_t> <void *> <Py_intptr_t> get_nonzero_line(input.take([0]))
   32130             :  *         read_line_func_t read_line = \
   32131             :  *             <read_line_func_t> <void *> <Py_intptr_t> get_read_line(output.take([0]))             # <<<<<<<<<<<<<<
   32132             :  *         write_line_func_t write_line = \
   32133             :  *             <write_line_func_t> <void *> <Py_intptr_t> get_write_line(output.take([0]))
   32134             :  */
   32135         119 :   __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_get_read_line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 239, __pyx_L1_error)
   32136         119 :   __Pyx_GOTREF(__pyx_t_2);
   32137         119 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_take); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 239, __pyx_L1_error)
   32138         119 :   __Pyx_GOTREF(__pyx_t_3);
   32139         119 :   __pyx_t_5 = PyList_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 239, __pyx_L1_error)
   32140         119 :   __Pyx_GOTREF(__pyx_t_5);
   32141         119 :   __Pyx_INCREF(__pyx_int_0);
   32142         119 :   __Pyx_GIVEREF(__pyx_int_0);
   32143         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_5, 0, __pyx_int_0)) __PYX_ERR(0, 239, __pyx_L1_error);
   32144         119 :   __pyx_t_6 = NULL;
   32145         119 :   __pyx_t_7 = 0;
   32146             :   #if CYTHON_UNPACK_METHODS
   32147         119 :   if (likely(PyMethod_Check(__pyx_t_3))) {
   32148           0 :     __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_3);
   32149           0 :     if (likely(__pyx_t_6)) {
   32150           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
   32151           0 :       __Pyx_INCREF(__pyx_t_6);
   32152           0 :       __Pyx_INCREF(function);
   32153           0 :       __Pyx_DECREF_SET(__pyx_t_3, function);
   32154             :       __pyx_t_7 = 1;
   32155             :     }
   32156             :   }
   32157             :   #endif
   32158             :   {
   32159         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_t_5};
   32160         119 :     __pyx_t_8 = __Pyx_PyObject_FastCall(__pyx_t_3, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32161         119 :     __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   32162         119 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32163         119 :     if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 239, __pyx_L1_error)
   32164         119 :     __Pyx_GOTREF(__pyx_t_8);
   32165         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32166             :   }
   32167         119 :   __pyx_t_3 = NULL;
   32168         119 :   __pyx_t_7 = 0;
   32169             :   #if CYTHON_UNPACK_METHODS
   32170         119 :   if (unlikely(PyMethod_Check(__pyx_t_2))) {
   32171           0 :     __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
   32172           0 :     if (likely(__pyx_t_3)) {
   32173           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
   32174           0 :       __Pyx_INCREF(__pyx_t_3);
   32175           0 :       __Pyx_INCREF(function);
   32176           0 :       __Pyx_DECREF_SET(__pyx_t_2, function);
   32177             :       __pyx_t_7 = 1;
   32178             :     }
   32179             :   }
   32180             :   #endif
   32181             :   {
   32182         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_3, __pyx_t_8};
   32183         119 :     __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_2, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32184         119 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   32185         119 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32186         119 :     if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 239, __pyx_L1_error)
   32187         119 :     __Pyx_GOTREF(__pyx_t_1);
   32188         119 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32189             :   }
   32190         119 :   __pyx_t_11 = __Pyx_PyInt_As_Py_intptr_t(__pyx_t_1); if (unlikely((__pyx_t_11 == ((Py_intptr_t)-1)) && PyErr_Occurred())) __PYX_ERR(0, 239, __pyx_L1_error)
   32191         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32192         119 :   __pyx_v_read_line = ((__pyx_t_9_ni_label_read_line_func_t)((void *)((Py_intptr_t)__pyx_t_11)));
   32193             : 
   32194             :   /* "_ni_label.pyx":241
   32195             :  *             <read_line_func_t> <void *> <Py_intptr_t> get_read_line(output.take([0]))
   32196             :  *         write_line_func_t write_line = \
   32197             :  *             <write_line_func_t> <void *> <Py_intptr_t> get_write_line(output.take([0]))             # <<<<<<<<<<<<<<
   32198             :  *         np.flatiter _iti, _ito, _itstruct
   32199             :  *         PyArrayIterObject *iti
   32200             :  */
   32201         119 :   __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_get_write_line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 241, __pyx_L1_error)
   32202         119 :   __Pyx_GOTREF(__pyx_t_2);
   32203         119 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_output), __pyx_n_s_take); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 241, __pyx_L1_error)
   32204         119 :   __Pyx_GOTREF(__pyx_t_3);
   32205         119 :   __pyx_t_5 = PyList_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 241, __pyx_L1_error)
   32206         119 :   __Pyx_GOTREF(__pyx_t_5);
   32207         119 :   __Pyx_INCREF(__pyx_int_0);
   32208         119 :   __Pyx_GIVEREF(__pyx_int_0);
   32209         119 :   if (__Pyx_PyList_SET_ITEM(__pyx_t_5, 0, __pyx_int_0)) __PYX_ERR(0, 241, __pyx_L1_error);
   32210         119 :   __pyx_t_6 = NULL;
   32211         119 :   __pyx_t_7 = 0;
   32212             :   #if CYTHON_UNPACK_METHODS
   32213         119 :   if (likely(PyMethod_Check(__pyx_t_3))) {
   32214           0 :     __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_3);
   32215           0 :     if (likely(__pyx_t_6)) {
   32216           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
   32217           0 :       __Pyx_INCREF(__pyx_t_6);
   32218           0 :       __Pyx_INCREF(function);
   32219           0 :       __Pyx_DECREF_SET(__pyx_t_3, function);
   32220             :       __pyx_t_7 = 1;
   32221             :     }
   32222             :   }
   32223             :   #endif
   32224             :   {
   32225         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_6, __pyx_t_5};
   32226         119 :     __pyx_t_8 = __Pyx_PyObject_FastCall(__pyx_t_3, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32227         119 :     __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   32228         119 :     __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32229         119 :     if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 241, __pyx_L1_error)
   32230         119 :     __Pyx_GOTREF(__pyx_t_8);
   32231         119 :     __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32232             :   }
   32233         119 :   __pyx_t_3 = NULL;
   32234         119 :   __pyx_t_7 = 0;
   32235             :   #if CYTHON_UNPACK_METHODS
   32236         119 :   if (unlikely(PyMethod_Check(__pyx_t_2))) {
   32237           0 :     __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
   32238           0 :     if (likely(__pyx_t_3)) {
   32239           0 :       PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
   32240           0 :       __Pyx_INCREF(__pyx_t_3);
   32241           0 :       __Pyx_INCREF(function);
   32242           0 :       __Pyx_DECREF_SET(__pyx_t_2, function);
   32243             :       __pyx_t_7 = 1;
   32244             :     }
   32245             :   }
   32246             :   #endif
   32247             :   {
   32248         119 :     PyObject *__pyx_callargs[2] = {__pyx_t_3, __pyx_t_8};
   32249         119 :     __pyx_t_1 = __Pyx_PyObject_FastCall(__pyx_t_2, __pyx_callargs+1-__pyx_t_7, 1+__pyx_t_7);
   32250         119 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   32251         119 :     __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32252         119 :     if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error)
   32253         119 :     __Pyx_GOTREF(__pyx_t_1);
   32254         119 :     __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32255             :   }
   32256         119 :   __pyx_t_11 = __Pyx_PyInt_As_Py_intptr_t(__pyx_t_1); if (unlikely((__pyx_t_11 == ((Py_intptr_t)-1)) && PyErr_Occurred())) __PYX_ERR(0, 241, __pyx_L1_error)
   32257         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32258         119 :   __pyx_v_write_line = ((__pyx_t_9_ni_label_write_line_func_t)((void *)((Py_intptr_t)__pyx_t_11)));
   32259             : 
   32260             :   /* "_ni_label.pyx":260
   32261             :  *         np.uintp_t *mergetable
   32262             :  * 
   32263             :  *     axis = -1  # choose best axis based on output             # <<<<<<<<<<<<<<
   32264             :  *     _ito = np.PyArray_IterAllButAxis(output, &axis)
   32265             :  *     _iti = np.PyArray_IterAllButAxis(input, &axis)
   32266             :  */
   32267         119 :   __pyx_v_axis = -1;
   32268             : 
   32269             :   /* "_ni_label.pyx":261
   32270             :  * 
   32271             :  *     axis = -1  # choose best axis based on output
   32272             :  *     _ito = np.PyArray_IterAllButAxis(output, &axis)             # <<<<<<<<<<<<<<
   32273             :  *     _iti = np.PyArray_IterAllButAxis(input, &axis)
   32274             :  *     _itstruct = np.PyArray_IterAllButAxis(structure, &axis)
   32275             :  */
   32276         119 :   __pyx_t_1 = PyArray_IterAllButAxis(((PyObject *)__pyx_v_output), (&__pyx_v_axis)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error)
   32277         119 :   __Pyx_GOTREF(__pyx_t_1);
   32278         119 :   if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_flatiter))))) __PYX_ERR(0, 261, __pyx_L1_error)
   32279         119 :   __pyx_v__ito = ((PyArrayIterObject *)__pyx_t_1);
   32280         119 :   __pyx_t_1 = 0;
   32281             : 
   32282             :   /* "_ni_label.pyx":262
   32283             :  *     axis = -1  # choose best axis based on output
   32284             :  *     _ito = np.PyArray_IterAllButAxis(output, &axis)
   32285             :  *     _iti = np.PyArray_IterAllButAxis(input, &axis)             # <<<<<<<<<<<<<<
   32286             :  *     _itstruct = np.PyArray_IterAllButAxis(structure, &axis)
   32287             :  * 
   32288             :  */
   32289         119 :   __pyx_t_1 = PyArray_IterAllButAxis(((PyObject *)__pyx_v_input), (&__pyx_v_axis)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 262, __pyx_L1_error)
   32290         119 :   __Pyx_GOTREF(__pyx_t_1);
   32291         119 :   if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_flatiter))))) __PYX_ERR(0, 262, __pyx_L1_error)
   32292         119 :   __pyx_v__iti = ((PyArrayIterObject *)__pyx_t_1);
   32293         119 :   __pyx_t_1 = 0;
   32294             : 
   32295             :   /* "_ni_label.pyx":263
   32296             :  *     _ito = np.PyArray_IterAllButAxis(output, &axis)
   32297             :  *     _iti = np.PyArray_IterAllButAxis(input, &axis)
   32298             :  *     _itstruct = np.PyArray_IterAllButAxis(structure, &axis)             # <<<<<<<<<<<<<<
   32299             :  * 
   32300             :  *     ito = <PyArrayIterObject *> _ito
   32301             :  */
   32302         119 :   __pyx_t_1 = PyArray_IterAllButAxis(((PyObject *)__pyx_v_structure), (&__pyx_v_axis)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 263, __pyx_L1_error)
   32303         119 :   __Pyx_GOTREF(__pyx_t_1);
   32304         119 :   if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_flatiter))))) __PYX_ERR(0, 263, __pyx_L1_error)
   32305         119 :   __pyx_v__itstruct = ((PyArrayIterObject *)__pyx_t_1);
   32306         119 :   __pyx_t_1 = 0;
   32307             : 
   32308             :   /* "_ni_label.pyx":265
   32309             :  *     _itstruct = np.PyArray_IterAllButAxis(structure, &axis)
   32310             :  * 
   32311             :  *     ito = <PyArrayIterObject *> _ito             # <<<<<<<<<<<<<<
   32312             :  *     iti = <PyArrayIterObject *> _iti
   32313             :  *     itstruct = <PyArrayIterObject *> _itstruct
   32314             :  */
   32315         119 :   __pyx_v_ito = ((PyArrayIterObject *)__pyx_v__ito);
   32316             : 
   32317             :   /* "_ni_label.pyx":266
   32318             :  * 
   32319             :  *     ito = <PyArrayIterObject *> _ito
   32320             :  *     iti = <PyArrayIterObject *> _iti             # <<<<<<<<<<<<<<
   32321             :  *     itstruct = <PyArrayIterObject *> _itstruct
   32322             :  * 
   32323             :  */
   32324         119 :   __pyx_v_iti = ((PyArrayIterObject *)__pyx_v__iti);
   32325             : 
   32326             :   /* "_ni_label.pyx":267
   32327             :  *     ito = <PyArrayIterObject *> _ito
   32328             :  *     iti = <PyArrayIterObject *> _iti
   32329             :  *     itstruct = <PyArrayIterObject *> _itstruct             # <<<<<<<<<<<<<<
   32330             :  * 
   32331             :  *     # we only process this many neighbors from the itstruct iterator before
   32332             :  */
   32333         119 :   __pyx_v_itstruct = ((PyArrayIterObject *)__pyx_v__itstruct);
   32334             : 
   32335             :   /* "_ni_label.pyx":271
   32336             :  *     # we only process this many neighbors from the itstruct iterator before
   32337             :  *     # reaching the center, where we stop
   32338             :  *     num_neighbors = structure.size // (3 * 2)             # <<<<<<<<<<<<<<
   32339             :  * 
   32340             :  *     # Create two buffer arrays for reading/writing labels.
   32341             :  */
   32342         119 :   __pyx_v_num_neighbors = __Pyx_div_npy_intp(__pyx_f_5numpy_7ndarray_4size_size(__pyx_v_structure), 0x6);
   32343             : 
   32344             :   /* "_ni_label.pyx":275
   32345             :  *     # Create two buffer arrays for reading/writing labels.
   32346             :  *     # Add an entry at the end and beginning to simplify some bounds checks.
   32347             :  *     L = input.shape[axis]             # <<<<<<<<<<<<<<
   32348             :  *     _line_buffer = np.empty(L + 2, dtype=np.uintp)
   32349             :  *     _neighbor_buffer = np.empty(L + 2, dtype=np.uintp)
   32350             :  */
   32351         119 :   __pyx_v_L = (__pyx_f_5numpy_7ndarray_5shape_shape(__pyx_v_input)[__pyx_v_axis]);
   32352             : 
   32353             :   /* "_ni_label.pyx":276
   32354             :  *     # Add an entry at the end and beginning to simplify some bounds checks.
   32355             :  *     L = input.shape[axis]
   32356             :  *     _line_buffer = np.empty(L + 2, dtype=np.uintp)             # <<<<<<<<<<<<<<
   32357             :  *     _neighbor_buffer = np.empty(L + 2, dtype=np.uintp)
   32358             :  *     line_buffer = <np.uintp_t *> _line_buffer.data
   32359             :  */
   32360         119 :   __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_np); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
   32361         119 :   __Pyx_GOTREF(__pyx_t_1);
   32362         119 :   __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_empty); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 276, __pyx_L1_error)
   32363         119 :   __Pyx_GOTREF(__pyx_t_2);
   32364         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32365         119 :   __pyx_t_1 = __Pyx_PyInt_From_npy_intp((__pyx_v_L + 2)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
   32366         119 :   __Pyx_GOTREF(__pyx_t_1);
   32367         119 :   __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 276, __pyx_L1_error)
   32368         119 :   __Pyx_GOTREF(__pyx_t_8);
   32369         119 :   __Pyx_GIVEREF(__pyx_t_1);
   32370         119 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error);
   32371         119 :   __pyx_t_1 = 0;
   32372         119 :   __pyx_t_1 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
   32373         119 :   __Pyx_GOTREF(__pyx_t_1);
   32374         119 :   __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 276, __pyx_L1_error)
   32375         119 :   __Pyx_GOTREF(__pyx_t_3);
   32376         119 :   __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_uintp); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 276, __pyx_L1_error)
   32377         119 :   __Pyx_GOTREF(__pyx_t_5);
   32378         119 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32379         119 :   if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_dtype, __pyx_t_5) < 0) __PYX_ERR(0, 276, __pyx_L1_error)
   32380         119 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32381         119 :   __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, __pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 276, __pyx_L1_error)
   32382         119 :   __Pyx_GOTREF(__pyx_t_5);
   32383         119 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32384         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32385         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32386         119 :   if (!(likely(((__pyx_t_5) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_5, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(0, 276, __pyx_L1_error)
   32387         119 :   __pyx_v__line_buffer = ((PyArrayObject *)__pyx_t_5);
   32388         119 :   __pyx_t_5 = 0;
   32389             : 
   32390             :   /* "_ni_label.pyx":277
   32391             :  *     L = input.shape[axis]
   32392             :  *     _line_buffer = np.empty(L + 2, dtype=np.uintp)
   32393             :  *     _neighbor_buffer = np.empty(L + 2, dtype=np.uintp)             # <<<<<<<<<<<<<<
   32394             :  *     line_buffer = <np.uintp_t *> _line_buffer.data
   32395             :  *     neighbor_buffer = <np.uintp_t *> _neighbor_buffer.data
   32396             :  */
   32397         119 :   __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_np); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 277, __pyx_L1_error)
   32398         119 :   __Pyx_GOTREF(__pyx_t_5);
   32399         119 :   __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_empty); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 277, __pyx_L1_error)
   32400         119 :   __Pyx_GOTREF(__pyx_t_1);
   32401         119 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32402         119 :   __pyx_t_5 = __Pyx_PyInt_From_npy_intp((__pyx_v_L + 2)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 277, __pyx_L1_error)
   32403         119 :   __Pyx_GOTREF(__pyx_t_5);
   32404         119 :   __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 277, __pyx_L1_error)
   32405         119 :   __Pyx_GOTREF(__pyx_t_8);
   32406         119 :   __Pyx_GIVEREF(__pyx_t_5);
   32407         119 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_5)) __PYX_ERR(0, 277, __pyx_L1_error);
   32408         119 :   __pyx_t_5 = 0;
   32409         119 :   __pyx_t_5 = __Pyx_PyDict_NewPresized(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 277, __pyx_L1_error)
   32410         119 :   __Pyx_GOTREF(__pyx_t_5);
   32411         119 :   __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 277, __pyx_L1_error)
   32412         119 :   __Pyx_GOTREF(__pyx_t_2);
   32413         119 :   __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_uintp); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 277, __pyx_L1_error)
   32414         119 :   __Pyx_GOTREF(__pyx_t_3);
   32415         119 :   __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
   32416         119 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_dtype, __pyx_t_3) < 0) __PYX_ERR(0, 277, __pyx_L1_error)
   32417         119 :   __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32418         119 :   __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 277, __pyx_L1_error)
   32419         119 :   __Pyx_GOTREF(__pyx_t_3);
   32420         119 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   32421         119 :   __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
   32422         119 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32423         119 :   if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(0, 277, __pyx_L1_error)
   32424         119 :   __pyx_v__neighbor_buffer = ((PyArrayObject *)__pyx_t_3);
   32425         119 :   __pyx_t_3 = 0;
   32426             : 
   32427             :   /* "_ni_label.pyx":278
   32428             :  *     _line_buffer = np.empty(L + 2, dtype=np.uintp)
   32429             :  *     _neighbor_buffer = np.empty(L + 2, dtype=np.uintp)
   32430             :  *     line_buffer = <np.uintp_t *> _line_buffer.data             # <<<<<<<<<<<<<<
   32431             :  *     neighbor_buffer = <np.uintp_t *> _neighbor_buffer.data
   32432             :  * 
   32433             :  */
   32434         119 :   __pyx_v_line_buffer = ((__pyx_t_5numpy_uintp_t *)__pyx_f_5numpy_7ndarray_4data_data(__pyx_v__line_buffer));
   32435             : 
   32436             :   /* "_ni_label.pyx":279
   32437             :  *     _neighbor_buffer = np.empty(L + 2, dtype=np.uintp)
   32438             :  *     line_buffer = <np.uintp_t *> _line_buffer.data
   32439             :  *     neighbor_buffer = <np.uintp_t *> _neighbor_buffer.data             # <<<<<<<<<<<<<<
   32440             :  * 
   32441             :  *     # Add fenceposts with background values
   32442             :  */
   32443         119 :   __pyx_v_neighbor_buffer = ((__pyx_t_5numpy_uintp_t *)__pyx_f_5numpy_7ndarray_4data_data(__pyx_v__neighbor_buffer));
   32444             : 
   32445             :   /* "_ni_label.pyx":282
   32446             :  * 
   32447             :  *     # Add fenceposts with background values
   32448             :  *     line_buffer[0] = neighbor_buffer[0] = BACKGROUND             # <<<<<<<<<<<<<<
   32449             :  *     line_buffer[L + 1] = neighbor_buffer[L + 1] = BACKGROUND
   32450             :  *     line_buffer = line_buffer + 1
   32451             :  */
   32452         119 :   (__pyx_v_line_buffer[0]) = __pyx_e_9_ni_label_BACKGROUND;
   32453         119 :   (__pyx_v_neighbor_buffer[0]) = __pyx_e_9_ni_label_BACKGROUND;
   32454             : 
   32455             :   /* "_ni_label.pyx":283
   32456             :  *     # Add fenceposts with background values
   32457             :  *     line_buffer[0] = neighbor_buffer[0] = BACKGROUND
   32458             :  *     line_buffer[L + 1] = neighbor_buffer[L + 1] = BACKGROUND             # <<<<<<<<<<<<<<
   32459             :  *     line_buffer = line_buffer + 1
   32460             :  *     neighbor_buffer = neighbor_buffer + 1
   32461             :  */
   32462         119 :   (__pyx_v_line_buffer[(__pyx_v_L + 1)]) = __pyx_e_9_ni_label_BACKGROUND;
   32463         119 :   (__pyx_v_neighbor_buffer[(__pyx_v_L + 1)]) = __pyx_e_9_ni_label_BACKGROUND;
   32464             : 
   32465             :   /* "_ni_label.pyx":284
   32466             :  *     line_buffer[0] = neighbor_buffer[0] = BACKGROUND
   32467             :  *     line_buffer[L + 1] = neighbor_buffer[L + 1] = BACKGROUND
   32468             :  *     line_buffer = line_buffer + 1             # <<<<<<<<<<<<<<
   32469             :  *     neighbor_buffer = neighbor_buffer + 1
   32470             :  * 
   32471             :  */
   32472         119 :   __pyx_v_line_buffer = (__pyx_v_line_buffer + 1);
   32473             : 
   32474             :   /* "_ni_label.pyx":285
   32475             :  *     line_buffer[L + 1] = neighbor_buffer[L + 1] = BACKGROUND
   32476             :  *     line_buffer = line_buffer + 1
   32477             :  *     neighbor_buffer = neighbor_buffer + 1             # <<<<<<<<<<<<<<
   32478             :  * 
   32479             :  *     mergetable_size = 2 * output.shape[axis]
   32480             :  */
   32481         119 :   __pyx_v_neighbor_buffer = (__pyx_v_neighbor_buffer + 1);
   32482             : 
   32483             :   /* "_ni_label.pyx":287
   32484             :  *     neighbor_buffer = neighbor_buffer + 1
   32485             :  * 
   32486             :  *     mergetable_size = 2 * output.shape[axis]             # <<<<<<<<<<<<<<
   32487             :  *     mergetable = <np.uintp_t *> PyDataMem_NEW(mergetable_size * sizeof(np.uintp_t))
   32488             :  *     if mergetable == NULL:
   32489             :  */
   32490         119 :   __pyx_v_mergetable_size = (2 * (__pyx_f_5numpy_7ndarray_5shape_shape(__pyx_v_output)[__pyx_v_axis]));
   32491             : 
   32492             :   /* "_ni_label.pyx":288
   32493             :  * 
   32494             :  *     mergetable_size = 2 * output.shape[axis]
   32495             :  *     mergetable = <np.uintp_t *> PyDataMem_NEW(mergetable_size * sizeof(np.uintp_t))             # <<<<<<<<<<<<<<
   32496             :  *     if mergetable == NULL:
   32497             :  *         raise MemoryError()
   32498             :  */
   32499         119 :   __pyx_v_mergetable = ((__pyx_t_5numpy_uintp_t *)PyDataMem_NEW((__pyx_v_mergetable_size * (sizeof(__pyx_t_5numpy_uintp_t)))));
   32500             : 
   32501             :   /* "_ni_label.pyx":289
   32502             :  *     mergetable_size = 2 * output.shape[axis]
   32503             :  *     mergetable = <np.uintp_t *> PyDataMem_NEW(mergetable_size * sizeof(np.uintp_t))
   32504             :  *     if mergetable == NULL:             # <<<<<<<<<<<<<<
   32505             :  *         raise MemoryError()
   32506             :  * 
   32507             :  */
   32508         119 :   __pyx_t_4 = (__pyx_v_mergetable == NULL);
   32509         119 :   if (unlikely(__pyx_t_4)) {
   32510             : 
   32511             :     /* "_ni_label.pyx":290
   32512             :  *     mergetable = <np.uintp_t *> PyDataMem_NEW(mergetable_size * sizeof(np.uintp_t))
   32513             :  *     if mergetable == NULL:
   32514             :  *         raise MemoryError()             # <<<<<<<<<<<<<<
   32515             :  * 
   32516             :  *     try:
   32517             :  */
   32518           0 :     PyErr_NoMemory(); __PYX_ERR(0, 290, __pyx_L1_error)
   32519             : 
   32520             :     /* "_ni_label.pyx":289
   32521             :  *     mergetable_size = 2 * output.shape[axis]
   32522             :  *     mergetable = <np.uintp_t *> PyDataMem_NEW(mergetable_size * sizeof(np.uintp_t))
   32523             :  *     if mergetable == NULL:             # <<<<<<<<<<<<<<
   32524             :  *         raise MemoryError()
   32525             :  * 
   32526             :  */
   32527             :   }
   32528             : 
   32529             :   /* "_ni_label.pyx":292
   32530             :  *         raise MemoryError()
   32531             :  * 
   32532             :  *     try:             # <<<<<<<<<<<<<<
   32533             :  *         # strides
   32534             :  *         si = input.strides[axis]
   32535             :  */
   32536             :   {
   32537         119 :     __Pyx_PyThreadState_declare
   32538         119 :     __Pyx_PyThreadState_assign
   32539         119 :     __Pyx_ExceptionSave(&__pyx_t_12, &__pyx_t_13, &__pyx_t_14);
   32540         119 :     __Pyx_XGOTREF(__pyx_t_12);
   32541         119 :     __Pyx_XGOTREF(__pyx_t_13);
   32542         119 :     __Pyx_XGOTREF(__pyx_t_14);
   32543             :     /*try:*/ {
   32544             : 
   32545             :       /* "_ni_label.pyx":294
   32546             :  *     try:
   32547             :  *         # strides
   32548             :  *         si = input.strides[axis]             # <<<<<<<<<<<<<<
   32549             :  *         so = output.strides[axis]
   32550             :  *         ss = structure.strides[axis]
   32551             :  */
   32552         119 :       __pyx_v_si = (__pyx_f_5numpy_7ndarray_7strides_strides(__pyx_v_input)[__pyx_v_axis]);
   32553             : 
   32554             :       /* "_ni_label.pyx":295
   32555             :  *         # strides
   32556             :  *         si = input.strides[axis]
   32557             :  *         so = output.strides[axis]             # <<<<<<<<<<<<<<
   32558             :  *         ss = structure.strides[axis]
   32559             :  * 
   32560             :  */
   32561         119 :       __pyx_v_so = (__pyx_f_5numpy_7ndarray_7strides_strides(__pyx_v_output)[__pyx_v_axis]);
   32562             : 
   32563             :       /* "_ni_label.pyx":296
   32564             :  *         si = input.strides[axis]
   32565             :  *         so = output.strides[axis]
   32566             :  *         ss = structure.strides[axis]             # <<<<<<<<<<<<<<
   32567             :  * 
   32568             :  *         # 0 = background
   32569             :  */
   32570         119 :       __pyx_v_ss = (__pyx_f_5numpy_7ndarray_7strides_strides(__pyx_v_structure)[__pyx_v_axis]);
   32571             : 
   32572             :       /* "_ni_label.pyx":301
   32573             :  *         # 1 = foreground, needs label
   32574             :  *         # 2... = working labels, will be compacted on output
   32575             :  *         next_region = 2             # <<<<<<<<<<<<<<
   32576             :  * 
   32577             :  *         structure_ndim = structure.ndim
   32578             :  */
   32579         119 :       __pyx_v_next_region = 2;
   32580             : 
   32581             :       /* "_ni_label.pyx":303
   32582             :  *         next_region = 2
   32583             :  * 
   32584             :  *         structure_ndim = structure.ndim             # <<<<<<<<<<<<<<
   32585             :  *         temp = [1] * structure_ndim
   32586             :  *         temp[axis] = 0
   32587             :  */
   32588         119 :       __pyx_v_structure_ndim = __pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_structure);
   32589             : 
   32590             :       /* "_ni_label.pyx":304
   32591             :  * 
   32592             :  *         structure_ndim = structure.ndim
   32593             :  *         temp = [1] * structure_ndim             # <<<<<<<<<<<<<<
   32594             :  *         temp[axis] = 0
   32595             :  *         use_previous = (structure[tuple(temp)] != 0)
   32596             :  */
   32597         119 :       __pyx_t_3 = PyList_New(1 * ((__pyx_v_structure_ndim<0) ? 0:__pyx_v_structure_ndim)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 304, __pyx_L8_error)
   32598             :       __Pyx_GOTREF(__pyx_t_3);
   32599             :       { Py_ssize_t __pyx_temp;
   32600         334 :         for (__pyx_temp=0; __pyx_temp < __pyx_v_structure_ndim; __pyx_temp++) {
   32601         215 :           __Pyx_INCREF(__pyx_int_1);
   32602         215 :           __Pyx_GIVEREF(__pyx_int_1);
   32603         215 :           if (__Pyx_PyList_SET_ITEM(__pyx_t_3, __pyx_temp, __pyx_int_1)) __PYX_ERR(0, 304, __pyx_L8_error);
   32604             :         }
   32605             :       }
   32606         119 :       __pyx_v_temp = ((PyObject*)__pyx_t_3);
   32607         119 :       __pyx_t_3 = 0;
   32608             : 
   32609             :       /* "_ni_label.pyx":305
   32610             :  *         structure_ndim = structure.ndim
   32611             :  *         temp = [1] * structure_ndim
   32612             :  *         temp[axis] = 0             # <<<<<<<<<<<<<<
   32613             :  *         use_previous = (structure[tuple(temp)] != 0)
   32614             :  *         output_ndim = output.ndim
   32615             :  */
   32616         119 :       if (unlikely((__Pyx_SetItemInt(__pyx_v_temp, __pyx_v_axis, __pyx_int_0, int, 1, __Pyx_PyInt_From_int, 1, 1, 1) < 0))) __PYX_ERR(0, 305, __pyx_L8_error)
   32617             : 
   32618             :       /* "_ni_label.pyx":306
   32619             :  *         temp = [1] * structure_ndim
   32620             :  *         temp[axis] = 0
   32621             :  *         use_previous = (structure[tuple(temp)] != 0)             # <<<<<<<<<<<<<<
   32622             :  *         output_ndim = output.ndim
   32623             :  *         output_shape = output.shape
   32624             :  */
   32625         119 :       __pyx_t_3 = PyList_AsTuple(__pyx_v_temp); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 306, __pyx_L8_error)
   32626         119 :       __Pyx_GOTREF(__pyx_t_3);
   32627         119 :       __pyx_t_5 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_structure), __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 306, __pyx_L8_error)
   32628         119 :       __Pyx_GOTREF(__pyx_t_5);
   32629         119 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32630         119 :       __pyx_t_3 = __Pyx_PyInt_NeObjC(__pyx_t_5, __pyx_int_0, 0, 0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 306, __pyx_L8_error)
   32631         119 :       __Pyx_GOTREF(__pyx_t_3);
   32632         119 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   32633         119 :       __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 306, __pyx_L8_error)
   32634         119 :       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   32635         119 :       __pyx_v_use_previous = __pyx_t_4;
   32636             : 
   32637             :       /* "_ni_label.pyx":307
   32638             :  *         temp[axis] = 0
   32639             :  *         use_previous = (structure[tuple(temp)] != 0)
   32640             :  *         output_ndim = output.ndim             # <<<<<<<<<<<<<<
   32641             :  *         output_shape = output.shape
   32642             :  *         output_strides = output.strides
   32643             :  */
   32644         119 :       __pyx_v_output_ndim = __pyx_f_5numpy_7ndarray_4ndim_ndim(__pyx_v_output);
   32645             : 
   32646             :       /* "_ni_label.pyx":308
   32647             :  *         use_previous = (structure[tuple(temp)] != 0)
   32648             :  *         output_ndim = output.ndim
   32649             :  *         output_shape = output.shape             # <<<<<<<<<<<<<<
   32650             :  *         output_strides = output.strides
   32651             :  * 
   32652             :  */
   32653         119 :       __pyx_v_output_shape = __pyx_f_5numpy_7ndarray_5shape_shape(__pyx_v_output);
   32654             : 
   32655             :       /* "_ni_label.pyx":309
   32656             :  *         output_ndim = output.ndim
   32657             :  *         output_shape = output.shape
   32658             :  *         output_strides = output.strides             # <<<<<<<<<<<<<<
   32659             :  * 
   32660             :  *         with nogil:
   32661             :  */
   32662         119 :       __pyx_v_output_strides = __pyx_f_5numpy_7ndarray_7strides_strides(__pyx_v_output);
   32663             : 
   32664             :       /* "_ni_label.pyx":311
   32665             :  *         output_strides = output.strides
   32666             :  * 
   32667             :  *         with nogil:             # <<<<<<<<<<<<<<
   32668             :  *             while PyArray_ITER_NOTDONE(iti):
   32669             :  *                 # Optimization - for 2D, line_buffer becomes next iteration's
   32670             :  */
   32671             :       {
   32672             :           #ifdef WITH_THREAD
   32673         119 :           PyThreadState *_save;
   32674         119 :           _save = NULL;
   32675         119 :           Py_UNBLOCK_THREADS
   32676        4579 :           __Pyx_FastGIL_Remember();
   32677             :           #endif
   32678             :           /*try:*/ {
   32679             : 
   32680             :             /* "_ni_label.pyx":312
   32681             :  * 
   32682             :  *         with nogil:
   32683             :  *             while PyArray_ITER_NOTDONE(iti):             # <<<<<<<<<<<<<<
   32684             :  *                 # Optimization - for 2D, line_buffer becomes next iteration's
   32685             :  *                 # neighbor buffer
   32686             :  */
   32687        4579 :             while (1) {
   32688        4579 :               __pyx_t_4 = (PyArray_ITER_NOTDONE(__pyx_v_iti) != 0);
   32689        4579 :               if (!__pyx_t_4) break;
   32690             : 
   32691             :               /* "_ni_label.pyx":315
   32692             :  *                 # Optimization - for 2D, line_buffer becomes next iteration's
   32693             :  *                 # neighbor buffer
   32694             :  *                 if output_ndim == 2:             # <<<<<<<<<<<<<<
   32695             :  *                     tmp = line_buffer
   32696             :  *                     line_buffer = neighbor_buffer
   32697             :  */
   32698        4460 :               __pyx_t_4 = (__pyx_v_output_ndim == 2);
   32699        4460 :               if (__pyx_t_4) {
   32700             : 
   32701             :                 /* "_ni_label.pyx":316
   32702             :  *                 # neighbor buffer
   32703             :  *                 if output_ndim == 2:
   32704             :  *                     tmp = line_buffer             # <<<<<<<<<<<<<<
   32705             :  *                     line_buffer = neighbor_buffer
   32706             :  *                     neighbor_buffer = tmp
   32707             :  */
   32708         716 :                 __pyx_v_tmp = __pyx_v_line_buffer;
   32709             : 
   32710             :                 /* "_ni_label.pyx":317
   32711             :  *                 if output_ndim == 2:
   32712             :  *                     tmp = line_buffer
   32713             :  *                     line_buffer = neighbor_buffer             # <<<<<<<<<<<<<<
   32714             :  *                     neighbor_buffer = tmp
   32715             :  * 
   32716             :  */
   32717         716 :                 __pyx_v_line_buffer = __pyx_v_neighbor_buffer;
   32718             : 
   32719             :                 /* "_ni_label.pyx":318
   32720             :  *                     tmp = line_buffer
   32721             :  *                     line_buffer = neighbor_buffer
   32722             :  *                     neighbor_buffer = tmp             # <<<<<<<<<<<<<<
   32723             :  * 
   32724             :  *                 # copy nonzero values in input to line_buffer as FOREGROUND
   32725             :  */
   32726         716 :                 __pyx_v_neighbor_buffer = __pyx_v_tmp;
   32727             : 
   32728             :                 /* "_ni_label.pyx":315
   32729             :  *                 # Optimization - for 2D, line_buffer becomes next iteration's
   32730             :  *                 # neighbor buffer
   32731             :  *                 if output_ndim == 2:             # <<<<<<<<<<<<<<
   32732             :  *                     tmp = line_buffer
   32733             :  *                     line_buffer = neighbor_buffer
   32734             :  */
   32735             :               }
   32736             : 
   32737             :               /* "_ni_label.pyx":321
   32738             :  * 
   32739             :  *                 # copy nonzero values in input to line_buffer as FOREGROUND
   32740             :  *                 nonzero_line(PyArray_ITER_DATA(iti), si, line_buffer, L)             # <<<<<<<<<<<<<<
   32741             :  * 
   32742             :  *                 # Used for labeling single lines
   32743             :  */
   32744        4460 :               __pyx_v_nonzero_line(PyArray_ITER_DATA(__pyx_v_iti), __pyx_v_si, __pyx_v_line_buffer, __pyx_v_L);
   32745             : 
   32746             :               /* "_ni_label.pyx":324
   32747             :  * 
   32748             :  *                 # Used for labeling single lines
   32749             :  *                 needs_self_labeling = True             # <<<<<<<<<<<<<<
   32750             :  * 
   32751             :  *                 # Take neighbor labels
   32752             :  */
   32753        4460 :               __pyx_v_needs_self_labeling = 1;
   32754             : 
   32755             :               /* "_ni_label.pyx":327
   32756             :  * 
   32757             :  *                 # Take neighbor labels
   32758             :  *                 PyArray_ITER_RESET(itstruct)             # <<<<<<<<<<<<<<
   32759             :  *                 for ni in range(num_neighbors):
   32760             :  *                     neighbor_use_prev = (<np.npy_bool *> PyArray_ITER_DATA(itstruct))[0]
   32761             :  */
   32762        4460 :               PyArray_ITER_RESET(__pyx_v_itstruct);
   32763             : 
   32764             :               /* "_ni_label.pyx":328
   32765             :  *                 # Take neighbor labels
   32766             :  *                 PyArray_ITER_RESET(itstruct)
   32767             :  *                 for ni in range(num_neighbors):             # <<<<<<<<<<<<<<
   32768             :  *                     neighbor_use_prev = (<np.npy_bool *> PyArray_ITER_DATA(itstruct))[0]
   32769             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32770             :  */
   32771        4460 :               __pyx_t_9 = __pyx_v_num_neighbors;
   32772        4460 :               __pyx_t_15 = __pyx_t_9;
   32773       20056 :               for (__pyx_t_16 = 0; __pyx_t_16 < __pyx_t_15; __pyx_t_16+=1) {
   32774       15596 :                 __pyx_v_ni = __pyx_t_16;
   32775             : 
   32776             :                 /* "_ni_label.pyx":329
   32777             :  *                 PyArray_ITER_RESET(itstruct)
   32778             :  *                 for ni in range(num_neighbors):
   32779             :  *                     neighbor_use_prev = (<np.npy_bool *> PyArray_ITER_DATA(itstruct))[0]             # <<<<<<<<<<<<<<
   32780             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32781             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32782             :  */
   32783       15596 :                 __pyx_v_neighbor_use_prev = (((npy_bool *)PyArray_ITER_DATA(__pyx_v_itstruct))[0]);
   32784             : 
   32785             :                 /* "_ni_label.pyx":330
   32786             :  *                 for ni in range(num_neighbors):
   32787             :  *                     neighbor_use_prev = (<np.npy_bool *> PyArray_ITER_DATA(itstruct))[0]
   32788             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]             # <<<<<<<<<<<<<<
   32789             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32790             :  *                     if not (neighbor_use_prev or
   32791             :  */
   32792       15596 :                 __pyx_v_neighbor_use_adjacent = (((npy_bool *)(((char *)PyArray_ITER_DATA(__pyx_v_itstruct)) + __pyx_v_ss))[0]);
   32793             : 
   32794             :                 /* "_ni_label.pyx":331
   32795             :  *                     neighbor_use_prev = (<np.npy_bool *> PyArray_ITER_DATA(itstruct))[0]
   32796             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32797             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]             # <<<<<<<<<<<<<<
   32798             :  *                     if not (neighbor_use_prev or
   32799             :  *                             neighbor_use_adjacent or
   32800             :  */
   32801       15596 :                 __pyx_v_neighbor_use_next = (((npy_bool *)(((char *)PyArray_ITER_DATA(__pyx_v_itstruct)) + (2 * __pyx_v_ss)))[0]);
   32802             : 
   32803             :                 /* "_ni_label.pyx":332
   32804             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32805             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32806             :  *                     if not (neighbor_use_prev or             # <<<<<<<<<<<<<<
   32807             :  *                             neighbor_use_adjacent or
   32808             :  *                             neighbor_use_next):
   32809             :  */
   32810       15596 :                 __pyx_t_10 = (__pyx_v_neighbor_use_prev != 0);
   32811       15596 :                 if (!__pyx_t_10) {
   32812         520 :                 } else {
   32813       15076 :                   __pyx_t_4 = __pyx_t_10;
   32814       15076 :                   goto __pyx_L23_bool_binop_done;
   32815             :                 }
   32816             : 
   32817             :                 /* "_ni_label.pyx":333
   32818             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32819             :  *                     if not (neighbor_use_prev or
   32820             :  *                             neighbor_use_adjacent or             # <<<<<<<<<<<<<<
   32821             :  *                             neighbor_use_next):
   32822             :  *                         PyArray_ITER_NEXT(itstruct)
   32823             :  */
   32824         520 :                 __pyx_t_10 = (__pyx_v_neighbor_use_adjacent != 0);
   32825         520 :                 if (!__pyx_t_10) {
   32826          84 :                 } else {
   32827         436 :                   __pyx_t_4 = __pyx_t_10;
   32828         436 :                   goto __pyx_L23_bool_binop_done;
   32829             :                 }
   32830             : 
   32831             :                 /* "_ni_label.pyx":334
   32832             :  *                     if not (neighbor_use_prev or
   32833             :  *                             neighbor_use_adjacent or
   32834             :  *                             neighbor_use_next):             # <<<<<<<<<<<<<<
   32835             :  *                         PyArray_ITER_NEXT(itstruct)
   32836             :  *                         continue
   32837             :  */
   32838          84 :                 __pyx_t_10 = (__pyx_v_neighbor_use_next != 0);
   32839          84 :                 __pyx_t_4 = __pyx_t_10;
   32840       15596 :                 __pyx_L23_bool_binop_done:;
   32841             : 
   32842             :                 /* "_ni_label.pyx":332
   32843             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32844             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32845             :  *                     if not (neighbor_use_prev or             # <<<<<<<<<<<<<<
   32846             :  *                             neighbor_use_adjacent or
   32847             :  *                             neighbor_use_next):
   32848             :  */
   32849       15596 :                 __pyx_t_10 = (!__pyx_t_4);
   32850       15596 :                 if (__pyx_t_10) {
   32851             : 
   32852             :                   /* "_ni_label.pyx":335
   32853             :  *                             neighbor_use_adjacent or
   32854             :  *                             neighbor_use_next):
   32855             :  *                         PyArray_ITER_NEXT(itstruct)             # <<<<<<<<<<<<<<
   32856             :  *                         continue
   32857             :  * 
   32858             :  */
   32859          42 :                   PyArray_ITER_NEXT(__pyx_v_itstruct);
   32860             : 
   32861             :                   /* "_ni_label.pyx":336
   32862             :  *                             neighbor_use_next):
   32863             :  *                         PyArray_ITER_NEXT(itstruct)
   32864             :  *                         continue             # <<<<<<<<<<<<<<
   32865             :  * 
   32866             :  *                     # Check that the neighbor line is in bounds
   32867             :  */
   32868          42 :                   goto __pyx_L20_continue;
   32869             : 
   32870             :                   /* "_ni_label.pyx":332
   32871             :  *                     neighbor_use_adjacent = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + ss))[0]
   32872             :  *                     neighbor_use_next = (<np.npy_bool *> (<char *> PyArray_ITER_DATA(itstruct) + 2 * ss))[0]
   32873             :  *                     if not (neighbor_use_prev or             # <<<<<<<<<<<<<<
   32874             :  *                             neighbor_use_adjacent or
   32875             :  *                             neighbor_use_next):
   32876             :  */
   32877             :                 }
   32878             : 
   32879             :                 /* "_ni_label.pyx":339
   32880             :  * 
   32881             :  *                     # Check that the neighbor line is in bounds
   32882             :  *                     valid = True             # <<<<<<<<<<<<<<
   32883             :  *                     total_offset = 0
   32884             :  *                     for idim in range(structure_ndim):
   32885             :  */
   32886       50192 :                 __pyx_v_valid = 1;
   32887             : 
   32888             :                 /* "_ni_label.pyx":340
   32889             :  *                     # Check that the neighbor line is in bounds
   32890             :  *                     valid = True
   32891             :  *                     total_offset = 0             # <<<<<<<<<<<<<<
   32892             :  *                     for idim in range(structure_ndim):
   32893             :  *                         if idim == axis:
   32894             :  */
   32895             :                 __pyx_v_total_offset = 0;
   32896             : 
   32897             :                 /* "_ni_label.pyx":341
   32898             :  *                     valid = True
   32899             :  *                     total_offset = 0
   32900             :  *                     for idim in range(structure_ndim):             # <<<<<<<<<<<<<<
   32901             :  *                         if idim == axis:
   32902             :  *                             continue
   32903             :  */
   32904       50192 :                 __pyx_t_17 = __pyx_v_structure_ndim;
   32905       50192 :                 __pyx_t_18 = __pyx_t_17;
   32906       50192 :                 for (__pyx_t_19 = 0; __pyx_t_19 < __pyx_t_18; __pyx_t_19+=1) {
   32907       38453 :                   __pyx_v_idim = __pyx_t_19;
   32908             : 
   32909             :                   /* "_ni_label.pyx":342
   32910             :  *                     total_offset = 0
   32911             :  *                     for idim in range(structure_ndim):
   32912             :  *                         if idim == axis:             # <<<<<<<<<<<<<<
   32913             :  *                             continue
   32914             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32915             :  */
   32916       38453 :                   __pyx_t_10 = (__pyx_v_idim == __pyx_v_axis);
   32917       38453 :                   if (__pyx_t_10) {
   32918             : 
   32919             :                     /* "_ni_label.pyx":343
   32920             :  *                     for idim in range(structure_ndim):
   32921             :  *                         if idim == axis:
   32922             :  *                             continue             # <<<<<<<<<<<<<<
   32923             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32924             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):
   32925             :  */
   32926       11739 :                     goto __pyx_L26_continue;
   32927             : 
   32928             :                     /* "_ni_label.pyx":342
   32929             :  *                     total_offset = 0
   32930             :  *                     for idim in range(structure_ndim):
   32931             :  *                         if idim == axis:             # <<<<<<<<<<<<<<
   32932             :  *                             continue
   32933             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32934             :  */
   32935             :                   }
   32936             : 
   32937             :                   /* "_ni_label.pyx":344
   32938             :  *                         if idim == axis:
   32939             :  *                             continue
   32940             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center             # <<<<<<<<<<<<<<
   32941             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):
   32942             :  *                             valid = False
   32943             :  */
   32944       26714 :                   __pyx_v_delta = ((__pyx_v_itstruct->coordinates[__pyx_v_idim]) - 1);
   32945             : 
   32946             :                   /* "_ni_label.pyx":345
   32947             :  *                             continue
   32948             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32949             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):             # <<<<<<<<<<<<<<
   32950             :  *                             valid = False
   32951             :  *                             break
   32952             :  */
   32953       26714 :                   __pyx_t_20 = ((__pyx_v_ito->coordinates[__pyx_v_idim]) + __pyx_v_delta);
   32954       26714 :                   __pyx_t_10 = (0 <= __pyx_t_20);
   32955       26714 :                   if (__pyx_t_10) {
   32956       22901 :                     __pyx_t_10 = (__pyx_t_20 < (__pyx_v_output_shape[__pyx_v_idim]));
   32957             :                   }
   32958       26714 :                   __pyx_t_4 = (!__pyx_t_10);
   32959       26714 :                   if (__pyx_t_4) {
   32960             : 
   32961             :                     /* "_ni_label.pyx":346
   32962             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32963             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):
   32964             :  *                             valid = False             # <<<<<<<<<<<<<<
   32965             :  *                             break
   32966             :  *                         total_offset += delta * output_strides[idim]
   32967             :  */
   32968        3815 :                     __pyx_v_valid = 0;
   32969             : 
   32970             :                     /* "_ni_label.pyx":347
   32971             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):
   32972             :  *                             valid = False
   32973             :  *                             break             # <<<<<<<<<<<<<<
   32974             :  *                         total_offset += delta * output_strides[idim]
   32975             :  * 
   32976             :  */
   32977        3815 :                     goto __pyx_L27_break;
   32978             : 
   32979             :                     /* "_ni_label.pyx":345
   32980             :  *                             continue
   32981             :  *                         delta = (itstruct.coordinates[idim] - 1)  # 1,1,1... is center
   32982             :  *                         if not (0 <= (ito.coordinates[idim] + delta) < output_shape[idim]):             # <<<<<<<<<<<<<<
   32983             :  *                             valid = False
   32984             :  *                             break
   32985             :  */
   32986             :                   }
   32987             : 
   32988             :                   /* "_ni_label.pyx":348
   32989             :  *                             valid = False
   32990             :  *                             break
   32991             :  *                         total_offset += delta * output_strides[idim]             # <<<<<<<<<<<<<<
   32992             :  * 
   32993             :  *                     if valid:
   32994             :  */
   32995       22899 :                   __pyx_v_total_offset = (__pyx_v_total_offset + (__pyx_v_delta * (__pyx_v_output_strides[__pyx_v_idim])));
   32996       34638 :                   __pyx_L26_continue:;
   32997             :                 }
   32998       11739 :                 __pyx_L27_break:;
   32999             : 
   33000             :                 /* "_ni_label.pyx":350
   33001             :  *                         total_offset += delta * output_strides[idim]
   33002             :  * 
   33003             :  *                     if valid:             # <<<<<<<<<<<<<<
   33004             :  *                         # Optimization (see above) - for 2D, line_buffer
   33005             :  *                         # becomes next iteration's neighbor buffer, so no
   33006             :  */
   33007        3815 :                 if (__pyx_v_valid) {
   33008             : 
   33009             :                   /* "_ni_label.pyx":354
   33010             :  *                         # becomes next iteration's neighbor buffer, so no
   33011             :  *                         # need to read it here.
   33012             :  *                         if output_ndim != 2:             # <<<<<<<<<<<<<<
   33013             :  *                             read_line(<char *> PyArray_ITER_DATA(ito) + total_offset, so,
   33014             :  *                                       neighbor_buffer, L)
   33015             :  */
   33016       11739 :                   __pyx_t_4 = (__pyx_v_output_ndim != 2);
   33017       11739 :                   if (__pyx_t_4) {
   33018             : 
   33019             :                     /* "_ni_label.pyx":355
   33020             :  *                         # need to read it here.
   33021             :  *                         if output_ndim != 2:
   33022             :  *                             read_line(<char *> PyArray_ITER_DATA(ito) + total_offset, so,             # <<<<<<<<<<<<<<
   33023             :  *                                       neighbor_buffer, L)
   33024             :  * 
   33025             :  */
   33026       11153 :                     __pyx_v_read_line((((char *)PyArray_ITER_DATA(__pyx_v_ito)) + __pyx_v_total_offset), __pyx_v_so, __pyx_v_neighbor_buffer, __pyx_v_L);
   33027             : 
   33028             :                     /* "_ni_label.pyx":354
   33029             :  *                         # becomes next iteration's neighbor buffer, so no
   33030             :  *                         # need to read it here.
   33031             :  *                         if output_ndim != 2:             # <<<<<<<<<<<<<<
   33032             :  *                             read_line(<char *> PyArray_ITER_DATA(ito) + total_offset, so,
   33033             :  *                                       neighbor_buffer, L)
   33034             :  */
   33035             :                   }
   33036             : 
   33037             :                   /* "_ni_label.pyx":359
   33038             :  * 
   33039             :  *                         # be conservative about how much space we may need
   33040             :  *                         while mergetable_size < (next_region + L):             # <<<<<<<<<<<<<<
   33041             :  *                             mergetable_size *= 2
   33042             :  *                             mergetable = <np.uintp_t *> \
   33043             :  */
   33044       11805 :                   while (1) {
   33045       11772 :                     __pyx_t_4 = (__pyx_v_mergetable_size < (__pyx_v_next_region + __pyx_v_L));
   33046       11772 :                     if (!__pyx_t_4) break;
   33047             : 
   33048             :                     /* "_ni_label.pyx":360
   33049             :  *                         # be conservative about how much space we may need
   33050             :  *                         while mergetable_size < (next_region + L):
   33051             :  *                             mergetable_size *= 2             # <<<<<<<<<<<<<<
   33052             :  *                             mergetable = <np.uintp_t *> \
   33053             :  *                                 PyDataMem_RENEW(<void *> mergetable,
   33054             :  */
   33055          33 :                     __pyx_v_mergetable_size = (__pyx_v_mergetable_size * 2);
   33056             : 
   33057             :                     /* "_ni_label.pyx":361
   33058             :  *                         while mergetable_size < (next_region + L):
   33059             :  *                             mergetable_size *= 2
   33060             :  *                             mergetable = <np.uintp_t *> \             # <<<<<<<<<<<<<<
   33061             :  *                                 PyDataMem_RENEW(<void *> mergetable,
   33062             :  *                                                  mergetable_size * sizeof(np.uintp_t))
   33063             :  */
   33064          33 :                     __pyx_v_mergetable = ((__pyx_t_5numpy_uintp_t *)PyDataMem_RENEW(((void *)__pyx_v_mergetable), (__pyx_v_mergetable_size * (sizeof(__pyx_t_5numpy_uintp_t)))));
   33065             :                   }
   33066             : 
   33067             :                   /* "_ni_label.pyx":365
   33068             :  *                                                  mergetable_size * sizeof(np.uintp_t))
   33069             :  * 
   33070             :  *                         next_region = label_line_with_neighbor(line_buffer,             # <<<<<<<<<<<<<<
   33071             :  *                                                               neighbor_buffer,
   33072             :  *                                                               neighbor_use_prev,
   33073             :  */
   33074       11739 :                   __pyx_v_next_region = __pyx_f_9_ni_label_label_line_with_neighbor(__pyx_v_line_buffer, __pyx_v_neighbor_buffer, __pyx_v_neighbor_use_prev, __pyx_v_neighbor_use_adjacent, __pyx_v_neighbor_use_next, __pyx_v_L, (__pyx_v_ni == (__pyx_v_num_neighbors - 1)), __pyx_v_use_previous, __pyx_v_next_region, __pyx_v_mergetable);
   33075             : 
   33076             :                   /* "_ni_label.pyx":375
   33077             :  *                                                               next_region,
   33078             :  *                                                               mergetable)
   33079             :  *                         if ni == (num_neighbors - 1):             # <<<<<<<<<<<<<<
   33080             :  *                             needs_self_labeling = False
   33081             :  *                     PyArray_ITER_NEXT(itstruct)
   33082             :  */
   33083       11739 :                   __pyx_t_4 = (__pyx_v_ni == (__pyx_v_num_neighbors - 1));
   33084       11739 :                   if (__pyx_t_4) {
   33085             : 
   33086             :                     /* "_ni_label.pyx":376
   33087             :  *                                                               mergetable)
   33088             :  *                         if ni == (num_neighbors - 1):
   33089             :  *                             needs_self_labeling = False             # <<<<<<<<<<<<<<
   33090             :  *                     PyArray_ITER_NEXT(itstruct)
   33091             :  * 
   33092             :  */
   33093        4303 :                     __pyx_v_needs_self_labeling = 0;
   33094             : 
   33095             :                     /* "_ni_label.pyx":375
   33096             :  *                                                               next_region,
   33097             :  *                                                               mergetable)
   33098             :  *                         if ni == (num_neighbors - 1):             # <<<<<<<<<<<<<<
   33099             :  *                             needs_self_labeling = False
   33100             :  *                     PyArray_ITER_NEXT(itstruct)
   33101             :  */
   33102             :                   }
   33103             : 
   33104             :                   /* "_ni_label.pyx":350
   33105             :  *                         total_offset += delta * output_strides[idim]
   33106             :  * 
   33107             :  *                     if valid:             # <<<<<<<<<<<<<<
   33108             :  *                         # Optimization (see above) - for 2D, line_buffer
   33109             :  *                         # becomes next iteration's neighbor buffer, so no
   33110             :  */
   33111             :                 }
   33112             : 
   33113             :                 /* "_ni_label.pyx":377
   33114             :  *                         if ni == (num_neighbors - 1):
   33115             :  *                             needs_self_labeling = False
   33116             :  *                     PyArray_ITER_NEXT(itstruct)             # <<<<<<<<<<<<<<
   33117             :  * 
   33118             :  *                 if needs_self_labeling:
   33119             :  */
   33120       34154 :                 PyArray_ITER_NEXT(__pyx_v_itstruct);
   33121       15596 :                 __pyx_L20_continue:;
   33122             :               }
   33123             : 
   33124             :               /* "_ni_label.pyx":379
   33125             :  *                     PyArray_ITER_NEXT(itstruct)
   33126             :  * 
   33127             :  *                 if needs_self_labeling:             # <<<<<<<<<<<<<<
   33128             :  *                     # We didn't call label_line_with_neighbor above with
   33129             :  *                     # label_unlabeled=True, so call it now in such a way as to
   33130             :  */
   33131        4460 :               if (__pyx_v_needs_self_labeling) {
   33132             : 
   33133             :                 /* "_ni_label.pyx":383
   33134             :  *                     # label_unlabeled=True, so call it now in such a way as to
   33135             :  *                     # cause unlabeled regions to get a label.
   33136             :  *                     while mergetable_size < (next_region + L):             # <<<<<<<<<<<<<<
   33137             :  *                             mergetable_size *= 2
   33138             :  *                             mergetable = <np.uintp_t *> \
   33139             :  */
   33140         179 :                 while (1) {
   33141         168 :                   __pyx_t_4 = (__pyx_v_mergetable_size < (__pyx_v_next_region + __pyx_v_L));
   33142         168 :                   if (!__pyx_t_4) break;
   33143             : 
   33144             :                   /* "_ni_label.pyx":384
   33145             :  *                     # cause unlabeled regions to get a label.
   33146             :  *                     while mergetable_size < (next_region + L):
   33147             :  *                             mergetable_size *= 2             # <<<<<<<<<<<<<<
   33148             :  *                             mergetable = <np.uintp_t *> \
   33149             :  *                                 PyDataMem_RENEW(<void *> mergetable,
   33150             :  */
   33151          11 :                   __pyx_v_mergetable_size = (__pyx_v_mergetable_size * 2);
   33152             : 
   33153             :                   /* "_ni_label.pyx":385
   33154             :  *                     while mergetable_size < (next_region + L):
   33155             :  *                             mergetable_size *= 2
   33156             :  *                             mergetable = <np.uintp_t *> \             # <<<<<<<<<<<<<<
   33157             :  *                                 PyDataMem_RENEW(<void *> mergetable,
   33158             :  *                                                  mergetable_size * sizeof(np.uintp_t))
   33159             :  */
   33160          11 :                   __pyx_v_mergetable = ((__pyx_t_5numpy_uintp_t *)PyDataMem_RENEW(((void *)__pyx_v_mergetable), (__pyx_v_mergetable_size * (sizeof(__pyx_t_5numpy_uintp_t)))));
   33161             :                 }
   33162             : 
   33163             :                 /* "_ni_label.pyx":389
   33164             :  *                                                  mergetable_size * sizeof(np.uintp_t))
   33165             :  * 
   33166             :  *                     next_region = label_line_with_neighbor(line_buffer,             # <<<<<<<<<<<<<<
   33167             :  *                                                           neighbor_buffer,
   33168             :  *                                                           False, False, False,  # no neighbors
   33169             :  */
   33170         157 :                 __pyx_v_next_region = __pyx_f_9_ni_label_label_line_with_neighbor(__pyx_v_line_buffer, __pyx_v_neighbor_buffer, 0, 0, 0, __pyx_v_L, 1, __pyx_v_use_previous, __pyx_v_next_region, __pyx_v_mergetable);
   33171             : 
   33172             :                 /* "_ni_label.pyx":379
   33173             :  *                     PyArray_ITER_NEXT(itstruct)
   33174             :  * 
   33175             :  *                 if needs_self_labeling:             # <<<<<<<<<<<<<<
   33176             :  *                     # We didn't call label_line_with_neighbor above with
   33177             :  *                     # label_unlabeled=True, so call it now in such a way as to
   33178             :  */
   33179             :               }
   33180             : 
   33181             :               /* "_ni_label.pyx":398
   33182             :  *                                                           mergetable)
   33183             :  * 
   33184             :  *                 overflowed = write_line(PyArray_ITER_DATA(ito), so,             # <<<<<<<<<<<<<<
   33185             :  *                                         line_buffer, L)
   33186             :  *                 if overflowed:
   33187             :  */
   33188        4460 :               __pyx_v_overflowed = __pyx_v_write_line(PyArray_ITER_DATA(__pyx_v_ito), __pyx_v_so, __pyx_v_line_buffer, __pyx_v_L);
   33189             : 
   33190             :               /* "_ni_label.pyx":400
   33191             :  *                 overflowed = write_line(PyArray_ITER_DATA(ito), so,
   33192             :  *                                         line_buffer, L)
   33193             :  *                 if overflowed:             # <<<<<<<<<<<<<<
   33194             :  *                     with gil:
   33195             :  *                         raise NeedMoreBits()
   33196             :  */
   33197        4460 :               if (unlikely(__pyx_v_overflowed)) {
   33198             : 
   33199             :                 /* "_ni_label.pyx":401
   33200             :  *                                         line_buffer, L)
   33201             :  *                 if overflowed:
   33202             :  *                     with gil:             # <<<<<<<<<<<<<<
   33203             :  *                         raise NeedMoreBits()
   33204             :  * 
   33205             :  */
   33206             :                 {
   33207             :                     #ifdef WITH_THREAD
   33208           0 :                     PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
   33209             :                     #endif
   33210             :                     /*try:*/ {
   33211             : 
   33212             :                       /* "_ni_label.pyx":402
   33213             :  *                 if overflowed:
   33214             :  *                     with gil:
   33215             :  *                         raise NeedMoreBits()             # <<<<<<<<<<<<<<
   33216             :  * 
   33217             :  *                 PyArray_ITER_NEXT(iti)
   33218             :  */
   33219           0 :                       __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_NeedMoreBits); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 402, __pyx_L42_error)
   33220           0 :                       __Pyx_GOTREF(__pyx_t_5);
   33221           0 :                       __pyx_t_8 = NULL;
   33222           0 :                       __pyx_t_7 = 0;
   33223             :                       #if CYTHON_UNPACK_METHODS
   33224           0 :                       if (unlikely(PyMethod_Check(__pyx_t_5))) {
   33225           0 :                         __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_5);
   33226           0 :                         if (likely(__pyx_t_8)) {
   33227           0 :                           PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
   33228           0 :                           __Pyx_INCREF(__pyx_t_8);
   33229           0 :                           __Pyx_INCREF(function);
   33230           0 :                           __Pyx_DECREF_SET(__pyx_t_5, function);
   33231             :                           __pyx_t_7 = 1;
   33232             :                         }
   33233             :                       }
   33234             :                       #endif
   33235             :                       {
   33236           0 :                         PyObject *__pyx_callargs[2] = {__pyx_t_8, NULL};
   33237           0 :                         __pyx_t_3 = __Pyx_PyObject_FastCall(__pyx_t_5, __pyx_callargs+1-__pyx_t_7, 0+__pyx_t_7);
   33238           0 :                         __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   33239           0 :                         if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 402, __pyx_L42_error)
   33240           0 :                         __Pyx_GOTREF(__pyx_t_3);
   33241           0 :                         __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   33242             :                       }
   33243           0 :                       __Pyx_Raise(__pyx_t_3, 0, 0, 0);
   33244           0 :                       __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
   33245           0 :                       __PYX_ERR(0, 402, __pyx_L42_error)
   33246             :                     }
   33247             : 
   33248             :                     /* "_ni_label.pyx":401
   33249             :  *                                         line_buffer, L)
   33250             :  *                 if overflowed:
   33251             :  *                     with gil:             # <<<<<<<<<<<<<<
   33252             :  *                         raise NeedMoreBits()
   33253             :  * 
   33254             :  */
   33255             :                     /*finally:*/ {
   33256           0 :                       __pyx_L42_error: {
   33257             :                         #ifdef WITH_THREAD
   33258           0 :                         __Pyx_PyGILState_Release(__pyx_gilstate_save);
   33259             :                         #endif
   33260           0 :                         goto __pyx_L15_error;
   33261             :                       }
   33262             :                     }
   33263             :                 }
   33264             : 
   33265             :                 /* "_ni_label.pyx":400
   33266             :  *                 overflowed = write_line(PyArray_ITER_DATA(ito), so,
   33267             :  *                                         line_buffer, L)
   33268             :  *                 if overflowed:             # <<<<<<<<<<<<<<
   33269             :  *                     with gil:
   33270             :  *                         raise NeedMoreBits()
   33271             :  */
   33272             :               }
   33273             : 
   33274             :               /* "_ni_label.pyx":404
   33275             :  *                         raise NeedMoreBits()
   33276             :  * 
   33277             :  *                 PyArray_ITER_NEXT(iti)             # <<<<<<<<<<<<<<
   33278             :  *                 PyArray_ITER_NEXT(ito)
   33279             :  * 
   33280             :  */
   33281        8184 :               PyArray_ITER_NEXT(__pyx_v_iti);
   33282             : 
   33283             :               /* "_ni_label.pyx":405
   33284             :  * 
   33285             :  *                 PyArray_ITER_NEXT(iti)
   33286             :  *                 PyArray_ITER_NEXT(ito)             # <<<<<<<<<<<<<<
   33287             :  * 
   33288             :  *             # compact the mergetable, mapping each value to its destination
   33289             :  */
   33290        8184 :               PyArray_ITER_NEXT(__pyx_v_ito);
   33291             :             }
   33292             : 
   33293             :             /* "_ni_label.pyx":408
   33294             :  * 
   33295             :  *             # compact the mergetable, mapping each value to its destination
   33296             :  *             mergetable[BACKGROUND] = BACKGROUND             # <<<<<<<<<<<<<<
   33297             :  *             mergetable[FOREGROUND] = -1  # should never be encountered
   33298             :  *             mergetable[2] = 1  # labels started here
   33299             :  */
   33300         119 :             (__pyx_v_mergetable[__pyx_e_9_ni_label_BACKGROUND]) = __pyx_e_9_ni_label_BACKGROUND;
   33301             : 
   33302             :             /* "_ni_label.pyx":409
   33303             :  *             # compact the mergetable, mapping each value to its destination
   33304             :  *             mergetable[BACKGROUND] = BACKGROUND
   33305             :  *             mergetable[FOREGROUND] = -1  # should never be encountered             # <<<<<<<<<<<<<<
   33306             :  *             mergetable[2] = 1  # labels started here
   33307             :  *             dest_label = 2
   33308             :  */
   33309         119 :             (__pyx_v_mergetable[__pyx_e_9_ni_label_FOREGROUND]) = -1L;
   33310             : 
   33311             :             /* "_ni_label.pyx":410
   33312             :  *             mergetable[BACKGROUND] = BACKGROUND
   33313             :  *             mergetable[FOREGROUND] = -1  # should never be encountered
   33314             :  *             mergetable[2] = 1  # labels started here             # <<<<<<<<<<<<<<
   33315             :  *             dest_label = 2
   33316             :  *             # next_region is still the original value -> we found no regions
   33317             :  */
   33318         119 :             (__pyx_v_mergetable[2]) = 1;
   33319             : 
   33320             :             /* "_ni_label.pyx":411
   33321             :  *             mergetable[FOREGROUND] = -1  # should never be encountered
   33322             :  *             mergetable[2] = 1  # labels started here
   33323             :  *             dest_label = 2             # <<<<<<<<<<<<<<
   33324             :  *             # next_region is still the original value -> we found no regions
   33325             :  *             # set dest_label to 1 so we return 0
   33326             :  */
   33327         119 :             __pyx_v_dest_label = 2;
   33328             : 
   33329             :             /* "_ni_label.pyx":414
   33330             :  *             # next_region is still the original value -> we found no regions
   33331             :  *             # set dest_label to 1 so we return 0
   33332             :  *             if next_region < 3:             # <<<<<<<<<<<<<<
   33333             :  *                 dest_label = 1
   33334             :  *             for src_label in range(3, next_region):
   33335             :  */
   33336         119 :             __pyx_t_4 = (__pyx_v_next_region < 3);
   33337         119 :             if (__pyx_t_4) {
   33338             : 
   33339             :               /* "_ni_label.pyx":415
   33340             :  *             # set dest_label to 1 so we return 0
   33341             :  *             if next_region < 3:
   33342             :  *                 dest_label = 1             # <<<<<<<<<<<<<<
   33343             :  *             for src_label in range(3, next_region):
   33344             :  *                 # labels that map to themselves are new regions
   33345             :  */
   33346           2 :               __pyx_v_dest_label = 1;
   33347             : 
   33348             :               /* "_ni_label.pyx":414
   33349             :  *             # next_region is still the original value -> we found no regions
   33350             :  *             # set dest_label to 1 so we return 0
   33351             :  *             if next_region < 3:             # <<<<<<<<<<<<<<
   33352             :  *                 dest_label = 1
   33353             :  *             for src_label in range(3, next_region):
   33354             :  */
   33355             :             }
   33356             : 
   33357             :             /* "_ni_label.pyx":416
   33358             :  *             if next_region < 3:
   33359             :  *                 dest_label = 1
   33360             :  *             for src_label in range(3, next_region):             # <<<<<<<<<<<<<<
   33361             :  *                 # labels that map to themselves are new regions
   33362             :  *                 if mergetable[src_label] == src_label:
   33363             :  */
   33364             :             __pyx_t_21 = __pyx_v_next_region;
   33365             :             __pyx_t_22 = __pyx_t_21;
   33366      120993 :             for (__pyx_t_23 = 3; __pyx_t_23 < __pyx_t_22; __pyx_t_23+=1) {
   33367      120874 :               __pyx_v_src_label = __pyx_t_23;
   33368             : 
   33369             :               /* "_ni_label.pyx":418
   33370             :  *             for src_label in range(3, next_region):
   33371             :  *                 # labels that map to themselves are new regions
   33372             :  *                 if mergetable[src_label] == src_label:             # <<<<<<<<<<<<<<
   33373             :  *                     mergetable[src_label] = dest_label
   33374             :  *                     dest_label += 1
   33375             :  */
   33376      120874 :               __pyx_t_4 = ((__pyx_v_mergetable[__pyx_v_src_label]) == __pyx_v_src_label);
   33377      120874 :               if (__pyx_t_4) {
   33378             : 
   33379             :                 /* "_ni_label.pyx":419
   33380             :  *                 # labels that map to themselves are new regions
   33381             :  *                 if mergetable[src_label] == src_label:
   33382             :  *                     mergetable[src_label] = dest_label             # <<<<<<<<<<<<<<
   33383             :  *                     dest_label += 1
   33384             :  *                 else:
   33385             :  */
   33386        3314 :                 (__pyx_v_mergetable[__pyx_v_src_label]) = __pyx_v_dest_label;
   33387             : 
   33388             :                 /* "_ni_label.pyx":420
   33389             :  *                 if mergetable[src_label] == src_label:
   33390             :  *                     mergetable[src_label] = dest_label
   33391             :  *                     dest_label += 1             # <<<<<<<<<<<<<<
   33392             :  *                 else:
   33393             :  *                     # we've compacted every label below this, and the
   33394             :  */
   33395        3314 :                 __pyx_v_dest_label = (__pyx_v_dest_label + 1);
   33396             : 
   33397             :                 /* "_ni_label.pyx":418
   33398             :  *             for src_label in range(3, next_region):
   33399             :  *                 # labels that map to themselves are new regions
   33400             :  *                 if mergetable[src_label] == src_label:             # <<<<<<<<<<<<<<
   33401             :  *                     mergetable[src_label] = dest_label
   33402             :  *                     dest_label += 1
   33403             :  */
   33404        3314 :                 goto __pyx_L47;
   33405             :               }
   33406             : 
   33407             :               /* "_ni_label.pyx":426
   33408             :  *                     # it always points downward.  Therefore, we can fetch the
   33409             :  *                     # final label by two steps of indirection.
   33410             :  *                     mergetable[src_label] = mergetable[mergetable[src_label]]             # <<<<<<<<<<<<<<
   33411             :  * 
   33412             :  *             PyArray_ITER_RESET(ito)
   33413             :  */
   33414             :               /*else*/ {
   33415      117560 :                 (__pyx_v_mergetable[__pyx_v_src_label]) = (__pyx_v_mergetable[(__pyx_v_mergetable[__pyx_v_src_label])]);
   33416             :               }
   33417      120874 :               __pyx_L47:;
   33418             :             }
   33419             : 
   33420             :             /* "_ni_label.pyx":428
   33421             :  *                     mergetable[src_label] = mergetable[mergetable[src_label]]
   33422             :  * 
   33423             :  *             PyArray_ITER_RESET(ito)             # <<<<<<<<<<<<<<
   33424             :  *             while PyArray_ITER_NOTDONE(ito):
   33425             :  *                 read_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33426             :  */
   33427         119 :             PyArray_ITER_RESET(__pyx_v_ito);
   33428             : 
   33429             :             /* "_ni_label.pyx":429
   33430             :  * 
   33431             :  *             PyArray_ITER_RESET(ito)
   33432             :  *             while PyArray_ITER_NOTDONE(ito):             # <<<<<<<<<<<<<<
   33433             :  *                 read_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33434             :  *                 for i in range(L):
   33435             :  */
   33436        4579 :             while (1) {
   33437        4579 :               __pyx_t_4 = (PyArray_ITER_NOTDONE(__pyx_v_ito) != 0);
   33438        4579 :               if (!__pyx_t_4) break;
   33439             : 
   33440             :               /* "_ni_label.pyx":430
   33441             :  *             PyArray_ITER_RESET(ito)
   33442             :  *             while PyArray_ITER_NOTDONE(ito):
   33443             :  *                 read_line(PyArray_ITER_DATA(ito), so, line_buffer, L)             # <<<<<<<<<<<<<<
   33444             :  *                 for i in range(L):
   33445             :  *                     line_buffer[i] = mergetable[line_buffer[i]]
   33446             :  */
   33447        4460 :               __pyx_v_read_line(PyArray_ITER_DATA(__pyx_v_ito), __pyx_v_so, __pyx_v_line_buffer, __pyx_v_L);
   33448             : 
   33449             :               /* "_ni_label.pyx":431
   33450             :  *             while PyArray_ITER_NOTDONE(ito):
   33451             :  *                 read_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33452             :  *                 for i in range(L):             # <<<<<<<<<<<<<<
   33453             :  *                     line_buffer[i] = mergetable[line_buffer[i]]
   33454             :  *                 write_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33455             :  */
   33456        4460 :               __pyx_t_17 = __pyx_v_L;
   33457        4460 :               __pyx_t_18 = __pyx_t_17;
   33458     4647183 :               for (__pyx_t_20 = 0; __pyx_t_20 < __pyx_t_18; __pyx_t_20+=1) {
   33459     4638263 :                 __pyx_v_i = __pyx_t_20;
   33460             : 
   33461             :                 /* "_ni_label.pyx":432
   33462             :  *                 read_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33463             :  *                 for i in range(L):
   33464             :  *                     line_buffer[i] = mergetable[line_buffer[i]]             # <<<<<<<<<<<<<<
   33465             :  *                 write_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33466             :  *                 PyArray_ITER_NEXT(ito)
   33467             :  */
   33468     4638263 :                 (__pyx_v_line_buffer[__pyx_v_i]) = (__pyx_v_mergetable[(__pyx_v_line_buffer[__pyx_v_i])]);
   33469             :               }
   33470             : 
   33471             :               /* "_ni_label.pyx":433
   33472             :  *                 for i in range(L):
   33473             :  *                     line_buffer[i] = mergetable[line_buffer[i]]
   33474             :  *                 write_line(PyArray_ITER_DATA(ito), so, line_buffer, L)             # <<<<<<<<<<<<<<
   33475             :  *                 PyArray_ITER_NEXT(ito)
   33476             :  *     except:  # noqa: E722
   33477             :  */
   33478        4460 :               (void)(__pyx_v_write_line(PyArray_ITER_DATA(__pyx_v_ito), __pyx_v_so, __pyx_v_line_buffer, __pyx_v_L));
   33479             : 
   33480             :               /* "_ni_label.pyx":434
   33481             :  *                     line_buffer[i] = mergetable[line_buffer[i]]
   33482             :  *                 write_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33483             :  *                 PyArray_ITER_NEXT(ito)             # <<<<<<<<<<<<<<
   33484             :  *     except:  # noqa: E722
   33485             :  *         # clean up and re-raise
   33486             :  */
   33487        8184 :               PyArray_ITER_NEXT(__pyx_v_ito);
   33488             :             }
   33489             :           }
   33490             : 
   33491             :           /* "_ni_label.pyx":311
   33492             :  *         output_strides = output.strides
   33493             :  * 
   33494             :  *         with nogil:             # <<<<<<<<<<<<<<
   33495             :  *             while PyArray_ITER_NOTDONE(iti):
   33496             :  *                 # Optimization - for 2D, line_buffer becomes next iteration's
   33497             :  */
   33498             :           /*finally:*/ {
   33499             :             /*normal exit:*/{
   33500             :               #ifdef WITH_THREAD
   33501         119 :               __Pyx_FastGIL_Forget();
   33502         119 :               Py_BLOCK_THREADS
   33503             :               #endif
   33504         119 :               goto __pyx_L16;
   33505             :             }
   33506           0 :             __pyx_L15_error: {
   33507             :               #ifdef WITH_THREAD
   33508           0 :               __Pyx_FastGIL_Forget();
   33509           0 :               Py_BLOCK_THREADS
   33510             :               #endif
   33511           0 :               goto __pyx_L8_error;
   33512             :             }
   33513         119 :             __pyx_L16:;
   33514             :           }
   33515             :       }
   33516             : 
   33517             :       /* "_ni_label.pyx":292
   33518             :  *         raise MemoryError()
   33519             :  * 
   33520             :  *     try:             # <<<<<<<<<<<<<<
   33521             :  *         # strides
   33522             :  *         si = input.strides[axis]
   33523             :  */
   33524             :     }
   33525         119 :     __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0;
   33526         119 :     __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0;
   33527         119 :     __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0;
   33528         119 :     goto __pyx_L13_try_end;
   33529           0 :     __pyx_L8_error:;
   33530           0 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   33531           0 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   33532           0 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   33533           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   33534           0 :     __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
   33535           0 :     __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
   33536             : 
   33537             :     /* "_ni_label.pyx":435
   33538             :  *                 write_line(PyArray_ITER_DATA(ito), so, line_buffer, L)
   33539             :  *                 PyArray_ITER_NEXT(ito)
   33540             :  *     except:  # noqa: E722             # <<<<<<<<<<<<<<
   33541             :  *         # clean up and re-raise
   33542             :  *         PyDataMem_FREE(<void *> mergetable)
   33543             :  */
   33544             :     /*except:*/ {
   33545           0 :       __Pyx_AddTraceback("_ni_label._label", __pyx_clineno, __pyx_lineno, __pyx_filename);
   33546           0 :       if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_5, &__pyx_t_8) < 0) __PYX_ERR(0, 435, __pyx_L10_except_error)
   33547           0 :       __Pyx_XGOTREF(__pyx_t_3);
   33548           0 :       __Pyx_XGOTREF(__pyx_t_5);
   33549           0 :       __Pyx_XGOTREF(__pyx_t_8);
   33550             : 
   33551             :       /* "_ni_label.pyx":437
   33552             :  *     except:  # noqa: E722
   33553             :  *         # clean up and re-raise
   33554             :  *         PyDataMem_FREE(<void *> mergetable)             # <<<<<<<<<<<<<<
   33555             :  *         raise
   33556             :  * 
   33557             :  */
   33558           0 :       PyDataMem_FREE(((void *)__pyx_v_mergetable));
   33559             : 
   33560             :       /* "_ni_label.pyx":438
   33561             :  *         # clean up and re-raise
   33562             :  *         PyDataMem_FREE(<void *> mergetable)
   33563             :  *         raise             # <<<<<<<<<<<<<<
   33564             :  * 
   33565             :  *     PyDataMem_FREE(<void *> mergetable)
   33566             :  */
   33567           0 :       __Pyx_GIVEREF(__pyx_t_3);
   33568           0 :       __Pyx_GIVEREF(__pyx_t_5);
   33569           0 :       __Pyx_XGIVEREF(__pyx_t_8);
   33570           0 :       __Pyx_ErrRestoreWithState(__pyx_t_3, __pyx_t_5, __pyx_t_8);
   33571           0 :       __pyx_t_3 = 0; __pyx_t_5 = 0; __pyx_t_8 = 0; 
   33572           0 :       __PYX_ERR(0, 438, __pyx_L10_except_error)
   33573             :     }
   33574             : 
   33575             :     /* "_ni_label.pyx":292
   33576             :  *         raise MemoryError()
   33577             :  * 
   33578             :  *     try:             # <<<<<<<<<<<<<<
   33579             :  *         # strides
   33580             :  *         si = input.strides[axis]
   33581             :  */
   33582           0 :     __pyx_L10_except_error:;
   33583           0 :     __Pyx_XGIVEREF(__pyx_t_12);
   33584           0 :     __Pyx_XGIVEREF(__pyx_t_13);
   33585           0 :     __Pyx_XGIVEREF(__pyx_t_14);
   33586           0 :     __Pyx_ExceptionReset(__pyx_t_12, __pyx_t_13, __pyx_t_14);
   33587           0 :     goto __pyx_L1_error;
   33588         119 :     __pyx_L13_try_end:;
   33589             :   }
   33590             : 
   33591             :   /* "_ni_label.pyx":440
   33592             :  *         raise
   33593             :  * 
   33594             :  *     PyDataMem_FREE(<void *> mergetable)             # <<<<<<<<<<<<<<
   33595             :  *     return dest_label - 1
   33596             :  */
   33597         119 :   PyDataMem_FREE(((void *)__pyx_v_mergetable));
   33598             : 
   33599             :   /* "_ni_label.pyx":441
   33600             :  * 
   33601             :  *     PyDataMem_FREE(<void *> mergetable)
   33602             :  *     return dest_label - 1             # <<<<<<<<<<<<<<
   33603             :  */
   33604         119 :   __Pyx_XDECREF(__pyx_r);
   33605         119 :   __pyx_t_8 = __Pyx_PyInt_From_npy_uintp((__pyx_v_dest_label - 1)); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 441, __pyx_L1_error)
   33606         119 :   __Pyx_GOTREF(__pyx_t_8);
   33607         119 :   __pyx_r = __pyx_t_8;
   33608         119 :   __pyx_t_8 = 0;
   33609         119 :   goto __pyx_L0;
   33610             : 
   33611             :   /* "_ni_label.pyx":200
   33612             :  * # Label regions
   33613             :  * ######################################################################
   33614             :  * cpdef _label(np.ndarray input,             # <<<<<<<<<<<<<<
   33615             :  *              np.ndarray structure,
   33616             :  *              np.ndarray output):
   33617             :  */
   33618             : 
   33619             :   /* function exit code */
   33620           0 :   __pyx_L1_error:;
   33621           0 :   __Pyx_XDECREF(__pyx_t_1);
   33622           0 :   __Pyx_XDECREF(__pyx_t_2);
   33623           0 :   __Pyx_XDECREF(__pyx_t_3);
   33624           0 :   __Pyx_XDECREF(__pyx_t_5);
   33625           0 :   __Pyx_XDECREF(__pyx_t_6);
   33626           0 :   __Pyx_XDECREF(__pyx_t_8);
   33627           0 :   __Pyx_AddTraceback("_ni_label._label", __pyx_clineno, __pyx_lineno, __pyx_filename);
   33628           0 :   __pyx_r = 0;
   33629         119 :   __pyx_L0:;
   33630         119 :   __Pyx_XDECREF((PyObject *)__pyx_v__iti);
   33631         119 :   __Pyx_XDECREF((PyObject *)__pyx_v__ito);
   33632         119 :   __Pyx_XDECREF((PyObject *)__pyx_v__itstruct);
   33633         119 :   __Pyx_XDECREF((PyObject *)__pyx_v__line_buffer);
   33634         119 :   __Pyx_XDECREF((PyObject *)__pyx_v__neighbor_buffer);
   33635         119 :   __Pyx_XDECREF(__pyx_v_temp);
   33636         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_input);
   33637         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_structure);
   33638         119 :   __Pyx_XDECREF((PyObject *)__pyx_v_output);
   33639         119 :   __Pyx_XGIVEREF(__pyx_r);
   33640         119 :   __Pyx_RefNannyFinishContext();
   33641         119 :   return __pyx_r;
   33642             : }
   33643             : 
   33644             : /* Python wrapper */
   33645             : static PyObject *__pyx_pw_9_ni_label_7_label(PyObject *__pyx_self, 
   33646             : #if CYTHON_METH_FASTCALL
   33647             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   33648             : #else
   33649             : PyObject *__pyx_args, PyObject *__pyx_kwds
   33650             : #endif
   33651             : ); /*proto*/
   33652             : static PyMethodDef __pyx_mdef_9_ni_label_7_label = {"_label", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw_9_ni_label_7_label, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0};
   33653         119 : static PyObject *__pyx_pw_9_ni_label_7_label(PyObject *__pyx_self, 
   33654             : #if CYTHON_METH_FASTCALL
   33655             : PyObject *const *__pyx_args, Py_ssize_t __pyx_nargs, PyObject *__pyx_kwds
   33656             : #else
   33657             : PyObject *__pyx_args, PyObject *__pyx_kwds
   33658             : #endif
   33659             : ) {
   33660         119 :   PyArrayObject *__pyx_v_input = 0;
   33661         119 :   PyArrayObject *__pyx_v_structure = 0;
   33662         119 :   PyArrayObject *__pyx_v_output = 0;
   33663             :   #if !CYTHON_METH_FASTCALL
   33664             :   CYTHON_UNUSED Py_ssize_t __pyx_nargs;
   33665             :   #endif
   33666         119 :   CYTHON_UNUSED PyObject *const *__pyx_kwvalues;
   33667         119 :   PyObject* values[3] = {0,0,0};
   33668         119 :   int __pyx_lineno = 0;
   33669         119 :   const char *__pyx_filename = NULL;
   33670         119 :   int __pyx_clineno = 0;
   33671         119 :   PyObject *__pyx_r = 0;
   33672             :   __Pyx_RefNannyDeclarations
   33673         119 :   __Pyx_RefNannySetupContext("_label (wrapper)", 0);
   33674             :   #if !CYTHON_METH_FASTCALL
   33675             :   #if CYTHON_ASSUME_SAFE_MACROS
   33676             :   __pyx_nargs = PyTuple_GET_SIZE(__pyx_args);
   33677             :   #else
   33678             :   __pyx_nargs = PyTuple_Size(__pyx_args); if (unlikely(__pyx_nargs < 0)) return NULL;
   33679             :   #endif
   33680             :   #endif
   33681         119 :   __pyx_kwvalues = __Pyx_KwValues_FASTCALL(__pyx_args, __pyx_nargs);
   33682             :   {
   33683         119 :     PyObject **__pyx_pyargnames[] = {&__pyx_n_s_input,&__pyx_n_s_structure,&__pyx_n_s_output,0};
   33684         119 :     if (__pyx_kwds) {
   33685           0 :       Py_ssize_t kw_args;
   33686           0 :       switch (__pyx_nargs) {
   33687           0 :         case  3: values[2] = __Pyx_Arg_FASTCALL(__pyx_args, 2);
   33688           0 :         CYTHON_FALLTHROUGH;
   33689           0 :         case  2: values[1] = __Pyx_Arg_FASTCALL(__pyx_args, 1);
   33690           0 :         CYTHON_FALLTHROUGH;
   33691           0 :         case  1: values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   33692           0 :         CYTHON_FALLTHROUGH;
   33693           0 :         case  0: break;
   33694           0 :         default: goto __pyx_L5_argtuple_error;
   33695             :       }
   33696           0 :       kw_args = __Pyx_NumKwargs_FASTCALL(__pyx_kwds);
   33697           0 :       switch (__pyx_nargs) {
   33698           0 :         case  0:
   33699           0 :         if (likely((values[0] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_input)) != 0)) {
   33700           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[0]);
   33701           0 :           kw_args--;
   33702             :         }
   33703           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 200, __pyx_L3_error)
   33704           0 :         else goto __pyx_L5_argtuple_error;
   33705           0 :         CYTHON_FALLTHROUGH;
   33706             :         case  1:
   33707           0 :         if (likely((values[1] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_structure)) != 0)) {
   33708           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[1]);
   33709           0 :           kw_args--;
   33710             :         }
   33711           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 200, __pyx_L3_error)
   33712             :         else {
   33713           0 :           __Pyx_RaiseArgtupleInvalid("_label", 1, 3, 3, 1); __PYX_ERR(0, 200, __pyx_L3_error)
   33714             :         }
   33715           0 :         CYTHON_FALLTHROUGH;
   33716             :         case  2:
   33717           0 :         if (likely((values[2] = __Pyx_GetKwValue_FASTCALL(__pyx_kwds, __pyx_kwvalues, __pyx_n_s_output)) != 0)) {
   33718           0 :           (void)__Pyx_Arg_NewRef_FASTCALL(values[2]);
   33719           0 :           kw_args--;
   33720             :         }
   33721           0 :         else if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 200, __pyx_L3_error)
   33722             :         else {
   33723           0 :           __Pyx_RaiseArgtupleInvalid("_label", 1, 3, 3, 2); __PYX_ERR(0, 200, __pyx_L3_error)
   33724             :         }
   33725             :       }
   33726           0 :       if (unlikely(kw_args > 0)) {
   33727           0 :         const Py_ssize_t kwd_pos_args = __pyx_nargs;
   33728           0 :         if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_kwvalues, __pyx_pyargnames, 0, values + 0, kwd_pos_args, "_label") < 0)) __PYX_ERR(0, 200, __pyx_L3_error)
   33729             :       }
   33730         119 :     } else if (unlikely(__pyx_nargs != 3)) {
   33731           0 :       goto __pyx_L5_argtuple_error;
   33732             :     } else {
   33733         119 :       values[0] = __Pyx_Arg_FASTCALL(__pyx_args, 0);
   33734         119 :       values[1] = __Pyx_Arg_FASTCALL(__pyx_args, 1);
   33735         119 :       values[2] = __Pyx_Arg_FASTCALL(__pyx_args, 2);
   33736             :     }
   33737         119 :     __pyx_v_input = ((PyArrayObject *)values[0]);
   33738         119 :     __pyx_v_structure = ((PyArrayObject *)values[1]);
   33739         119 :     __pyx_v_output = ((PyArrayObject *)values[2]);
   33740             :   }
   33741         119 :   goto __pyx_L6_skip;
   33742           0 :   __pyx_L5_argtuple_error:;
   33743           0 :   __Pyx_RaiseArgtupleInvalid("_label", 1, 3, 3, __pyx_nargs); __PYX_ERR(0, 200, __pyx_L3_error)
   33744         119 :   __pyx_L6_skip:;
   33745         119 :   goto __pyx_L4_argument_unpacking_done;
   33746           0 :   __pyx_L3_error:;
   33747             :   {
   33748           0 :     Py_ssize_t __pyx_temp;
   33749           0 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   33750             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   33751             :     }
   33752             :   }
   33753           0 :   __Pyx_AddTraceback("_ni_label._label", __pyx_clineno, __pyx_lineno, __pyx_filename);
   33754           0 :   __Pyx_RefNannyFinishContext();
   33755           0 :   return NULL;
   33756         119 :   __pyx_L4_argument_unpacking_done:;
   33757         119 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_input), __pyx_ptype_5numpy_ndarray, 1, "input", 0))) __PYX_ERR(0, 200, __pyx_L1_error)
   33758         119 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_structure), __pyx_ptype_5numpy_ndarray, 1, "structure", 0))) __PYX_ERR(0, 201, __pyx_L1_error)
   33759         119 :   if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) __PYX_ERR(0, 202, __pyx_L1_error)
   33760         119 :   __pyx_r = __pyx_pf_9_ni_label_6_label(__pyx_self, __pyx_v_input, __pyx_v_structure, __pyx_v_output);
   33761             : 
   33762             :   /* function exit code */
   33763         119 :   goto __pyx_L0;
   33764             :   __pyx_L1_error:;
   33765             :   __pyx_r = NULL;
   33766         119 :   __pyx_L0:;
   33767             :   {
   33768         119 :     Py_ssize_t __pyx_temp;
   33769         119 :     for (__pyx_temp=0; __pyx_temp < (Py_ssize_t)(sizeof(values)/sizeof(values[0])); ++__pyx_temp) {
   33770             :       __Pyx_Arg_XDECREF_FASTCALL(values[__pyx_temp]);
   33771             :     }
   33772             :   }
   33773             :   __Pyx_RefNannyFinishContext();
   33774             :   return __pyx_r;
   33775             : }
   33776             : 
   33777         119 : static PyObject *__pyx_pf_9_ni_label_6_label(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_input, PyArrayObject *__pyx_v_structure, PyArrayObject *__pyx_v_output) {
   33778         119 :   PyObject *__pyx_r = NULL;
   33779             :   __Pyx_RefNannyDeclarations
   33780         119 :   PyObject *__pyx_t_1 = NULL;
   33781         119 :   int __pyx_lineno = 0;
   33782         119 :   const char *__pyx_filename = NULL;
   33783         119 :   int __pyx_clineno = 0;
   33784         119 :   __Pyx_RefNannySetupContext("_label", 1);
   33785         119 :   __Pyx_XDECREF(__pyx_r);
   33786         119 :   __pyx_t_1 = __pyx_f_9_ni_label__label(__pyx_v_input, __pyx_v_structure, __pyx_v_output, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 200, __pyx_L1_error)
   33787         119 :   __Pyx_GOTREF(__pyx_t_1);
   33788         119 :   __pyx_r = __pyx_t_1;
   33789         119 :   __pyx_t_1 = 0;
   33790         119 :   goto __pyx_L0;
   33791             : 
   33792             :   /* function exit code */
   33793           0 :   __pyx_L1_error:;
   33794           0 :   __Pyx_XDECREF(__pyx_t_1);
   33795           0 :   __Pyx_AddTraceback("_ni_label._label", __pyx_clineno, __pyx_lineno, __pyx_filename);
   33796           0 :   __pyx_r = NULL;
   33797         119 :   __pyx_L0:;
   33798         119 :   __Pyx_XGIVEREF(__pyx_r);
   33799         119 :   __Pyx_RefNannyFinishContext();
   33800         119 :   return __pyx_r;
   33801             : }
   33802             : static struct __pyx_vtabstruct_array __pyx_vtable_array;
   33803             : 
   33804           0 : static PyObject *__pyx_tp_new_array(PyTypeObject *t, PyObject *a, PyObject *k) {
   33805           0 :   struct __pyx_array_obj *p;
   33806           0 :   PyObject *o;
   33807             :   #if CYTHON_COMPILING_IN_LIMITED_API
   33808             :   allocfunc alloc_func = (allocfunc)PyType_GetSlot(t, Py_tp_alloc);
   33809             :   o = alloc_func(t, 0);
   33810             :   #else
   33811           0 :   if (likely(!__Pyx_PyType_HasFeature(t, Py_TPFLAGS_IS_ABSTRACT))) {
   33812           0 :     o = (*t->tp_alloc)(t, 0);
   33813             :   } else {
   33814           0 :     o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
   33815             :   }
   33816           0 :   if (unlikely(!o)) return 0;
   33817             :   #endif
   33818           0 :   p = ((struct __pyx_array_obj *)o);
   33819           0 :   p->__pyx_vtab = __pyx_vtabptr_array;
   33820           0 :   p->mode = ((PyObject*)Py_None); Py_INCREF(Py_None);
   33821           0 :   p->_format = ((PyObject*)Py_None); Py_INCREF(Py_None);
   33822           0 :   if (unlikely(__pyx_array___cinit__(o, a, k) < 0)) goto bad;
   33823             :   return o;
   33824           0 :   bad:
   33825           0 :   Py_DECREF(o); o = 0;
   33826             :   return NULL;
   33827             : }
   33828             : 
   33829           0 : static void __pyx_tp_dealloc_array(PyObject *o) {
   33830           0 :   struct __pyx_array_obj *p = (struct __pyx_array_obj *)o;
   33831             :   #if CYTHON_USE_TP_FINALIZE
   33832           0 :   if (unlikely((PY_VERSION_HEX >= 0x03080000 || __Pyx_PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE)) && __Pyx_PyObject_GetSlot(o, tp_finalize, destructor)) && (!PyType_IS_GC(Py_TYPE(o)) || !__Pyx_PyObject_GC_IsFinalized(o))) {
   33833           0 :     if (__Pyx_PyObject_GetSlot(o, tp_dealloc, destructor) == __pyx_tp_dealloc_array) {
   33834           0 :       if (PyObject_CallFinalizerFromDealloc(o)) return;
   33835             :     }
   33836             :   }
   33837             :   #endif
   33838             :   {
   33839           0 :     PyObject *etype, *eval, *etb;
   33840           0 :     PyErr_Fetch(&etype, &eval, &etb);
   33841           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
   33842           0 :     __pyx_array___dealloc__(o);
   33843           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
   33844           0 :     PyErr_Restore(etype, eval, etb);
   33845             :   }
   33846           0 :   Py_CLEAR(p->mode);
   33847           0 :   Py_CLEAR(p->_format);
   33848             :   #if CYTHON_USE_TYPE_SLOTS || CYTHON_COMPILING_IN_PYPY
   33849           0 :   (*Py_TYPE(o)->tp_free)(o);
   33850             :   #else
   33851             :   {
   33852             :     freefunc tp_free = (freefunc)PyType_GetSlot(Py_TYPE(o), Py_tp_free);
   33853             :     if (tp_free) tp_free(o);
   33854             :   }
   33855             :   #endif
   33856             : }
   33857           0 : static PyObject *__pyx_sq_item_array(PyObject *o, Py_ssize_t i) {
   33858           0 :   PyObject *r;
   33859           0 :   PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
   33860           0 :   r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
   33861           0 :   Py_DECREF(x);
   33862             :   return r;
   33863             : }
   33864             : 
   33865           0 : static int __pyx_mp_ass_subscript_array(PyObject *o, PyObject *i, PyObject *v) {
   33866           0 :   if (v) {
   33867           0 :     return __pyx_array___setitem__(o, i, v);
   33868             :   }
   33869             :   else {
   33870           0 :     __Pyx_TypeName o_type_name;
   33871           0 :     o_type_name = __Pyx_PyType_GetName(Py_TYPE(o));
   33872           0 :     PyErr_Format(PyExc_NotImplementedError,
   33873             :       "Subscript deletion not supported by " __Pyx_FMT_TYPENAME, o_type_name);
   33874           0 :     __Pyx_DECREF_TypeName(o_type_name);
   33875           0 :     return -1;
   33876             :   }
   33877             : }
   33878             : 
   33879           0 : static PyObject *__pyx_tp_getattro_array(PyObject *o, PyObject *n) {
   33880           0 :   PyObject *v = __Pyx_PyObject_GenericGetAttr(o, n);
   33881           0 :   if (!v && PyErr_ExceptionMatches(PyExc_AttributeError)) {
   33882           0 :     PyErr_Clear();
   33883           0 :     v = __pyx_array___getattr__(o, n);
   33884             :   }
   33885           0 :   return v;
   33886             : }
   33887             : 
   33888           0 : static PyObject *__pyx_getprop___pyx_array_memview(PyObject *o, CYTHON_UNUSED void *x) {
   33889           0 :   return __pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(o);
   33890             : }
   33891             : 
   33892             : static PyMethodDef __pyx_methods_array[] = {
   33893             :   {"__getattr__", (PyCFunction)__pyx_array___getattr__, METH_O|METH_COEXIST, 0},
   33894             :   {"__reduce_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_array_1__reduce_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   33895             :   {"__setstate_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_array_3__setstate_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   33896             :   {0, 0, 0, 0}
   33897             : };
   33898             : 
   33899             : static struct PyGetSetDef __pyx_getsets_array[] = {
   33900             :   {(char *)"memview", __pyx_getprop___pyx_array_memview, 0, (char *)0, 0},
   33901             :   {0, 0, 0, 0, 0}
   33902             : };
   33903             : #if CYTHON_USE_TYPE_SPECS
   33904             : #if !CYTHON_COMPILING_IN_LIMITED_API
   33905             : 
   33906             : static PyBufferProcs __pyx_tp_as_buffer_array = {
   33907             :   #if PY_MAJOR_VERSION < 3
   33908             :   0, /*bf_getreadbuffer*/
   33909             :   #endif
   33910             :   #if PY_MAJOR_VERSION < 3
   33911             :   0, /*bf_getwritebuffer*/
   33912             :   #endif
   33913             :   #if PY_MAJOR_VERSION < 3
   33914             :   0, /*bf_getsegcount*/
   33915             :   #endif
   33916             :   #if PY_MAJOR_VERSION < 3
   33917             :   0, /*bf_getcharbuffer*/
   33918             :   #endif
   33919             :   __pyx_array_getbuffer, /*bf_getbuffer*/
   33920             :   0, /*bf_releasebuffer*/
   33921             : };
   33922             : #endif
   33923             : static PyType_Slot __pyx_type___pyx_array_slots[] = {
   33924             :   {Py_tp_dealloc, (void *)__pyx_tp_dealloc_array},
   33925             :   {Py_sq_length, (void *)__pyx_array___len__},
   33926             :   {Py_sq_item, (void *)__pyx_sq_item_array},
   33927             :   {Py_mp_length, (void *)__pyx_array___len__},
   33928             :   {Py_mp_subscript, (void *)__pyx_array___getitem__},
   33929             :   {Py_mp_ass_subscript, (void *)__pyx_mp_ass_subscript_array},
   33930             :   {Py_tp_getattro, (void *)__pyx_tp_getattro_array},
   33931             :   #if defined(Py_bf_getbuffer)
   33932             :   {Py_bf_getbuffer, (void *)__pyx_array_getbuffer},
   33933             :   #endif
   33934             :   {Py_tp_methods, (void *)__pyx_methods_array},
   33935             :   {Py_tp_getset, (void *)__pyx_getsets_array},
   33936             :   {Py_tp_new, (void *)__pyx_tp_new_array},
   33937             :   {0, 0},
   33938             : };
   33939             : static PyType_Spec __pyx_type___pyx_array_spec = {
   33940             :   "_ni_label.array",
   33941             :   sizeof(struct __pyx_array_obj),
   33942             :   0,
   33943             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_SEQUENCE,
   33944             :   __pyx_type___pyx_array_slots,
   33945             : };
   33946             : #else
   33947             : 
   33948             : static PySequenceMethods __pyx_tp_as_sequence_array = {
   33949             :   __pyx_array___len__, /*sq_length*/
   33950             :   0, /*sq_concat*/
   33951             :   0, /*sq_repeat*/
   33952             :   __pyx_sq_item_array, /*sq_item*/
   33953             :   0, /*sq_slice*/
   33954             :   0, /*sq_ass_item*/
   33955             :   0, /*sq_ass_slice*/
   33956             :   0, /*sq_contains*/
   33957             :   0, /*sq_inplace_concat*/
   33958             :   0, /*sq_inplace_repeat*/
   33959             : };
   33960             : 
   33961             : static PyMappingMethods __pyx_tp_as_mapping_array = {
   33962             :   __pyx_array___len__, /*mp_length*/
   33963             :   __pyx_array___getitem__, /*mp_subscript*/
   33964             :   __pyx_mp_ass_subscript_array, /*mp_ass_subscript*/
   33965             : };
   33966             : 
   33967             : static PyBufferProcs __pyx_tp_as_buffer_array = {
   33968             :   #if PY_MAJOR_VERSION < 3
   33969             :   0, /*bf_getreadbuffer*/
   33970             :   #endif
   33971             :   #if PY_MAJOR_VERSION < 3
   33972             :   0, /*bf_getwritebuffer*/
   33973             :   #endif
   33974             :   #if PY_MAJOR_VERSION < 3
   33975             :   0, /*bf_getsegcount*/
   33976             :   #endif
   33977             :   #if PY_MAJOR_VERSION < 3
   33978             :   0, /*bf_getcharbuffer*/
   33979             :   #endif
   33980             :   __pyx_array_getbuffer, /*bf_getbuffer*/
   33981             :   0, /*bf_releasebuffer*/
   33982             : };
   33983             : 
   33984             : static PyTypeObject __pyx_type___pyx_array = {
   33985             :   PyVarObject_HEAD_INIT(0, 0)
   33986             :   "_ni_label.""array", /*tp_name*/
   33987             :   sizeof(struct __pyx_array_obj), /*tp_basicsize*/
   33988             :   0, /*tp_itemsize*/
   33989             :   __pyx_tp_dealloc_array, /*tp_dealloc*/
   33990             :   #if PY_VERSION_HEX < 0x030800b4
   33991             :   0, /*tp_print*/
   33992             :   #endif
   33993             :   #if PY_VERSION_HEX >= 0x030800b4
   33994             :   0, /*tp_vectorcall_offset*/
   33995             :   #endif
   33996             :   0, /*tp_getattr*/
   33997             :   0, /*tp_setattr*/
   33998             :   #if PY_MAJOR_VERSION < 3
   33999             :   0, /*tp_compare*/
   34000             :   #endif
   34001             :   #if PY_MAJOR_VERSION >= 3
   34002             :   0, /*tp_as_async*/
   34003             :   #endif
   34004             :   0, /*tp_repr*/
   34005             :   0, /*tp_as_number*/
   34006             :   &__pyx_tp_as_sequence_array, /*tp_as_sequence*/
   34007             :   &__pyx_tp_as_mapping_array, /*tp_as_mapping*/
   34008             :   0, /*tp_hash*/
   34009             :   0, /*tp_call*/
   34010             :   0, /*tp_str*/
   34011             :   __pyx_tp_getattro_array, /*tp_getattro*/
   34012             :   0, /*tp_setattro*/
   34013             :   &__pyx_tp_as_buffer_array, /*tp_as_buffer*/
   34014             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_SEQUENCE, /*tp_flags*/
   34015             :   0, /*tp_doc*/
   34016             :   0, /*tp_traverse*/
   34017             :   0, /*tp_clear*/
   34018             :   0, /*tp_richcompare*/
   34019             :   0, /*tp_weaklistoffset*/
   34020             :   0, /*tp_iter*/
   34021             :   0, /*tp_iternext*/
   34022             :   __pyx_methods_array, /*tp_methods*/
   34023             :   0, /*tp_members*/
   34024             :   __pyx_getsets_array, /*tp_getset*/
   34025             :   0, /*tp_base*/
   34026             :   0, /*tp_dict*/
   34027             :   0, /*tp_descr_get*/
   34028             :   0, /*tp_descr_set*/
   34029             :   #if !CYTHON_USE_TYPE_SPECS
   34030             :   0, /*tp_dictoffset*/
   34031             :   #endif
   34032             :   0, /*tp_init*/
   34033             :   0, /*tp_alloc*/
   34034             :   __pyx_tp_new_array, /*tp_new*/
   34035             :   0, /*tp_free*/
   34036             :   0, /*tp_is_gc*/
   34037             :   0, /*tp_bases*/
   34038             :   0, /*tp_mro*/
   34039             :   0, /*tp_cache*/
   34040             :   0, /*tp_subclasses*/
   34041             :   0, /*tp_weaklist*/
   34042             :   0, /*tp_del*/
   34043             :   0, /*tp_version_tag*/
   34044             :   #if PY_VERSION_HEX >= 0x030400a1
   34045             :   #if CYTHON_USE_TP_FINALIZE
   34046             :   0, /*tp_finalize*/
   34047             :   #else
   34048             :   NULL, /*tp_finalize*/
   34049             :   #endif
   34050             :   #endif
   34051             :   #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   34052             :   0, /*tp_vectorcall*/
   34053             :   #endif
   34054             :   #if __PYX_NEED_TP_PRINT_SLOT == 1
   34055             :   0, /*tp_print*/
   34056             :   #endif
   34057             :   #if PY_VERSION_HEX >= 0x030C0000
   34058             :   0, /*tp_watched*/
   34059             :   #endif
   34060             :   #if PY_VERSION_HEX >= 0x030d00A4
   34061             :   0, /*tp_versions_used*/
   34062             :   #endif
   34063             :   #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   34064             :   0, /*tp_pypy_flags*/
   34065             :   #endif
   34066             : };
   34067             : #endif
   34068             : 
   34069          15 : static PyObject *__pyx_tp_new_Enum(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
   34070          15 :   struct __pyx_MemviewEnum_obj *p;
   34071          15 :   PyObject *o;
   34072             :   #if CYTHON_COMPILING_IN_LIMITED_API
   34073             :   allocfunc alloc_func = (allocfunc)PyType_GetSlot(t, Py_tp_alloc);
   34074             :   o = alloc_func(t, 0);
   34075             :   #else
   34076          15 :   if (likely(!__Pyx_PyType_HasFeature(t, Py_TPFLAGS_IS_ABSTRACT))) {
   34077          15 :     o = (*t->tp_alloc)(t, 0);
   34078             :   } else {
   34079           0 :     o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
   34080             :   }
   34081          15 :   if (unlikely(!o)) return 0;
   34082             :   #endif
   34083          15 :   p = ((struct __pyx_MemviewEnum_obj *)o);
   34084          15 :   p->name = Py_None; Py_INCREF(Py_None);
   34085             :   return o;
   34086             : }
   34087             : 
   34088           0 : static void __pyx_tp_dealloc_Enum(PyObject *o) {
   34089           0 :   struct __pyx_MemviewEnum_obj *p = (struct __pyx_MemviewEnum_obj *)o;
   34090             :   #if CYTHON_USE_TP_FINALIZE
   34091           0 :   if (unlikely((PY_VERSION_HEX >= 0x03080000 || __Pyx_PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE)) && __Pyx_PyObject_GetSlot(o, tp_finalize, destructor)) && !__Pyx_PyObject_GC_IsFinalized(o)) {
   34092           0 :     if (__Pyx_PyObject_GetSlot(o, tp_dealloc, destructor) == __pyx_tp_dealloc_Enum) {
   34093           0 :       if (PyObject_CallFinalizerFromDealloc(o)) return;
   34094             :     }
   34095             :   }
   34096             :   #endif
   34097           0 :   PyObject_GC_UnTrack(o);
   34098           0 :   Py_CLEAR(p->name);
   34099             :   #if CYTHON_USE_TYPE_SLOTS || CYTHON_COMPILING_IN_PYPY
   34100           0 :   (*Py_TYPE(o)->tp_free)(o);
   34101             :   #else
   34102             :   {
   34103             :     freefunc tp_free = (freefunc)PyType_GetSlot(Py_TYPE(o), Py_tp_free);
   34104             :     if (tp_free) tp_free(o);
   34105             :   }
   34106             :   #endif
   34107             : }
   34108             : 
   34109         685 : static int __pyx_tp_traverse_Enum(PyObject *o, visitproc v, void *a) {
   34110         685 :   int e;
   34111         685 :   struct __pyx_MemviewEnum_obj *p = (struct __pyx_MemviewEnum_obj *)o;
   34112         685 :   if (p->name) {
   34113         685 :     e = (*v)(p->name, a); if (e) return e;
   34114             :   }
   34115             :   return 0;
   34116             : }
   34117             : 
   34118           0 : static int __pyx_tp_clear_Enum(PyObject *o) {
   34119           0 :   PyObject* tmp;
   34120           0 :   struct __pyx_MemviewEnum_obj *p = (struct __pyx_MemviewEnum_obj *)o;
   34121           0 :   tmp = ((PyObject*)p->name);
   34122           0 :   p->name = Py_None; Py_INCREF(Py_None);
   34123           0 :   Py_XDECREF(tmp);
   34124           0 :   return 0;
   34125             : }
   34126             : 
   34127           0 : static PyObject *__pyx_specialmethod___pyx_MemviewEnum___repr__(PyObject *self, CYTHON_UNUSED PyObject *arg) {
   34128           0 :   return __pyx_MemviewEnum___repr__(self);
   34129             : }
   34130             : 
   34131             : static PyMethodDef __pyx_methods_Enum[] = {
   34132             :   {"__repr__", (PyCFunction)__pyx_specialmethod___pyx_MemviewEnum___repr__, METH_NOARGS|METH_COEXIST, 0},
   34133             :   {"__reduce_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_MemviewEnum_1__reduce_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34134             :   {"__setstate_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_MemviewEnum_3__setstate_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34135             :   {0, 0, 0, 0}
   34136             : };
   34137             : #if CYTHON_USE_TYPE_SPECS
   34138             : static PyType_Slot __pyx_type___pyx_MemviewEnum_slots[] = {
   34139             :   {Py_tp_dealloc, (void *)__pyx_tp_dealloc_Enum},
   34140             :   {Py_tp_repr, (void *)__pyx_MemviewEnum___repr__},
   34141             :   {Py_tp_traverse, (void *)__pyx_tp_traverse_Enum},
   34142             :   {Py_tp_clear, (void *)__pyx_tp_clear_Enum},
   34143             :   {Py_tp_methods, (void *)__pyx_methods_Enum},
   34144             :   {Py_tp_init, (void *)__pyx_MemviewEnum___init__},
   34145             :   {Py_tp_new, (void *)__pyx_tp_new_Enum},
   34146             :   {0, 0},
   34147             : };
   34148             : static PyType_Spec __pyx_type___pyx_MemviewEnum_spec = {
   34149             :   "_ni_label.Enum",
   34150             :   sizeof(struct __pyx_MemviewEnum_obj),
   34151             :   0,
   34152             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
   34153             :   __pyx_type___pyx_MemviewEnum_slots,
   34154             : };
   34155             : #else
   34156             : 
   34157             : static PyTypeObject __pyx_type___pyx_MemviewEnum = {
   34158             :   PyVarObject_HEAD_INIT(0, 0)
   34159             :   "_ni_label.""Enum", /*tp_name*/
   34160             :   sizeof(struct __pyx_MemviewEnum_obj), /*tp_basicsize*/
   34161             :   0, /*tp_itemsize*/
   34162             :   __pyx_tp_dealloc_Enum, /*tp_dealloc*/
   34163             :   #if PY_VERSION_HEX < 0x030800b4
   34164             :   0, /*tp_print*/
   34165             :   #endif
   34166             :   #if PY_VERSION_HEX >= 0x030800b4
   34167             :   0, /*tp_vectorcall_offset*/
   34168             :   #endif
   34169             :   0, /*tp_getattr*/
   34170             :   0, /*tp_setattr*/
   34171             :   #if PY_MAJOR_VERSION < 3
   34172             :   0, /*tp_compare*/
   34173             :   #endif
   34174             :   #if PY_MAJOR_VERSION >= 3
   34175             :   0, /*tp_as_async*/
   34176             :   #endif
   34177             :   __pyx_MemviewEnum___repr__, /*tp_repr*/
   34178             :   0, /*tp_as_number*/
   34179             :   0, /*tp_as_sequence*/
   34180             :   0, /*tp_as_mapping*/
   34181             :   0, /*tp_hash*/
   34182             :   0, /*tp_call*/
   34183             :   0, /*tp_str*/
   34184             :   0, /*tp_getattro*/
   34185             :   0, /*tp_setattro*/
   34186             :   0, /*tp_as_buffer*/
   34187             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
   34188             :   0, /*tp_doc*/
   34189             :   __pyx_tp_traverse_Enum, /*tp_traverse*/
   34190             :   __pyx_tp_clear_Enum, /*tp_clear*/
   34191             :   0, /*tp_richcompare*/
   34192             :   0, /*tp_weaklistoffset*/
   34193             :   0, /*tp_iter*/
   34194             :   0, /*tp_iternext*/
   34195             :   __pyx_methods_Enum, /*tp_methods*/
   34196             :   0, /*tp_members*/
   34197             :   0, /*tp_getset*/
   34198             :   0, /*tp_base*/
   34199             :   0, /*tp_dict*/
   34200             :   0, /*tp_descr_get*/
   34201             :   0, /*tp_descr_set*/
   34202             :   #if !CYTHON_USE_TYPE_SPECS
   34203             :   0, /*tp_dictoffset*/
   34204             :   #endif
   34205             :   __pyx_MemviewEnum___init__, /*tp_init*/
   34206             :   0, /*tp_alloc*/
   34207             :   __pyx_tp_new_Enum, /*tp_new*/
   34208             :   0, /*tp_free*/
   34209             :   0, /*tp_is_gc*/
   34210             :   0, /*tp_bases*/
   34211             :   0, /*tp_mro*/
   34212             :   0, /*tp_cache*/
   34213             :   0, /*tp_subclasses*/
   34214             :   0, /*tp_weaklist*/
   34215             :   0, /*tp_del*/
   34216             :   0, /*tp_version_tag*/
   34217             :   #if PY_VERSION_HEX >= 0x030400a1
   34218             :   #if CYTHON_USE_TP_FINALIZE
   34219             :   0, /*tp_finalize*/
   34220             :   #else
   34221             :   NULL, /*tp_finalize*/
   34222             :   #endif
   34223             :   #endif
   34224             :   #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   34225             :   0, /*tp_vectorcall*/
   34226             :   #endif
   34227             :   #if __PYX_NEED_TP_PRINT_SLOT == 1
   34228             :   0, /*tp_print*/
   34229             :   #endif
   34230             :   #if PY_VERSION_HEX >= 0x030C0000
   34231             :   0, /*tp_watched*/
   34232             :   #endif
   34233             :   #if PY_VERSION_HEX >= 0x030d00A4
   34234             :   0, /*tp_versions_used*/
   34235             :   #endif
   34236             :   #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   34237             :   0, /*tp_pypy_flags*/
   34238             :   #endif
   34239             : };
   34240             : #endif
   34241             : static struct __pyx_vtabstruct_memoryview __pyx_vtable_memoryview;
   34242             : 
   34243           0 : static PyObject *__pyx_tp_new_memoryview(PyTypeObject *t, PyObject *a, PyObject *k) {
   34244           0 :   struct __pyx_memoryview_obj *p;
   34245           0 :   PyObject *o;
   34246             :   #if CYTHON_COMPILING_IN_LIMITED_API
   34247             :   allocfunc alloc_func = (allocfunc)PyType_GetSlot(t, Py_tp_alloc);
   34248             :   o = alloc_func(t, 0);
   34249             :   #else
   34250           0 :   if (likely(!__Pyx_PyType_HasFeature(t, Py_TPFLAGS_IS_ABSTRACT))) {
   34251           0 :     o = (*t->tp_alloc)(t, 0);
   34252             :   } else {
   34253           0 :     o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
   34254             :   }
   34255           0 :   if (unlikely(!o)) return 0;
   34256             :   #endif
   34257           0 :   p = ((struct __pyx_memoryview_obj *)o);
   34258           0 :   p->__pyx_vtab = __pyx_vtabptr_memoryview;
   34259           0 :   p->obj = Py_None; Py_INCREF(Py_None);
   34260           0 :   p->_size = Py_None; Py_INCREF(Py_None);
   34261           0 :   p->_array_interface = Py_None; Py_INCREF(Py_None);
   34262           0 :   p->view.obj = NULL;
   34263           0 :   if (unlikely(__pyx_memoryview___cinit__(o, a, k) < 0)) goto bad;
   34264             :   return o;
   34265           0 :   bad:
   34266           0 :   Py_DECREF(o); o = 0;
   34267             :   return NULL;
   34268             : }
   34269             : 
   34270           0 : static void __pyx_tp_dealloc_memoryview(PyObject *o) {
   34271           0 :   struct __pyx_memoryview_obj *p = (struct __pyx_memoryview_obj *)o;
   34272             :   #if CYTHON_USE_TP_FINALIZE
   34273           0 :   if (unlikely((PY_VERSION_HEX >= 0x03080000 || __Pyx_PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE)) && __Pyx_PyObject_GetSlot(o, tp_finalize, destructor)) && !__Pyx_PyObject_GC_IsFinalized(o)) {
   34274           0 :     if (__Pyx_PyObject_GetSlot(o, tp_dealloc, destructor) == __pyx_tp_dealloc_memoryview) {
   34275           0 :       if (PyObject_CallFinalizerFromDealloc(o)) return;
   34276             :     }
   34277             :   }
   34278             :   #endif
   34279           0 :   PyObject_GC_UnTrack(o);
   34280             :   {
   34281           0 :     PyObject *etype, *eval, *etb;
   34282           0 :     PyErr_Fetch(&etype, &eval, &etb);
   34283           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
   34284           0 :     __pyx_memoryview___dealloc__(o);
   34285           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
   34286           0 :     PyErr_Restore(etype, eval, etb);
   34287             :   }
   34288           0 :   Py_CLEAR(p->obj);
   34289           0 :   Py_CLEAR(p->_size);
   34290           0 :   Py_CLEAR(p->_array_interface);
   34291             :   #if CYTHON_USE_TYPE_SLOTS || CYTHON_COMPILING_IN_PYPY
   34292           0 :   (*Py_TYPE(o)->tp_free)(o);
   34293             :   #else
   34294             :   {
   34295             :     freefunc tp_free = (freefunc)PyType_GetSlot(Py_TYPE(o), Py_tp_free);
   34296             :     if (tp_free) tp_free(o);
   34297             :   }
   34298             :   #endif
   34299             : }
   34300             : 
   34301           0 : static int __pyx_tp_traverse_memoryview(PyObject *o, visitproc v, void *a) {
   34302           0 :   int e;
   34303           0 :   struct __pyx_memoryview_obj *p = (struct __pyx_memoryview_obj *)o;
   34304           0 :   if (p->obj) {
   34305           0 :     e = (*v)(p->obj, a); if (e) return e;
   34306             :   }
   34307           0 :   if (p->_size) {
   34308           0 :     e = (*v)(p->_size, a); if (e) return e;
   34309             :   }
   34310           0 :   if (p->_array_interface) {
   34311           0 :     e = (*v)(p->_array_interface, a); if (e) return e;
   34312             :   }
   34313           0 :   if (p->view.obj) {
   34314           0 :     e = (*v)(p->view.obj, a); if (e) return e;
   34315             :   }
   34316             :   return 0;
   34317             : }
   34318             : 
   34319           0 : static int __pyx_tp_clear_memoryview(PyObject *o) {
   34320           0 :   PyObject* tmp;
   34321           0 :   struct __pyx_memoryview_obj *p = (struct __pyx_memoryview_obj *)o;
   34322           0 :   tmp = ((PyObject*)p->obj);
   34323           0 :   p->obj = Py_None; Py_INCREF(Py_None);
   34324           0 :   Py_XDECREF(tmp);
   34325           0 :   tmp = ((PyObject*)p->_size);
   34326           0 :   p->_size = Py_None; Py_INCREF(Py_None);
   34327           0 :   Py_XDECREF(tmp);
   34328           0 :   tmp = ((PyObject*)p->_array_interface);
   34329           0 :   p->_array_interface = Py_None; Py_INCREF(Py_None);
   34330           0 :   Py_XDECREF(tmp);
   34331           0 :   Py_CLEAR(p->view.obj);
   34332           0 :   return 0;
   34333             : }
   34334           0 : static PyObject *__pyx_sq_item_memoryview(PyObject *o, Py_ssize_t i) {
   34335           0 :   PyObject *r;
   34336           0 :   PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
   34337           0 :   r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
   34338           0 :   Py_DECREF(x);
   34339             :   return r;
   34340             : }
   34341             : 
   34342           0 : static int __pyx_mp_ass_subscript_memoryview(PyObject *o, PyObject *i, PyObject *v) {
   34343           0 :   if (v) {
   34344           0 :     return __pyx_memoryview___setitem__(o, i, v);
   34345             :   }
   34346             :   else {
   34347           0 :     __Pyx_TypeName o_type_name;
   34348           0 :     o_type_name = __Pyx_PyType_GetName(Py_TYPE(o));
   34349           0 :     PyErr_Format(PyExc_NotImplementedError,
   34350             :       "Subscript deletion not supported by " __Pyx_FMT_TYPENAME, o_type_name);
   34351           0 :     __Pyx_DECREF_TypeName(o_type_name);
   34352           0 :     return -1;
   34353             :   }
   34354             : }
   34355             : 
   34356           0 : static PyObject *__pyx_getprop___pyx_memoryview_T(PyObject *o, CYTHON_UNUSED void *x) {
   34357           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(o);
   34358             : }
   34359             : 
   34360           0 : static PyObject *__pyx_getprop___pyx_memoryview_base(PyObject *o, CYTHON_UNUSED void *x) {
   34361           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(o);
   34362             : }
   34363             : 
   34364           0 : static PyObject *__pyx_getprop___pyx_memoryview_shape(PyObject *o, CYTHON_UNUSED void *x) {
   34365           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(o);
   34366             : }
   34367             : 
   34368           0 : static PyObject *__pyx_getprop___pyx_memoryview_strides(PyObject *o, CYTHON_UNUSED void *x) {
   34369           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(o);
   34370             : }
   34371             : 
   34372           0 : static PyObject *__pyx_getprop___pyx_memoryview_suboffsets(PyObject *o, CYTHON_UNUSED void *x) {
   34373           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(o);
   34374             : }
   34375             : 
   34376           0 : static PyObject *__pyx_getprop___pyx_memoryview_ndim(PyObject *o, CYTHON_UNUSED void *x) {
   34377           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(o);
   34378             : }
   34379             : 
   34380           0 : static PyObject *__pyx_getprop___pyx_memoryview_itemsize(PyObject *o, CYTHON_UNUSED void *x) {
   34381           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(o);
   34382             : }
   34383             : 
   34384           0 : static PyObject *__pyx_getprop___pyx_memoryview_nbytes(PyObject *o, CYTHON_UNUSED void *x) {
   34385           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(o);
   34386             : }
   34387             : 
   34388           0 : static PyObject *__pyx_getprop___pyx_memoryview_size(PyObject *o, CYTHON_UNUSED void *x) {
   34389           0 :   return __pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(o);
   34390             : }
   34391             : 
   34392           0 : static PyObject *__pyx_specialmethod___pyx_memoryview___repr__(PyObject *self, CYTHON_UNUSED PyObject *arg) {
   34393           0 :   return __pyx_memoryview___repr__(self);
   34394             : }
   34395             : 
   34396             : static PyMethodDef __pyx_methods_memoryview[] = {
   34397             :   {"__repr__", (PyCFunction)__pyx_specialmethod___pyx_memoryview___repr__, METH_NOARGS|METH_COEXIST, 0},
   34398             :   {"is_c_contig", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_memoryview_is_c_contig, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34399             :   {"is_f_contig", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_memoryview_is_f_contig, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34400             :   {"copy", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_memoryview_copy, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34401             :   {"copy_fortran", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_memoryview_copy_fortran, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34402             :   {"__reduce_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_memoryview_1__reduce_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34403             :   {"__setstate_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_memoryview_3__setstate_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34404             :   {0, 0, 0, 0}
   34405             : };
   34406             : 
   34407             : static struct PyGetSetDef __pyx_getsets_memoryview[] = {
   34408             :   {(char *)"T", __pyx_getprop___pyx_memoryview_T, 0, (char *)0, 0},
   34409             :   {(char *)"base", __pyx_getprop___pyx_memoryview_base, 0, (char *)0, 0},
   34410             :   {(char *)"shape", __pyx_getprop___pyx_memoryview_shape, 0, (char *)0, 0},
   34411             :   {(char *)"strides", __pyx_getprop___pyx_memoryview_strides, 0, (char *)0, 0},
   34412             :   {(char *)"suboffsets", __pyx_getprop___pyx_memoryview_suboffsets, 0, (char *)0, 0},
   34413             :   {(char *)"ndim", __pyx_getprop___pyx_memoryview_ndim, 0, (char *)0, 0},
   34414             :   {(char *)"itemsize", __pyx_getprop___pyx_memoryview_itemsize, 0, (char *)0, 0},
   34415             :   {(char *)"nbytes", __pyx_getprop___pyx_memoryview_nbytes, 0, (char *)0, 0},
   34416             :   {(char *)"size", __pyx_getprop___pyx_memoryview_size, 0, (char *)0, 0},
   34417             :   {0, 0, 0, 0, 0}
   34418             : };
   34419             : #if CYTHON_USE_TYPE_SPECS
   34420             : #if !CYTHON_COMPILING_IN_LIMITED_API
   34421             : 
   34422             : static PyBufferProcs __pyx_tp_as_buffer_memoryview = {
   34423             :   #if PY_MAJOR_VERSION < 3
   34424             :   0, /*bf_getreadbuffer*/
   34425             :   #endif
   34426             :   #if PY_MAJOR_VERSION < 3
   34427             :   0, /*bf_getwritebuffer*/
   34428             :   #endif
   34429             :   #if PY_MAJOR_VERSION < 3
   34430             :   0, /*bf_getsegcount*/
   34431             :   #endif
   34432             :   #if PY_MAJOR_VERSION < 3
   34433             :   0, /*bf_getcharbuffer*/
   34434             :   #endif
   34435             :   __pyx_memoryview_getbuffer, /*bf_getbuffer*/
   34436             :   0, /*bf_releasebuffer*/
   34437             : };
   34438             : #endif
   34439             : static PyType_Slot __pyx_type___pyx_memoryview_slots[] = {
   34440             :   {Py_tp_dealloc, (void *)__pyx_tp_dealloc_memoryview},
   34441             :   {Py_tp_repr, (void *)__pyx_memoryview___repr__},
   34442             :   {Py_sq_length, (void *)__pyx_memoryview___len__},
   34443             :   {Py_sq_item, (void *)__pyx_sq_item_memoryview},
   34444             :   {Py_mp_length, (void *)__pyx_memoryview___len__},
   34445             :   {Py_mp_subscript, (void *)__pyx_memoryview___getitem__},
   34446             :   {Py_mp_ass_subscript, (void *)__pyx_mp_ass_subscript_memoryview},
   34447             :   {Py_tp_str, (void *)__pyx_memoryview___str__},
   34448             :   #if defined(Py_bf_getbuffer)
   34449             :   {Py_bf_getbuffer, (void *)__pyx_memoryview_getbuffer},
   34450             :   #endif
   34451             :   {Py_tp_traverse, (void *)__pyx_tp_traverse_memoryview},
   34452             :   {Py_tp_clear, (void *)__pyx_tp_clear_memoryview},
   34453             :   {Py_tp_methods, (void *)__pyx_methods_memoryview},
   34454             :   {Py_tp_getset, (void *)__pyx_getsets_memoryview},
   34455             :   {Py_tp_new, (void *)__pyx_tp_new_memoryview},
   34456             :   {0, 0},
   34457             : };
   34458             : static PyType_Spec __pyx_type___pyx_memoryview_spec = {
   34459             :   "_ni_label.memoryview",
   34460             :   sizeof(struct __pyx_memoryview_obj),
   34461             :   0,
   34462             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
   34463             :   __pyx_type___pyx_memoryview_slots,
   34464             : };
   34465             : #else
   34466             : 
   34467             : static PySequenceMethods __pyx_tp_as_sequence_memoryview = {
   34468             :   __pyx_memoryview___len__, /*sq_length*/
   34469             :   0, /*sq_concat*/
   34470             :   0, /*sq_repeat*/
   34471             :   __pyx_sq_item_memoryview, /*sq_item*/
   34472             :   0, /*sq_slice*/
   34473             :   0, /*sq_ass_item*/
   34474             :   0, /*sq_ass_slice*/
   34475             :   0, /*sq_contains*/
   34476             :   0, /*sq_inplace_concat*/
   34477             :   0, /*sq_inplace_repeat*/
   34478             : };
   34479             : 
   34480             : static PyMappingMethods __pyx_tp_as_mapping_memoryview = {
   34481             :   __pyx_memoryview___len__, /*mp_length*/
   34482             :   __pyx_memoryview___getitem__, /*mp_subscript*/
   34483             :   __pyx_mp_ass_subscript_memoryview, /*mp_ass_subscript*/
   34484             : };
   34485             : 
   34486             : static PyBufferProcs __pyx_tp_as_buffer_memoryview = {
   34487             :   #if PY_MAJOR_VERSION < 3
   34488             :   0, /*bf_getreadbuffer*/
   34489             :   #endif
   34490             :   #if PY_MAJOR_VERSION < 3
   34491             :   0, /*bf_getwritebuffer*/
   34492             :   #endif
   34493             :   #if PY_MAJOR_VERSION < 3
   34494             :   0, /*bf_getsegcount*/
   34495             :   #endif
   34496             :   #if PY_MAJOR_VERSION < 3
   34497             :   0, /*bf_getcharbuffer*/
   34498             :   #endif
   34499             :   __pyx_memoryview_getbuffer, /*bf_getbuffer*/
   34500             :   0, /*bf_releasebuffer*/
   34501             : };
   34502             : 
   34503             : static PyTypeObject __pyx_type___pyx_memoryview = {
   34504             :   PyVarObject_HEAD_INIT(0, 0)
   34505             :   "_ni_label.""memoryview", /*tp_name*/
   34506             :   sizeof(struct __pyx_memoryview_obj), /*tp_basicsize*/
   34507             :   0, /*tp_itemsize*/
   34508             :   __pyx_tp_dealloc_memoryview, /*tp_dealloc*/
   34509             :   #if PY_VERSION_HEX < 0x030800b4
   34510             :   0, /*tp_print*/
   34511             :   #endif
   34512             :   #if PY_VERSION_HEX >= 0x030800b4
   34513             :   0, /*tp_vectorcall_offset*/
   34514             :   #endif
   34515             :   0, /*tp_getattr*/
   34516             :   0, /*tp_setattr*/
   34517             :   #if PY_MAJOR_VERSION < 3
   34518             :   0, /*tp_compare*/
   34519             :   #endif
   34520             :   #if PY_MAJOR_VERSION >= 3
   34521             :   0, /*tp_as_async*/
   34522             :   #endif
   34523             :   __pyx_memoryview___repr__, /*tp_repr*/
   34524             :   0, /*tp_as_number*/
   34525             :   &__pyx_tp_as_sequence_memoryview, /*tp_as_sequence*/
   34526             :   &__pyx_tp_as_mapping_memoryview, /*tp_as_mapping*/
   34527             :   0, /*tp_hash*/
   34528             :   0, /*tp_call*/
   34529             :   __pyx_memoryview___str__, /*tp_str*/
   34530             :   0, /*tp_getattro*/
   34531             :   0, /*tp_setattro*/
   34532             :   &__pyx_tp_as_buffer_memoryview, /*tp_as_buffer*/
   34533             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
   34534             :   0, /*tp_doc*/
   34535             :   __pyx_tp_traverse_memoryview, /*tp_traverse*/
   34536             :   __pyx_tp_clear_memoryview, /*tp_clear*/
   34537             :   0, /*tp_richcompare*/
   34538             :   0, /*tp_weaklistoffset*/
   34539             :   0, /*tp_iter*/
   34540             :   0, /*tp_iternext*/
   34541             :   __pyx_methods_memoryview, /*tp_methods*/
   34542             :   0, /*tp_members*/
   34543             :   __pyx_getsets_memoryview, /*tp_getset*/
   34544             :   0, /*tp_base*/
   34545             :   0, /*tp_dict*/
   34546             :   0, /*tp_descr_get*/
   34547             :   0, /*tp_descr_set*/
   34548             :   #if !CYTHON_USE_TYPE_SPECS
   34549             :   0, /*tp_dictoffset*/
   34550             :   #endif
   34551             :   0, /*tp_init*/
   34552             :   0, /*tp_alloc*/
   34553             :   __pyx_tp_new_memoryview, /*tp_new*/
   34554             :   0, /*tp_free*/
   34555             :   0, /*tp_is_gc*/
   34556             :   0, /*tp_bases*/
   34557             :   0, /*tp_mro*/
   34558             :   0, /*tp_cache*/
   34559             :   0, /*tp_subclasses*/
   34560             :   0, /*tp_weaklist*/
   34561             :   0, /*tp_del*/
   34562             :   0, /*tp_version_tag*/
   34563             :   #if PY_VERSION_HEX >= 0x030400a1
   34564             :   #if CYTHON_USE_TP_FINALIZE
   34565             :   0, /*tp_finalize*/
   34566             :   #else
   34567             :   NULL, /*tp_finalize*/
   34568             :   #endif
   34569             :   #endif
   34570             :   #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   34571             :   0, /*tp_vectorcall*/
   34572             :   #endif
   34573             :   #if __PYX_NEED_TP_PRINT_SLOT == 1
   34574             :   0, /*tp_print*/
   34575             :   #endif
   34576             :   #if PY_VERSION_HEX >= 0x030C0000
   34577             :   0, /*tp_watched*/
   34578             :   #endif
   34579             :   #if PY_VERSION_HEX >= 0x030d00A4
   34580             :   0, /*tp_versions_used*/
   34581             :   #endif
   34582             :   #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   34583             :   0, /*tp_pypy_flags*/
   34584             :   #endif
   34585             : };
   34586             : #endif
   34587             : static struct __pyx_vtabstruct__memoryviewslice __pyx_vtable__memoryviewslice;
   34588             : 
   34589           0 : static PyObject *__pyx_tp_new__memoryviewslice(PyTypeObject *t, PyObject *a, PyObject *k) {
   34590           0 :   struct __pyx_memoryviewslice_obj *p;
   34591           0 :   PyObject *o = __pyx_tp_new_memoryview(t, a, k);
   34592           0 :   if (unlikely(!o)) return 0;
   34593           0 :   p = ((struct __pyx_memoryviewslice_obj *)o);
   34594           0 :   p->__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_memoryview*)__pyx_vtabptr__memoryviewslice;
   34595           0 :   p->from_object = Py_None; Py_INCREF(Py_None);
   34596           0 :   p->from_slice.memview = NULL;
   34597           0 :   return o;
   34598             : }
   34599             : 
   34600           0 : static void __pyx_tp_dealloc__memoryviewslice(PyObject *o) {
   34601           0 :   struct __pyx_memoryviewslice_obj *p = (struct __pyx_memoryviewslice_obj *)o;
   34602             :   #if CYTHON_USE_TP_FINALIZE
   34603           0 :   if (unlikely((PY_VERSION_HEX >= 0x03080000 || __Pyx_PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE)) && __Pyx_PyObject_GetSlot(o, tp_finalize, destructor)) && !__Pyx_PyObject_GC_IsFinalized(o)) {
   34604           0 :     if (__Pyx_PyObject_GetSlot(o, tp_dealloc, destructor) == __pyx_tp_dealloc__memoryviewslice) {
   34605           0 :       if (PyObject_CallFinalizerFromDealloc(o)) return;
   34606             :     }
   34607             :   }
   34608             :   #endif
   34609           0 :   PyObject_GC_UnTrack(o);
   34610             :   {
   34611           0 :     PyObject *etype, *eval, *etb;
   34612           0 :     PyErr_Fetch(&etype, &eval, &etb);
   34613           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
   34614           0 :     __pyx_memoryviewslice___dealloc__(o);
   34615           0 :     __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
   34616           0 :     PyErr_Restore(etype, eval, etb);
   34617             :   }
   34618           0 :   Py_CLEAR(p->from_object);
   34619           0 :   PyObject_GC_Track(o);
   34620           0 :   __pyx_tp_dealloc_memoryview(o);
   34621             : }
   34622             : 
   34623           0 : static int __pyx_tp_traverse__memoryviewslice(PyObject *o, visitproc v, void *a) {
   34624           0 :   int e;
   34625           0 :   struct __pyx_memoryviewslice_obj *p = (struct __pyx_memoryviewslice_obj *)o;
   34626           0 :   e = __pyx_tp_traverse_memoryview(o, v, a); if (e) return e;
   34627           0 :   if (p->from_object) {
   34628           0 :     e = (*v)(p->from_object, a); if (e) return e;
   34629             :   }
   34630             :   return 0;
   34631             : }
   34632             : 
   34633           0 : static int __pyx_tp_clear__memoryviewslice(PyObject *o) {
   34634           0 :   PyObject* tmp;
   34635           0 :   struct __pyx_memoryviewslice_obj *p = (struct __pyx_memoryviewslice_obj *)o;
   34636           0 :   __pyx_tp_clear_memoryview(o);
   34637           0 :   tmp = ((PyObject*)p->from_object);
   34638           0 :   p->from_object = Py_None; Py_INCREF(Py_None);
   34639           0 :   Py_XDECREF(tmp);
   34640           0 :   __PYX_XCLEAR_MEMVIEW(&p->from_slice, 1);
   34641           0 :   return 0;
   34642             : }
   34643             : 
   34644             : static PyMethodDef __pyx_methods__memoryviewslice[] = {
   34645             :   {"__reduce_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_memoryviewslice_1__reduce_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34646             :   {"__setstate_cython__", (PyCFunction)(void*)(__Pyx_PyCFunction_FastCallWithKeywords)__pyx_pw___pyx_memoryviewslice_3__setstate_cython__, __Pyx_METH_FASTCALL|METH_KEYWORDS, 0},
   34647             :   {0, 0, 0, 0}
   34648             : };
   34649             : #if CYTHON_USE_TYPE_SPECS
   34650             : static PyType_Slot __pyx_type___pyx_memoryviewslice_slots[] = {
   34651             :   {Py_tp_dealloc, (void *)__pyx_tp_dealloc__memoryviewslice},
   34652             :   {Py_tp_doc, (void *)PyDoc_STR("Internal class for passing memoryview slices to Python")},
   34653             :   {Py_tp_traverse, (void *)__pyx_tp_traverse__memoryviewslice},
   34654             :   {Py_tp_clear, (void *)__pyx_tp_clear__memoryviewslice},
   34655             :   {Py_tp_methods, (void *)__pyx_methods__memoryviewslice},
   34656             :   {Py_tp_new, (void *)__pyx_tp_new__memoryviewslice},
   34657             :   {0, 0},
   34658             : };
   34659             : static PyType_Spec __pyx_type___pyx_memoryviewslice_spec = {
   34660             :   "_ni_label._memoryviewslice",
   34661             :   sizeof(struct __pyx_memoryviewslice_obj),
   34662             :   0,
   34663             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC|Py_TPFLAGS_SEQUENCE,
   34664             :   __pyx_type___pyx_memoryviewslice_slots,
   34665             : };
   34666             : #else
   34667             : 
   34668             : static PyTypeObject __pyx_type___pyx_memoryviewslice = {
   34669             :   PyVarObject_HEAD_INIT(0, 0)
   34670             :   "_ni_label.""_memoryviewslice", /*tp_name*/
   34671             :   sizeof(struct __pyx_memoryviewslice_obj), /*tp_basicsize*/
   34672             :   0, /*tp_itemsize*/
   34673             :   __pyx_tp_dealloc__memoryviewslice, /*tp_dealloc*/
   34674             :   #if PY_VERSION_HEX < 0x030800b4
   34675             :   0, /*tp_print*/
   34676             :   #endif
   34677             :   #if PY_VERSION_HEX >= 0x030800b4
   34678             :   0, /*tp_vectorcall_offset*/
   34679             :   #endif
   34680             :   0, /*tp_getattr*/
   34681             :   0, /*tp_setattr*/
   34682             :   #if PY_MAJOR_VERSION < 3
   34683             :   0, /*tp_compare*/
   34684             :   #endif
   34685             :   #if PY_MAJOR_VERSION >= 3
   34686             :   0, /*tp_as_async*/
   34687             :   #endif
   34688             :   #if CYTHON_COMPILING_IN_PYPY || 0
   34689             :   __pyx_memoryview___repr__, /*tp_repr*/
   34690             :   #else
   34691             :   0, /*tp_repr*/
   34692             :   #endif
   34693             :   0, /*tp_as_number*/
   34694             :   0, /*tp_as_sequence*/
   34695             :   0, /*tp_as_mapping*/
   34696             :   0, /*tp_hash*/
   34697             :   0, /*tp_call*/
   34698             :   #if CYTHON_COMPILING_IN_PYPY || 0
   34699             :   __pyx_memoryview___str__, /*tp_str*/
   34700             :   #else
   34701             :   0, /*tp_str*/
   34702             :   #endif
   34703             :   0, /*tp_getattro*/
   34704             :   0, /*tp_setattro*/
   34705             :   0, /*tp_as_buffer*/
   34706             :   Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC|Py_TPFLAGS_SEQUENCE, /*tp_flags*/
   34707             :   PyDoc_STR("Internal class for passing memoryview slices to Python"), /*tp_doc*/
   34708             :   __pyx_tp_traverse__memoryviewslice, /*tp_traverse*/
   34709             :   __pyx_tp_clear__memoryviewslice, /*tp_clear*/
   34710             :   0, /*tp_richcompare*/
   34711             :   0, /*tp_weaklistoffset*/
   34712             :   0, /*tp_iter*/
   34713             :   0, /*tp_iternext*/
   34714             :   __pyx_methods__memoryviewslice, /*tp_methods*/
   34715             :   0, /*tp_members*/
   34716             :   0, /*tp_getset*/
   34717             :   0, /*tp_base*/
   34718             :   0, /*tp_dict*/
   34719             :   0, /*tp_descr_get*/
   34720             :   0, /*tp_descr_set*/
   34721             :   #if !CYTHON_USE_TYPE_SPECS
   34722             :   0, /*tp_dictoffset*/
   34723             :   #endif
   34724             :   0, /*tp_init*/
   34725             :   0, /*tp_alloc*/
   34726             :   __pyx_tp_new__memoryviewslice, /*tp_new*/
   34727             :   0, /*tp_free*/
   34728             :   0, /*tp_is_gc*/
   34729             :   0, /*tp_bases*/
   34730             :   0, /*tp_mro*/
   34731             :   0, /*tp_cache*/
   34732             :   0, /*tp_subclasses*/
   34733             :   0, /*tp_weaklist*/
   34734             :   0, /*tp_del*/
   34735             :   0, /*tp_version_tag*/
   34736             :   #if PY_VERSION_HEX >= 0x030400a1
   34737             :   #if CYTHON_USE_TP_FINALIZE
   34738             :   0, /*tp_finalize*/
   34739             :   #else
   34740             :   NULL, /*tp_finalize*/
   34741             :   #endif
   34742             :   #endif
   34743             :   #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   34744             :   0, /*tp_vectorcall*/
   34745             :   #endif
   34746             :   #if __PYX_NEED_TP_PRINT_SLOT == 1
   34747             :   0, /*tp_print*/
   34748             :   #endif
   34749             :   #if PY_VERSION_HEX >= 0x030C0000
   34750             :   0, /*tp_watched*/
   34751             :   #endif
   34752             :   #if PY_VERSION_HEX >= 0x030d00A4
   34753             :   0, /*tp_versions_used*/
   34754             :   #endif
   34755             :   #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   34756             :   0, /*tp_pypy_flags*/
   34757             :   #endif
   34758             : };
   34759             : #endif
   34760             : 
   34761             : static PyMethodDef __pyx_methods[] = {
   34762             :   {0, 0, 0, 0}
   34763             : };
   34764             : #ifndef CYTHON_SMALL_CODE
   34765             : #if defined(__clang__)
   34766             :     #define CYTHON_SMALL_CODE
   34767             : #elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
   34768             :     #define CYTHON_SMALL_CODE __attribute__((cold))
   34769             : #else
   34770             :     #define CYTHON_SMALL_CODE
   34771             : #endif
   34772             : #endif
   34773             : /* #### Code section: pystring_table ### */
   34774             : 
   34775           3 : static int __Pyx_CreateStringTabAndInitStrings(void) {
   34776           3 :   __Pyx_StringTabEntry __pyx_string_tab[] = {
   34777           3 :     {&__pyx_kp_u_, __pyx_k_, sizeof(__pyx_k_), 0, 1, 0, 0},
   34778           3 :     {&__pyx_n_s_ASCII, __pyx_k_ASCII, sizeof(__pyx_k_ASCII), 0, 0, 1, 1},
   34779           3 :     {&__pyx_kp_s_All_dimensions_preceding_dimensi, __pyx_k_All_dimensions_preceding_dimensi, sizeof(__pyx_k_All_dimensions_preceding_dimensi), 0, 0, 1, 0},
   34780           3 :     {&__pyx_n_s_AssertionError, __pyx_k_AssertionError, sizeof(__pyx_k_AssertionError), 0, 0, 1, 1},
   34781           3 :     {&__pyx_kp_s_Buffer_view_does_not_expose_stri, __pyx_k_Buffer_view_does_not_expose_stri, sizeof(__pyx_k_Buffer_view_does_not_expose_stri), 0, 0, 1, 0},
   34782           3 :     {&__pyx_kp_s_Can_only_create_a_buffer_that_is, __pyx_k_Can_only_create_a_buffer_that_is, sizeof(__pyx_k_Can_only_create_a_buffer_that_is), 0, 0, 1, 0},
   34783           3 :     {&__pyx_kp_s_Cannot_assign_to_read_only_memor, __pyx_k_Cannot_assign_to_read_only_memor, sizeof(__pyx_k_Cannot_assign_to_read_only_memor), 0, 0, 1, 0},
   34784           3 :     {&__pyx_kp_s_Cannot_create_writable_memory_vi, __pyx_k_Cannot_create_writable_memory_vi, sizeof(__pyx_k_Cannot_create_writable_memory_vi), 0, 0, 1, 0},
   34785           3 :     {&__pyx_kp_u_Cannot_index_with_type, __pyx_k_Cannot_index_with_type, sizeof(__pyx_k_Cannot_index_with_type), 0, 1, 0, 0},
   34786           3 :     {&__pyx_kp_u_Cannot_label_scalars_or_empty_ar, __pyx_k_Cannot_label_scalars_or_empty_ar, sizeof(__pyx_k_Cannot_label_scalars_or_empty_ar), 0, 1, 0, 0},
   34787           3 :     {&__pyx_kp_s_Cannot_transpose_memoryview_with, __pyx_k_Cannot_transpose_memoryview_with, sizeof(__pyx_k_Cannot_transpose_memoryview_with), 0, 0, 1, 0},
   34788           3 :     {&__pyx_kp_s_Dimension_d_is_not_direct, __pyx_k_Dimension_d_is_not_direct, sizeof(__pyx_k_Dimension_d_is_not_direct), 0, 0, 1, 0},
   34789           3 :     {&__pyx_n_s_Ellipsis, __pyx_k_Ellipsis, sizeof(__pyx_k_Ellipsis), 0, 0, 1, 1},
   34790           3 :     {&__pyx_kp_s_Empty_shape_tuple_for_cython_arr, __pyx_k_Empty_shape_tuple_for_cython_arr, sizeof(__pyx_k_Empty_shape_tuple_for_cython_arr), 0, 0, 1, 0},
   34791           3 :     {&__pyx_kp_s_Expected_at_least_d_argument_s_g, __pyx_k_Expected_at_least_d_argument_s_g, sizeof(__pyx_k_Expected_at_least_d_argument_s_g), 0, 0, 1, 0},
   34792           3 :     {&__pyx_kp_s_Function_call_with_ambiguous_arg, __pyx_k_Function_call_with_ambiguous_arg, sizeof(__pyx_k_Function_call_with_ambiguous_arg), 0, 0, 1, 0},
   34793           3 :     {&__pyx_n_s_ImportError, __pyx_k_ImportError, sizeof(__pyx_k_ImportError), 0, 0, 1, 1},
   34794           3 :     {&__pyx_kp_s_Incompatible_checksums_0x_x_vs_0, __pyx_k_Incompatible_checksums_0x_x_vs_0, sizeof(__pyx_k_Incompatible_checksums_0x_x_vs_0), 0, 0, 1, 0},
   34795           3 :     {&__pyx_n_s_IndexError, __pyx_k_IndexError, sizeof(__pyx_k_IndexError), 0, 0, 1, 1},
   34796           3 :     {&__pyx_kp_s_Index_out_of_bounds_axis_d, __pyx_k_Index_out_of_bounds_axis_d, sizeof(__pyx_k_Index_out_of_bounds_axis_d), 0, 0, 1, 0},
   34797           3 :     {&__pyx_kp_s_Indirect_dimensions_not_supporte, __pyx_k_Indirect_dimensions_not_supporte, sizeof(__pyx_k_Indirect_dimensions_not_supporte), 0, 0, 1, 0},
   34798           3 :     {&__pyx_kp_u_Invalid_mode_expected_c_or_fortr, __pyx_k_Invalid_mode_expected_c_or_fortr, sizeof(__pyx_k_Invalid_mode_expected_c_or_fortr), 0, 1, 0, 0},
   34799           3 :     {&__pyx_kp_u_Invalid_shape_in_axis, __pyx_k_Invalid_shape_in_axis, sizeof(__pyx_k_Invalid_shape_in_axis), 0, 1, 0, 0},
   34800           3 :     {&__pyx_n_s_MemoryError, __pyx_k_MemoryError, sizeof(__pyx_k_MemoryError), 0, 0, 1, 1},
   34801           3 :     {&__pyx_kp_s_MemoryView_of_r_at_0x_x, __pyx_k_MemoryView_of_r_at_0x_x, sizeof(__pyx_k_MemoryView_of_r_at_0x_x), 0, 0, 1, 0},
   34802           3 :     {&__pyx_kp_s_MemoryView_of_r_object, __pyx_k_MemoryView_of_r_object, sizeof(__pyx_k_MemoryView_of_r_object), 0, 0, 1, 0},
   34803           3 :     {&__pyx_n_s_NeedMoreBits, __pyx_k_NeedMoreBits, sizeof(__pyx_k_NeedMoreBits), 0, 0, 1, 1},
   34804           3 :     {&__pyx_kp_s_No_matching_signature_found, __pyx_k_No_matching_signature_found, sizeof(__pyx_k_No_matching_signature_found), 0, 0, 1, 0},
   34805           3 :     {&__pyx_n_b_O, __pyx_k_O, sizeof(__pyx_k_O), 0, 0, 0, 1},
   34806           3 :     {&__pyx_kp_u_Out_of_bounds_on_buffer_access_a, __pyx_k_Out_of_bounds_on_buffer_access_a, sizeof(__pyx_k_Out_of_bounds_on_buffer_access_a), 0, 1, 0, 0},
   34807           3 :     {&__pyx_n_s_PickleError, __pyx_k_PickleError, sizeof(__pyx_k_PickleError), 0, 0, 1, 1},
   34808           3 :     {&__pyx_n_s_Sequence, __pyx_k_Sequence, sizeof(__pyx_k_Sequence), 0, 0, 1, 1},
   34809           3 :     {&__pyx_kp_u_Shapes_must_match_for_input_and, __pyx_k_Shapes_must_match_for_input_and, sizeof(__pyx_k_Shapes_must_match_for_input_and), 0, 1, 0, 0},
   34810           3 :     {&__pyx_kp_s_Step_may_not_be_zero_axis_d, __pyx_k_Step_may_not_be_zero_axis_d, sizeof(__pyx_k_Step_may_not_be_zero_axis_d), 0, 0, 1, 0},
   34811           3 :     {&__pyx_kp_u_Structuring_element_is_not_symme, __pyx_k_Structuring_element_is_not_symme, sizeof(__pyx_k_Structuring_element_is_not_symme), 0, 1, 0, 0},
   34812           3 :     {&__pyx_kp_u_Structuring_element_must_be_size, __pyx_k_Structuring_element_must_be_size, sizeof(__pyx_k_Structuring_element_must_be_size), 0, 1, 0, 0},
   34813           3 :     {&__pyx_kp_u_Structuring_element_must_have_sa, __pyx_k_Structuring_element_must_have_sa, sizeof(__pyx_k_Structuring_element_must_have_sa), 0, 1, 0, 0},
   34814           3 :     {&__pyx_n_s_TypeError, __pyx_k_TypeError, sizeof(__pyx_k_TypeError), 0, 0, 1, 1},
   34815           3 :     {&__pyx_kp_s_Unable_to_convert_item_to_object, __pyx_k_Unable_to_convert_item_to_object, sizeof(__pyx_k_Unable_to_convert_item_to_object), 0, 0, 1, 0},
   34816           3 :     {&__pyx_n_s_ValueError, __pyx_k_ValueError, sizeof(__pyx_k_ValueError), 0, 0, 1, 1},
   34817           3 :     {&__pyx_n_s_View_MemoryView, __pyx_k_View_MemoryView, sizeof(__pyx_k_View_MemoryView), 0, 0, 1, 1},
   34818           3 :     {&__pyx_kp_s__11, __pyx_k__11, sizeof(__pyx_k__11), 0, 0, 1, 0},
   34819           3 :     {&__pyx_kp_s__12, __pyx_k__12, sizeof(__pyx_k__12), 0, 0, 1, 0},
   34820           3 :     {&__pyx_kp_s__13, __pyx_k__13, sizeof(__pyx_k__13), 0, 0, 1, 0},
   34821           3 :     {&__pyx_kp_u__13, __pyx_k__13, sizeof(__pyx_k__13), 0, 1, 0, 0},
   34822           3 :     {&__pyx_kp_u__2, __pyx_k__2, sizeof(__pyx_k__2), 0, 1, 0, 0},
   34823           3 :     {&__pyx_n_s__3, __pyx_k__3, sizeof(__pyx_k__3), 0, 0, 1, 1},
   34824           3 :     {&__pyx_n_s__34, __pyx_k__34, sizeof(__pyx_k__34), 0, 0, 1, 1},
   34825           3 :     {&__pyx_kp_u__6, __pyx_k__6, sizeof(__pyx_k__6), 0, 1, 0, 0},
   34826           3 :     {&__pyx_kp_u__7, __pyx_k__7, sizeof(__pyx_k__7), 0, 1, 0, 0},
   34827           3 :     {&__pyx_n_s_a, __pyx_k_a, sizeof(__pyx_k_a), 0, 0, 1, 1},
   34828           3 :     {&__pyx_n_s_abc, __pyx_k_abc, sizeof(__pyx_k_abc), 0, 0, 1, 1},
   34829           3 :     {&__pyx_n_s_all, __pyx_k_all, sizeof(__pyx_k_all), 0, 0, 1, 1},
   34830           3 :     {&__pyx_n_s_allocate_buffer, __pyx_k_allocate_buffer, sizeof(__pyx_k_allocate_buffer), 0, 0, 1, 1},
   34831           3 :     {&__pyx_kp_u_and, __pyx_k_and, sizeof(__pyx_k_and), 0, 1, 0, 0},
   34832           3 :     {&__pyx_n_s_args, __pyx_k_args, sizeof(__pyx_k_args), 0, 0, 1, 1},
   34833           3 :     {&__pyx_n_s_asanyarray, __pyx_k_asanyarray, sizeof(__pyx_k_asanyarray), 0, 0, 1, 1},
   34834           3 :     {&__pyx_n_s_asyncio_coroutines, __pyx_k_asyncio_coroutines, sizeof(__pyx_k_asyncio_coroutines), 0, 0, 1, 1},
   34835           3 :     {&__pyx_n_s_base, __pyx_k_base, sizeof(__pyx_k_base), 0, 0, 1, 1},
   34836           3 :     {&__pyx_n_s_bool, __pyx_k_bool, sizeof(__pyx_k_bool), 0, 0, 1, 1},
   34837           3 :     {&__pyx_n_s_c, __pyx_k_c, sizeof(__pyx_k_c), 0, 0, 1, 1},
   34838           3 :     {&__pyx_n_u_c, __pyx_k_c, sizeof(__pyx_k_c), 0, 1, 0, 1},
   34839           3 :     {&__pyx_n_s_class, __pyx_k_class, sizeof(__pyx_k_class), 0, 0, 1, 1},
   34840           3 :     {&__pyx_n_s_class_getitem, __pyx_k_class_getitem, sizeof(__pyx_k_class_getitem), 0, 0, 1, 1},
   34841           3 :     {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback, sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
   34842           3 :     {&__pyx_n_s_collections, __pyx_k_collections, sizeof(__pyx_k_collections), 0, 0, 1, 1},
   34843           3 :     {&__pyx_kp_s_collections_abc, __pyx_k_collections_abc, sizeof(__pyx_k_collections_abc), 0, 0, 1, 0},
   34844           3 :     {&__pyx_kp_s_contiguous_and_direct, __pyx_k_contiguous_and_direct, sizeof(__pyx_k_contiguous_and_direct), 0, 0, 1, 0},
   34845           3 :     {&__pyx_kp_s_contiguous_and_indirect, __pyx_k_contiguous_and_indirect, sizeof(__pyx_k_contiguous_and_indirect), 0, 0, 1, 0},
   34846           3 :     {&__pyx_n_s_copy, __pyx_k_copy, sizeof(__pyx_k_copy), 0, 0, 1, 1},
   34847           3 :     {&__pyx_n_s_count, __pyx_k_count, sizeof(__pyx_k_count), 0, 0, 1, 1},
   34848           3 :     {&__pyx_n_s_defaults, __pyx_k_defaults, sizeof(__pyx_k_defaults), 0, 0, 1, 1},
   34849           3 :     {&__pyx_n_s_dict, __pyx_k_dict, sizeof(__pyx_k_dict), 0, 0, 1, 1},
   34850           3 :     {&__pyx_kp_u_disable, __pyx_k_disable, sizeof(__pyx_k_disable), 0, 1, 0, 0},
   34851           3 :     {&__pyx_n_s_doc, __pyx_k_doc, sizeof(__pyx_k_doc), 0, 0, 1, 1},
   34852           3 :     {&__pyx_n_s_dtype, __pyx_k_dtype, sizeof(__pyx_k_dtype), 0, 0, 1, 1},
   34853           3 :     {&__pyx_n_s_dtype_is_object, __pyx_k_dtype_is_object, sizeof(__pyx_k_dtype_is_object), 0, 0, 1, 1},
   34854           3 :     {&__pyx_n_s_empty, __pyx_k_empty, sizeof(__pyx_k_empty), 0, 0, 1, 1},
   34855           3 :     {&__pyx_kp_u_enable, __pyx_k_enable, sizeof(__pyx_k_enable), 0, 1, 0, 0},
   34856           3 :     {&__pyx_n_s_encode, __pyx_k_encode, sizeof(__pyx_k_encode), 0, 0, 1, 1},
   34857           3 :     {&__pyx_n_s_enumerate, __pyx_k_enumerate, sizeof(__pyx_k_enumerate), 0, 0, 1, 1},
   34858           3 :     {&__pyx_n_s_error, __pyx_k_error, sizeof(__pyx_k_error), 0, 0, 1, 1},
   34859           3 :     {&__pyx_n_s_flags, __pyx_k_flags, sizeof(__pyx_k_flags), 0, 0, 1, 1},
   34860           3 :     {&__pyx_n_s_float32_t, __pyx_k_float32_t, sizeof(__pyx_k_float32_t), 0, 0, 1, 1},
   34861           3 :     {&__pyx_n_s_float64_t, __pyx_k_float64_t, sizeof(__pyx_k_float64_t), 0, 0, 1, 1},
   34862           3 :     {&__pyx_n_s_format, __pyx_k_format, sizeof(__pyx_k_format), 0, 0, 1, 1},
   34863           3 :     {&__pyx_n_s_fortran, __pyx_k_fortran, sizeof(__pyx_k_fortran), 0, 0, 1, 1},
   34864           3 :     {&__pyx_n_u_fortran, __pyx_k_fortran, sizeof(__pyx_k_fortran), 0, 1, 0, 1},
   34865           3 :     {&__pyx_n_s_fused_sigindex, __pyx_k_fused_sigindex, sizeof(__pyx_k_fused_sigindex), 0, 0, 1, 1},
   34866           3 :     {&__pyx_kp_u_gc, __pyx_k_gc, sizeof(__pyx_k_gc), 0, 1, 0, 0},
   34867           3 :     {&__pyx_n_s_get, __pyx_k_get, sizeof(__pyx_k_get), 0, 0, 1, 1},
   34868           3 :     {&__pyx_n_s_get_nonzero_line, __pyx_k_get_nonzero_line, sizeof(__pyx_k_get_nonzero_line), 0, 0, 1, 1},
   34869           3 :     {&__pyx_n_s_get_read_line, __pyx_k_get_read_line, sizeof(__pyx_k_get_read_line), 0, 0, 1, 1},
   34870           3 :     {&__pyx_n_s_get_write_line, __pyx_k_get_write_line, sizeof(__pyx_k_get_write_line), 0, 0, 1, 1},
   34871           3 :     {&__pyx_n_s_getstate, __pyx_k_getstate, sizeof(__pyx_k_getstate), 0, 0, 1, 1},
   34872           3 :     {&__pyx_kp_u_got, __pyx_k_got, sizeof(__pyx_k_got), 0, 1, 0, 0},
   34873           3 :     {&__pyx_kp_u_got_differing_extents_in_dimensi, __pyx_k_got_differing_extents_in_dimensi, sizeof(__pyx_k_got_differing_extents_in_dimensi), 0, 1, 0, 0},
   34874           3 :     {&__pyx_kp_s_home_czgdp18079_Quansight_scipy, __pyx_k_home_czgdp18079_Quansight_scipy, sizeof(__pyx_k_home_czgdp18079_Quansight_scipy), 0, 0, 1, 0},
   34875           3 :     {&__pyx_n_s_id, __pyx_k_id, sizeof(__pyx_k_id), 0, 0, 1, 1},
   34876           3 :     {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1},
   34877           3 :     {&__pyx_n_s_index, __pyx_k_index, sizeof(__pyx_k_index), 0, 0, 1, 1},
   34878           3 :     {&__pyx_n_s_init_subclass, __pyx_k_init_subclass, sizeof(__pyx_k_init_subclass), 0, 0, 1, 1},
   34879           3 :     {&__pyx_n_s_initializing, __pyx_k_initializing, sizeof(__pyx_k_initializing), 0, 0, 1, 1},
   34880           3 :     {&__pyx_n_s_input, __pyx_k_input, sizeof(__pyx_k_input), 0, 0, 1, 1},
   34881           3 :     {&__pyx_n_s_int16_t, __pyx_k_int16_t, sizeof(__pyx_k_int16_t), 0, 0, 1, 1},
   34882           3 :     {&__pyx_n_s_int32_t, __pyx_k_int32_t, sizeof(__pyx_k_int32_t), 0, 0, 1, 1},
   34883           3 :     {&__pyx_n_s_int64_t, __pyx_k_int64_t, sizeof(__pyx_k_int64_t), 0, 0, 1, 1},
   34884           3 :     {&__pyx_n_s_int8_t, __pyx_k_int8_t, sizeof(__pyx_k_int8_t), 0, 0, 1, 1},
   34885           3 :     {&__pyx_n_s_is_coroutine, __pyx_k_is_coroutine, sizeof(__pyx_k_is_coroutine), 0, 0, 1, 1},
   34886           3 :     {&__pyx_kp_u_isenabled, __pyx_k_isenabled, sizeof(__pyx_k_isenabled), 0, 1, 0, 0},
   34887           3 :     {&__pyx_n_s_itemsize, __pyx_k_itemsize, sizeof(__pyx_k_itemsize), 0, 0, 1, 1},
   34888           3 :     {&__pyx_kp_s_itemsize_0_for_cython_array, __pyx_k_itemsize_0_for_cython_array, sizeof(__pyx_k_itemsize_0_for_cython_array), 0, 0, 1, 0},
   34889           3 :     {&__pyx_n_s_kind, __pyx_k_kind, sizeof(__pyx_k_kind), 0, 0, 1, 1},
   34890           3 :     {&__pyx_n_s_kwargs, __pyx_k_kwargs, sizeof(__pyx_k_kwargs), 0, 0, 1, 1},
   34891           3 :     {&__pyx_n_s_label, __pyx_k_label, sizeof(__pyx_k_label), 0, 0, 1, 1},
   34892           3 :     {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
   34893           3 :     {&__pyx_n_s_memview, __pyx_k_memview, sizeof(__pyx_k_memview), 0, 0, 1, 1},
   34894           3 :     {&__pyx_n_s_metaclass, __pyx_k_metaclass, sizeof(__pyx_k_metaclass), 0, 0, 1, 1},
   34895           3 :     {&__pyx_n_s_mode, __pyx_k_mode, sizeof(__pyx_k_mode), 0, 0, 1, 1},
   34896           3 :     {&__pyx_n_s_module, __pyx_k_module, sizeof(__pyx_k_module), 0, 0, 1, 1},
   34897           3 :     {&__pyx_n_s_mro_entries, __pyx_k_mro_entries, sizeof(__pyx_k_mro_entries), 0, 0, 1, 1},
   34898           3 :     {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
   34899           3 :     {&__pyx_n_s_name_2, __pyx_k_name_2, sizeof(__pyx_k_name_2), 0, 0, 1, 1},
   34900           3 :     {&__pyx_n_s_ndim, __pyx_k_ndim, sizeof(__pyx_k_ndim), 0, 0, 1, 1},
   34901           3 :     {&__pyx_n_s_new, __pyx_k_new, sizeof(__pyx_k_new), 0, 0, 1, 1},
   34902           3 :     {&__pyx_n_s_ni_label, __pyx_k_ni_label, sizeof(__pyx_k_ni_label), 0, 0, 1, 1},
   34903           3 :     {&__pyx_kp_s_no_default___reduce___due_to_non, __pyx_k_no_default___reduce___due_to_non, sizeof(__pyx_k_no_default___reduce___due_to_non), 0, 0, 1, 0},
   34904           3 :     {&__pyx_n_s_np, __pyx_k_np, sizeof(__pyx_k_np), 0, 0, 1, 1},
   34905           3 :     {&__pyx_n_s_numpy, __pyx_k_numpy, sizeof(__pyx_k_numpy), 0, 0, 1, 1},
   34906           3 :     {&__pyx_kp_u_numpy__core_multiarray_failed_to, __pyx_k_numpy__core_multiarray_failed_to, sizeof(__pyx_k_numpy__core_multiarray_failed_to), 0, 1, 0, 0},
   34907           3 :     {&__pyx_kp_u_numpy__core_umath_failed_to_impo, __pyx_k_numpy__core_umath_failed_to_impo, sizeof(__pyx_k_numpy__core_umath_failed_to_impo), 0, 1, 0, 0},
   34908           3 :     {&__pyx_n_s_obj, __pyx_k_obj, sizeof(__pyx_k_obj), 0, 0, 1, 1},
   34909           3 :     {&__pyx_n_s_output, __pyx_k_output, sizeof(__pyx_k_output), 0, 0, 1, 1},
   34910           3 :     {&__pyx_n_s_pack, __pyx_k_pack, sizeof(__pyx_k_pack), 0, 0, 1, 1},
   34911           3 :     {&__pyx_n_s_pickle, __pyx_k_pickle, sizeof(__pyx_k_pickle), 0, 0, 1, 1},
   34912           3 :     {&__pyx_n_s_prepare, __pyx_k_prepare, sizeof(__pyx_k_prepare), 0, 0, 1, 1},
   34913           3 :     {&__pyx_n_s_pyx_PickleError, __pyx_k_pyx_PickleError, sizeof(__pyx_k_pyx_PickleError), 0, 0, 1, 1},
   34914           3 :     {&__pyx_n_s_pyx_checksum, __pyx_k_pyx_checksum, sizeof(__pyx_k_pyx_checksum), 0, 0, 1, 1},
   34915           3 :     {&__pyx_n_s_pyx_result, __pyx_k_pyx_result, sizeof(__pyx_k_pyx_result), 0, 0, 1, 1},
   34916           3 :     {&__pyx_n_s_pyx_state, __pyx_k_pyx_state, sizeof(__pyx_k_pyx_state), 0, 0, 1, 1},
   34917           3 :     {&__pyx_n_s_pyx_type, __pyx_k_pyx_type, sizeof(__pyx_k_pyx_type), 0, 0, 1, 1},
   34918           3 :     {&__pyx_n_s_pyx_unpickle_Enum, __pyx_k_pyx_unpickle_Enum, sizeof(__pyx_k_pyx_unpickle_Enum), 0, 0, 1, 1},
   34919           3 :     {&__pyx_n_s_pyx_vtable, __pyx_k_pyx_vtable, sizeof(__pyx_k_pyx_vtable), 0, 0, 1, 1},
   34920           3 :     {&__pyx_n_s_qualname, __pyx_k_qualname, sizeof(__pyx_k_qualname), 0, 0, 1, 1},
   34921           3 :     {&__pyx_n_s_range, __pyx_k_range, sizeof(__pyx_k_range), 0, 0, 1, 1},
   34922           3 :     {&__pyx_n_s_reduce, __pyx_k_reduce, sizeof(__pyx_k_reduce), 0, 0, 1, 1},
   34923           3 :     {&__pyx_n_s_reduce_cython, __pyx_k_reduce_cython, sizeof(__pyx_k_reduce_cython), 0, 0, 1, 1},
   34924           3 :     {&__pyx_n_s_reduce_ex, __pyx_k_reduce_ex, sizeof(__pyx_k_reduce_ex), 0, 0, 1, 1},
   34925           3 :     {&__pyx_n_s_register, __pyx_k_register, sizeof(__pyx_k_register), 0, 0, 1, 1},
   34926           3 :     {&__pyx_n_s_s, __pyx_k_s, sizeof(__pyx_k_s), 0, 0, 1, 1},
   34927           3 :     {&__pyx_n_s_set_name, __pyx_k_set_name, sizeof(__pyx_k_set_name), 0, 0, 1, 1},
   34928           3 :     {&__pyx_n_s_setstate, __pyx_k_setstate, sizeof(__pyx_k_setstate), 0, 0, 1, 1},
   34929           3 :     {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython, sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1},
   34930           3 :     {&__pyx_n_s_shape, __pyx_k_shape, sizeof(__pyx_k_shape), 0, 0, 1, 1},
   34931           3 :     {&__pyx_n_s_signatures, __pyx_k_signatures, sizeof(__pyx_k_signatures), 0, 0, 1, 1},
   34932           3 :     {&__pyx_n_s_size, __pyx_k_size, sizeof(__pyx_k_size), 0, 0, 1, 1},
   34933           3 :     {&__pyx_n_s_spec, __pyx_k_spec, sizeof(__pyx_k_spec), 0, 0, 1, 1},
   34934           3 :     {&__pyx_n_s_split, __pyx_k_split, sizeof(__pyx_k_split), 0, 0, 1, 1},
   34935           3 :     {&__pyx_n_s_start, __pyx_k_start, sizeof(__pyx_k_start), 0, 0, 1, 1},
   34936           3 :     {&__pyx_n_s_step, __pyx_k_step, sizeof(__pyx_k_step), 0, 0, 1, 1},
   34937           3 :     {&__pyx_n_s_stop, __pyx_k_stop, sizeof(__pyx_k_stop), 0, 0, 1, 1},
   34938           3 :     {&__pyx_kp_s_strided_and_direct, __pyx_k_strided_and_direct, sizeof(__pyx_k_strided_and_direct), 0, 0, 1, 0},
   34939           3 :     {&__pyx_kp_s_strided_and_direct_or_indirect, __pyx_k_strided_and_direct_or_indirect, sizeof(__pyx_k_strided_and_direct_or_indirect), 0, 0, 1, 0},
   34940           3 :     {&__pyx_kp_s_strided_and_indirect, __pyx_k_strided_and_indirect, sizeof(__pyx_k_strided_and_indirect), 0, 0, 1, 0},
   34941           3 :     {&__pyx_kp_s_stringsource, __pyx_k_stringsource, sizeof(__pyx_k_stringsource), 0, 0, 1, 0},
   34942           3 :     {&__pyx_n_s_strip, __pyx_k_strip, sizeof(__pyx_k_strip), 0, 0, 1, 1},
   34943           3 :     {&__pyx_n_s_struct, __pyx_k_struct, sizeof(__pyx_k_struct), 0, 0, 1, 1},
   34944           3 :     {&__pyx_n_s_structure, __pyx_k_structure, sizeof(__pyx_k_structure), 0, 0, 1, 1},
   34945           3 :     {&__pyx_n_s_super, __pyx_k_super, sizeof(__pyx_k_super), 0, 0, 1, 1},
   34946           3 :     {&__pyx_n_s_sys, __pyx_k_sys, sizeof(__pyx_k_sys), 0, 0, 1, 1},
   34947           3 :     {&__pyx_n_s_take, __pyx_k_take, sizeof(__pyx_k_take), 0, 0, 1, 1},
   34948           3 :     {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
   34949           3 :     {&__pyx_n_s_uint16_t, __pyx_k_uint16_t, sizeof(__pyx_k_uint16_t), 0, 0, 1, 1},
   34950           3 :     {&__pyx_n_s_uint32_t, __pyx_k_uint32_t, sizeof(__pyx_k_uint32_t), 0, 0, 1, 1},
   34951           3 :     {&__pyx_n_s_uint64_t, __pyx_k_uint64_t, sizeof(__pyx_k_uint64_t), 0, 0, 1, 1},
   34952           3 :     {&__pyx_n_s_uint8, __pyx_k_uint8, sizeof(__pyx_k_uint8), 0, 0, 1, 1},
   34953           3 :     {&__pyx_n_s_uint8_t, __pyx_k_uint8_t, sizeof(__pyx_k_uint8_t), 0, 0, 1, 1},
   34954           3 :     {&__pyx_n_s_uintp, __pyx_k_uintp, sizeof(__pyx_k_uintp), 0, 0, 1, 1},
   34955           3 :     {&__pyx_kp_s_unable_to_allocate_array_data, __pyx_k_unable_to_allocate_array_data, sizeof(__pyx_k_unable_to_allocate_array_data), 0, 0, 1, 0},
   34956           3 :     {&__pyx_kp_s_unable_to_allocate_shape_and_str, __pyx_k_unable_to_allocate_shape_and_str, sizeof(__pyx_k_unable_to_allocate_shape_and_str), 0, 0, 1, 0},
   34957           3 :     {&__pyx_n_s_unpack, __pyx_k_unpack, sizeof(__pyx_k_unpack), 0, 0, 1, 1},
   34958           3 :     {&__pyx_n_s_update, __pyx_k_update, sizeof(__pyx_k_update), 0, 0, 1, 1},
   34959           3 :     {&__pyx_n_s_values, __pyx_k_values, sizeof(__pyx_k_values), 0, 0, 1, 1},
   34960           3 :     {&__pyx_n_s_version_info, __pyx_k_version_info, sizeof(__pyx_k_version_info), 0, 0, 1, 1},
   34961           3 :     {&__pyx_n_s_view, __pyx_k_view, sizeof(__pyx_k_view), 0, 0, 1, 1},
   34962             :     {0, 0, 0, 0, 0, 0, 0}
   34963             :   };
   34964           3 :   return __Pyx_InitStrings(__pyx_string_tab);
   34965             : }
   34966             : /* #### Code section: cached_builtins ### */
   34967           3 : static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) {
   34968           3 :   __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 57, __pyx_L1_error)
   34969           3 :   __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(0, 93, __pyx_L1_error)
   34970           3 :   __pyx_builtin_ValueError = __Pyx_GetBuiltinName(__pyx_n_s_ValueError); if (!__pyx_builtin_ValueError) __PYX_ERR(0, 93, __pyx_L1_error)
   34971           3 :   __pyx_builtin_AssertionError = __Pyx_GetBuiltinName(__pyx_n_s_AssertionError); if (!__pyx_builtin_AssertionError) __PYX_ERR(0, 206, __pyx_L1_error)
   34972           3 :   __pyx_builtin_MemoryError = __Pyx_GetBuiltinName(__pyx_n_s_MemoryError); if (!__pyx_builtin_MemoryError) __PYX_ERR(0, 290, __pyx_L1_error)
   34973           3 :   __pyx_builtin___import__ = __Pyx_GetBuiltinName(__pyx_n_s_import); if (!__pyx_builtin___import__) __PYX_ERR(1, 100, __pyx_L1_error)
   34974           3 :   __pyx_builtin_enumerate = __Pyx_GetBuiltinName(__pyx_n_s_enumerate); if (!__pyx_builtin_enumerate) __PYX_ERR(1, 159, __pyx_L1_error)
   34975           3 :   __pyx_builtin_Ellipsis = __Pyx_GetBuiltinName(__pyx_n_s_Ellipsis); if (!__pyx_builtin_Ellipsis) __PYX_ERR(1, 408, __pyx_L1_error)
   34976           3 :   __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id); if (!__pyx_builtin_id) __PYX_ERR(1, 618, __pyx_L1_error)
   34977           3 :   __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) __PYX_ERR(1, 914, __pyx_L1_error)
   34978           3 :   __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError); if (!__pyx_builtin_ImportError) __PYX_ERR(2, 1025, __pyx_L1_error)
   34979             :   return 0;
   34980             :   __pyx_L1_error:;
   34981             :   return -1;
   34982             : }
   34983             : /* #### Code section: cached_constants ### */
   34984             : 
   34985           3 : static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) {
   34986             :   __Pyx_RefNannyDeclarations
   34987           3 :   __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);
   34988             : 
   34989             :   /* "View.MemoryView":582
   34990             :  *     def suboffsets(self):
   34991             :  *         if self.view.suboffsets == NULL:
   34992             :  *             return (-1,) * self.view.ndim             # <<<<<<<<<<<<<<
   34993             :  * 
   34994             :  *         return tuple([suboffset for suboffset in self.view.suboffsets[:self.view.ndim]])
   34995             :  */
   34996           3 :   __pyx_tuple__4 = PyTuple_New(1); if (unlikely(!__pyx_tuple__4)) __PYX_ERR(1, 582, __pyx_L1_error)
   34997           3 :   __Pyx_GOTREF(__pyx_tuple__4);
   34998           3 :   __Pyx_INCREF(__pyx_int_neg_1);
   34999           3 :   __Pyx_GIVEREF(__pyx_int_neg_1);
   35000           3 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_tuple__4, 0, __pyx_int_neg_1)) __PYX_ERR(1, 582, __pyx_L1_error);
   35001           3 :   __Pyx_GIVEREF(__pyx_tuple__4);
   35002             : 
   35003             :   /* "View.MemoryView":679
   35004             :  *     tup = <tuple>index if isinstance(index, tuple) else (index,)
   35005             :  * 
   35006             :  *     result = [slice(None)] * ndim             # <<<<<<<<<<<<<<
   35007             :  *     have_slices = False
   35008             :  *     seen_ellipsis = False
   35009             :  */
   35010           3 :   __pyx_slice__5 = PySlice_New(Py_None, Py_None, Py_None); if (unlikely(!__pyx_slice__5)) __PYX_ERR(1, 679, __pyx_L1_error)
   35011           3 :   __Pyx_GOTREF(__pyx_slice__5);
   35012           3 :   __Pyx_GIVEREF(__pyx_slice__5);
   35013             : 
   35014             :   /* "(tree fragment)":4
   35015             :  *     cdef object __pyx_PickleError
   35016             :  *     cdef object __pyx_result
   35017             :  *     if __pyx_checksum not in (0x82a3537, 0x6ae9995, 0xb068931):             # <<<<<<<<<<<<<<
   35018             :  *         from pickle import PickleError as __pyx_PickleError
   35019             :  *         raise __pyx_PickleError, "Incompatible checksums (0x%x vs (0x82a3537, 0x6ae9995, 0xb068931) = (name))" % __pyx_checksum
   35020             :  */
   35021           3 :   __pyx_tuple__8 = PyTuple_Pack(3, __pyx_int_136983863, __pyx_int_112105877, __pyx_int_184977713); if (unlikely(!__pyx_tuple__8)) __PYX_ERR(1, 4, __pyx_L1_error)
   35022           3 :   __Pyx_GOTREF(__pyx_tuple__8);
   35023           3 :   __Pyx_GIVEREF(__pyx_tuple__8);
   35024             : 
   35025             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1025
   35026             :  *         __pyx_import_array()
   35027             :  *     except Exception:
   35028             :  *         raise ImportError("numpy._core.multiarray failed to import")             # <<<<<<<<<<<<<<
   35029             :  * 
   35030             :  * cdef inline int import_umath() except -1:
   35031             :  */
   35032           3 :   __pyx_tuple__9 = PyTuple_Pack(1, __pyx_kp_u_numpy__core_multiarray_failed_to); if (unlikely(!__pyx_tuple__9)) __PYX_ERR(2, 1025, __pyx_L1_error)
   35033           3 :   __Pyx_GOTREF(__pyx_tuple__9);
   35034           3 :   __Pyx_GIVEREF(__pyx_tuple__9);
   35035             : 
   35036             :   /* "../../../miniforge3/envs/scipy-dev/lib/python3.12/site-packages/numpy/__init__.cython-30.pxd":1031
   35037             :  *         _import_umath()
   35038             :  *     except Exception:
   35039             :  *         raise ImportError("numpy._core.umath failed to import")             # <<<<<<<<<<<<<<
   35040             :  * 
   35041             :  * cdef inline int import_ufunc() except -1:
   35042             :  */
   35043           3 :   __pyx_tuple__10 = PyTuple_Pack(1, __pyx_kp_u_numpy__core_umath_failed_to_impo); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(2, 1031, __pyx_L1_error)
   35044           3 :   __Pyx_GOTREF(__pyx_tuple__10);
   35045           3 :   __Pyx_GIVEREF(__pyx_tuple__10);
   35046             : 
   35047             :   /* "_ni_label.pyx":93
   35048             :  * # Function specializers
   35049             :  * ######################################################################
   35050             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   35051             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   35052             :  * 
   35053             :  */
   35054           3 :   __pyx_tuple__14 = PyTuple_Pack(1, __pyx_kp_s_No_matching_signature_found); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 93, __pyx_L1_error)
   35055           3 :   __Pyx_GOTREF(__pyx_tuple__14);
   35056           3 :   __Pyx_GIVEREF(__pyx_tuple__14);
   35057           3 :   __pyx_tuple__15 = PyTuple_Pack(1, __pyx_kp_s_Function_call_with_ambiguous_arg); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(0, 93, __pyx_L1_error)
   35058           3 :   __Pyx_GOTREF(__pyx_tuple__15);
   35059           3 :   __Pyx_GIVEREF(__pyx_tuple__15);
   35060             : 
   35061             :   /* "_ni_label.pyx":222
   35062             :  * 
   35063             :  *     # check structuring element for symmetry
   35064             :  *     assert np.all(structure == structure[(np.s_[::-1],) * structure.ndim]), \             # <<<<<<<<<<<<<<
   35065             :  *         "Structuring element is not symmetric"
   35066             :  * 
   35067             :  */
   35068           3 :   __pyx_slice__16 = PySlice_New(Py_None, Py_None, __pyx_int_neg_1); if (unlikely(!__pyx_slice__16)) __PYX_ERR(0, 222, __pyx_L1_error)
   35069           3 :   __Pyx_GOTREF(__pyx_slice__16);
   35070           3 :   __Pyx_GIVEREF(__pyx_slice__16);
   35071             : 
   35072             :   /* "View.MemoryView":100
   35073             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35074             :  * try:
   35075             :  *     if __import__("sys").version_info >= (3, 3):             # <<<<<<<<<<<<<<
   35076             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35077             :  *     else:
   35078             :  */
   35079           3 :   __pyx_tuple__17 = PyTuple_Pack(1, __pyx_n_s_sys); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(1, 100, __pyx_L1_error)
   35080           3 :   __Pyx_GOTREF(__pyx_tuple__17);
   35081           3 :   __Pyx_GIVEREF(__pyx_tuple__17);
   35082           3 :   __pyx_tuple__18 = PyTuple_Pack(2, __pyx_int_3, __pyx_int_3); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(1, 100, __pyx_L1_error)
   35083           3 :   __Pyx_GOTREF(__pyx_tuple__18);
   35084           3 :   __Pyx_GIVEREF(__pyx_tuple__18);
   35085             : 
   35086             :   /* "View.MemoryView":101
   35087             :  * try:
   35088             :  *     if __import__("sys").version_info >= (3, 3):
   35089             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence             # <<<<<<<<<<<<<<
   35090             :  *     else:
   35091             :  *         __pyx_collections_abc_Sequence = __import__("collections").Sequence
   35092             :  */
   35093           3 :   __pyx_tuple__19 = PyTuple_Pack(1, __pyx_kp_s_collections_abc); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(1, 101, __pyx_L1_error)
   35094           3 :   __Pyx_GOTREF(__pyx_tuple__19);
   35095           3 :   __Pyx_GIVEREF(__pyx_tuple__19);
   35096             : 
   35097             :   /* "View.MemoryView":103
   35098             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35099             :  *     else:
   35100             :  *         __pyx_collections_abc_Sequence = __import__("collections").Sequence             # <<<<<<<<<<<<<<
   35101             :  * except:
   35102             :  * 
   35103             :  */
   35104           3 :   __pyx_tuple__20 = PyTuple_Pack(1, __pyx_n_s_collections); if (unlikely(!__pyx_tuple__20)) __PYX_ERR(1, 103, __pyx_L1_error)
   35105           3 :   __Pyx_GOTREF(__pyx_tuple__20);
   35106           3 :   __Pyx_GIVEREF(__pyx_tuple__20);
   35107             : 
   35108             :   /* "View.MemoryView":309
   35109             :  *         return self.name
   35110             :  * 
   35111             :  * cdef generic = Enum("<strided and direct or indirect>")             # <<<<<<<<<<<<<<
   35112             :  * cdef strided = Enum("<strided and direct>") # default
   35113             :  * cdef indirect = Enum("<strided and indirect>")
   35114             :  */
   35115           3 :   __pyx_tuple__21 = PyTuple_Pack(1, __pyx_kp_s_strided_and_direct_or_indirect); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(1, 309, __pyx_L1_error)
   35116           3 :   __Pyx_GOTREF(__pyx_tuple__21);
   35117           3 :   __Pyx_GIVEREF(__pyx_tuple__21);
   35118             : 
   35119             :   /* "View.MemoryView":310
   35120             :  * 
   35121             :  * cdef generic = Enum("<strided and direct or indirect>")
   35122             :  * cdef strided = Enum("<strided and direct>") # default             # <<<<<<<<<<<<<<
   35123             :  * cdef indirect = Enum("<strided and indirect>")
   35124             :  * 
   35125             :  */
   35126           3 :   __pyx_tuple__22 = PyTuple_Pack(1, __pyx_kp_s_strided_and_direct); if (unlikely(!__pyx_tuple__22)) __PYX_ERR(1, 310, __pyx_L1_error)
   35127           3 :   __Pyx_GOTREF(__pyx_tuple__22);
   35128           3 :   __Pyx_GIVEREF(__pyx_tuple__22);
   35129             : 
   35130             :   /* "View.MemoryView":311
   35131             :  * cdef generic = Enum("<strided and direct or indirect>")
   35132             :  * cdef strided = Enum("<strided and direct>") # default
   35133             :  * cdef indirect = Enum("<strided and indirect>")             # <<<<<<<<<<<<<<
   35134             :  * 
   35135             :  * 
   35136             :  */
   35137           3 :   __pyx_tuple__23 = PyTuple_Pack(1, __pyx_kp_s_strided_and_indirect); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(1, 311, __pyx_L1_error)
   35138           3 :   __Pyx_GOTREF(__pyx_tuple__23);
   35139           3 :   __Pyx_GIVEREF(__pyx_tuple__23);
   35140             : 
   35141             :   /* "View.MemoryView":314
   35142             :  * 
   35143             :  * 
   35144             :  * cdef contiguous = Enum("<contiguous and direct>")             # <<<<<<<<<<<<<<
   35145             :  * cdef indirect_contiguous = Enum("<contiguous and indirect>")
   35146             :  * 
   35147             :  */
   35148           3 :   __pyx_tuple__24 = PyTuple_Pack(1, __pyx_kp_s_contiguous_and_direct); if (unlikely(!__pyx_tuple__24)) __PYX_ERR(1, 314, __pyx_L1_error)
   35149           3 :   __Pyx_GOTREF(__pyx_tuple__24);
   35150           3 :   __Pyx_GIVEREF(__pyx_tuple__24);
   35151             : 
   35152             :   /* "View.MemoryView":315
   35153             :  * 
   35154             :  * cdef contiguous = Enum("<contiguous and direct>")
   35155             :  * cdef indirect_contiguous = Enum("<contiguous and indirect>")             # <<<<<<<<<<<<<<
   35156             :  * 
   35157             :  * 
   35158             :  */
   35159           3 :   __pyx_tuple__25 = PyTuple_Pack(1, __pyx_kp_s_contiguous_and_indirect); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(1, 315, __pyx_L1_error)
   35160           3 :   __Pyx_GOTREF(__pyx_tuple__25);
   35161           3 :   __Pyx_GIVEREF(__pyx_tuple__25);
   35162             : 
   35163             :   /* "(tree fragment)":1
   35164             :  * def __pyx_unpickle_Enum(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
   35165             :  *     cdef object __pyx_PickleError
   35166             :  *     cdef object __pyx_result
   35167             :  */
   35168           3 :   __pyx_tuple__26 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__26)) __PYX_ERR(1, 1, __pyx_L1_error)
   35169           3 :   __Pyx_GOTREF(__pyx_tuple__26);
   35170           3 :   __Pyx_GIVEREF(__pyx_tuple__26);
   35171           3 :   __pyx_codeobj__27 = (PyObject*)__Pyx_PyCode_New(3, 0, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__26, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Enum, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__27)) __PYX_ERR(1, 1, __pyx_L1_error)
   35172             : 
   35173             :   /* "_ni_label.pyx":93
   35174             :  * # Function specializers
   35175             :  * ######################################################################
   35176             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   35177             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   35178             :  * 
   35179             :  */
   35180           3 :   __pyx_tuple__28 = PyTuple_Pack(1, __pyx_n_s_a); if (unlikely(!__pyx_tuple__28)) __PYX_ERR(0, 93, __pyx_L1_error)
   35181           3 :   __Pyx_GOTREF(__pyx_tuple__28);
   35182           3 :   __Pyx_GIVEREF(__pyx_tuple__28);
   35183           3 :   __pyx_codeobj__29 = (PyObject*)__Pyx_PyCode_New(1, 0, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__28, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_czgdp18079_Quansight_scipy, __pyx_n_s_get_nonzero_line, 93, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__29)) __PYX_ERR(0, 93, __pyx_L1_error)
   35184             : 
   35185             :   /* "_ni_label.pyx":96
   35186             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   35187             :  * 
   35188             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   35189             :  *     return <Py_intptr_t> fused_read_line[data_t]
   35190             :  * 
   35191             :  */
   35192           3 :   __pyx_codeobj__30 = (PyObject*)__Pyx_PyCode_New(1, 0, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__28, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_czgdp18079_Quansight_scipy, __pyx_n_s_get_read_line, 96, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__30)) __PYX_ERR(0, 96, __pyx_L1_error)
   35193             : 
   35194             :   /* "_ni_label.pyx":99
   35195             :  *     return <Py_intptr_t> fused_read_line[data_t]
   35196             :  * 
   35197             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   35198             :  *     return <Py_intptr_t> fused_write_line[data_t]
   35199             :  * 
   35200             :  */
   35201           3 :   __pyx_codeobj__31 = (PyObject*)__Pyx_PyCode_New(1, 0, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__28, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_czgdp18079_Quansight_scipy, __pyx_n_s_get_write_line, 99, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__31)) __PYX_ERR(0, 99, __pyx_L1_error)
   35202             : 
   35203             :   /* "_ni_label.pyx":200
   35204             :  * # Label regions
   35205             :  * ######################################################################
   35206             :  * cpdef _label(np.ndarray input,             # <<<<<<<<<<<<<<
   35207             :  *              np.ndarray structure,
   35208             :  *              np.ndarray output):
   35209             :  */
   35210           3 :   __pyx_tuple__32 = PyTuple_Pack(3, __pyx_n_s_input, __pyx_n_s_structure, __pyx_n_s_output); if (unlikely(!__pyx_tuple__32)) __PYX_ERR(0, 200, __pyx_L1_error)
   35211           3 :   __Pyx_GOTREF(__pyx_tuple__32);
   35212           3 :   __Pyx_GIVEREF(__pyx_tuple__32);
   35213           3 :   __pyx_codeobj__33 = (PyObject*)__Pyx_PyCode_New(3, 0, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__32, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_czgdp18079_Quansight_scipy, __pyx_n_s_label, 200, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__33)) __PYX_ERR(0, 200, __pyx_L1_error)
   35214             :   __Pyx_RefNannyFinishContext();
   35215             :   return 0;
   35216             :   __pyx_L1_error:;
   35217             :   __Pyx_RefNannyFinishContext();
   35218             :   return -1;
   35219             : }
   35220             : /* #### Code section: init_constants ### */
   35221             : 
   35222           3 : static CYTHON_SMALL_CODE int __Pyx_InitConstants(void) {
   35223           3 :   __pyx_umethod_PyDict_Type_get.type = (PyObject*)&PyDict_Type;
   35224           3 :   __pyx_umethod_PyDict_Type_get.method_name = &__pyx_n_s_get;
   35225           3 :   __pyx_umethod_PyDict_Type_values.type = (PyObject*)&PyDict_Type;
   35226           3 :   __pyx_umethod_PyDict_Type_values.method_name = &__pyx_n_s_values;
   35227           3 :   if (__Pyx_CreateStringTabAndInitStrings() < 0) __PYX_ERR(0, 1, __pyx_L1_error);
   35228           3 :   __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) __PYX_ERR(0, 1, __pyx_L1_error)
   35229           3 :   __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) __PYX_ERR(0, 1, __pyx_L1_error)
   35230           3 :   __pyx_int_3 = PyInt_FromLong(3); if (unlikely(!__pyx_int_3)) __PYX_ERR(0, 1, __pyx_L1_error)
   35231           3 :   __pyx_int_112105877 = PyInt_FromLong(112105877L); if (unlikely(!__pyx_int_112105877)) __PYX_ERR(0, 1, __pyx_L1_error)
   35232           3 :   __pyx_int_136983863 = PyInt_FromLong(136983863L); if (unlikely(!__pyx_int_136983863)) __PYX_ERR(0, 1, __pyx_L1_error)
   35233           3 :   __pyx_int_184977713 = PyInt_FromLong(184977713L); if (unlikely(!__pyx_int_184977713)) __PYX_ERR(0, 1, __pyx_L1_error)
   35234           3 :   __pyx_int_neg_1 = PyInt_FromLong(-1); if (unlikely(!__pyx_int_neg_1)) __PYX_ERR(0, 1, __pyx_L1_error)
   35235             :   return 0;
   35236             :   __pyx_L1_error:;
   35237             :   return -1;
   35238             : }
   35239             : /* #### Code section: init_globals ### */
   35240             : 
   35241           3 : static CYTHON_SMALL_CODE int __Pyx_InitGlobals(void) {
   35242             :   /* AssertionsEnabled.init */
   35243           3 :   if (likely(__Pyx_init_assertions_enabled() == 0)); else
   35244             : 
   35245           0 : if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1, __pyx_L1_error)
   35246             : 
   35247             :   return 0;
   35248           0 :   __pyx_L1_error:;
   35249           0 :   return -1;
   35250             : }
   35251             : /* #### Code section: init_module ### */
   35252             : 
   35253             : static CYTHON_SMALL_CODE int __Pyx_modinit_global_init_code(void); /*proto*/
   35254             : static CYTHON_SMALL_CODE int __Pyx_modinit_variable_export_code(void); /*proto*/
   35255             : static CYTHON_SMALL_CODE int __Pyx_modinit_function_export_code(void); /*proto*/
   35256             : static CYTHON_SMALL_CODE int __Pyx_modinit_type_init_code(void); /*proto*/
   35257             : static CYTHON_SMALL_CODE int __Pyx_modinit_type_import_code(void); /*proto*/
   35258             : static CYTHON_SMALL_CODE int __Pyx_modinit_variable_import_code(void); /*proto*/
   35259             : static CYTHON_SMALL_CODE int __Pyx_modinit_function_import_code(void); /*proto*/
   35260             : 
   35261           3 : static int __Pyx_modinit_global_init_code(void) {
   35262             :   __Pyx_RefNannyDeclarations
   35263           3 :   __Pyx_RefNannySetupContext("__Pyx_modinit_global_init_code", 0);
   35264             :   /*--- Global init code ---*/
   35265           3 :   __pyx_collections_abc_Sequence = Py_None; Py_INCREF(Py_None);
   35266           3 :   generic = Py_None; Py_INCREF(Py_None);
   35267           3 :   strided = Py_None; Py_INCREF(Py_None);
   35268           3 :   indirect = Py_None; Py_INCREF(Py_None);
   35269           3 :   contiguous = Py_None; Py_INCREF(Py_None);
   35270           3 :   indirect_contiguous = Py_None; Py_INCREF(Py_None);
   35271           3 :   __Pyx_RefNannyFinishContext();
   35272           3 :   return 0;
   35273             : }
   35274             : 
   35275             : static int __Pyx_modinit_variable_export_code(void) {
   35276             :   __Pyx_RefNannyDeclarations
   35277             :   __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0);
   35278             :   /*--- Variable export code ---*/
   35279             :   __Pyx_RefNannyFinishContext();
   35280             :   return 0;
   35281             : }
   35282             : 
   35283             : static int __Pyx_modinit_function_export_code(void) {
   35284             :   __Pyx_RefNannyDeclarations
   35285             :   __Pyx_RefNannySetupContext("__Pyx_modinit_function_export_code", 0);
   35286             :   /*--- Function export code ---*/
   35287             :   __Pyx_RefNannyFinishContext();
   35288             :   return 0;
   35289             : }
   35290             : 
   35291           3 : static int __Pyx_modinit_type_init_code(void) {
   35292             :   __Pyx_RefNannyDeclarations
   35293           3 :   PyObject *__pyx_t_1 = NULL;
   35294           3 :   int __pyx_lineno = 0;
   35295           3 :   const char *__pyx_filename = NULL;
   35296           3 :   int __pyx_clineno = 0;
   35297           3 :   __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0);
   35298             :   /*--- Type init code ---*/
   35299           3 :   __pyx_vtabptr_array = &__pyx_vtable_array;
   35300           3 :   __pyx_vtable_array.get_memview = (PyObject *(*)(struct __pyx_array_obj *))__pyx_array_get_memview;
   35301             :   #if CYTHON_USE_TYPE_SPECS
   35302             :   __pyx_array_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_array_spec, NULL); if (unlikely(!__pyx_array_type)) __PYX_ERR(1, 114, __pyx_L1_error)
   35303             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35304             :   __pyx_array_type->tp_as_buffer = &__pyx_tp_as_buffer_array;
   35305             :   if (!__pyx_array_type->tp_as_buffer->bf_releasebuffer && __pyx_array_type->tp_base->tp_as_buffer && __pyx_array_type->tp_base->tp_as_buffer->bf_releasebuffer) {
   35306             :     __pyx_array_type->tp_as_buffer->bf_releasebuffer = __pyx_array_type->tp_base->tp_as_buffer->bf_releasebuffer;
   35307             :   }
   35308             :   #elif defined(Py_bf_getbuffer) && defined(Py_bf_releasebuffer)
   35309             :   /* PY_VERSION_HEX >= 0x03090000 || Py_LIMITED_API >= 0x030B0000 */
   35310             :   #elif defined(_MSC_VER)
   35311             :   #pragma message ("The buffer protocol is not supported in the Limited C-API < 3.11.")
   35312             :   #else
   35313             :   #warning "The buffer protocol is not supported in the Limited C-API < 3.11."
   35314             :   #endif
   35315             :   if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_array_spec, __pyx_array_type) < 0) __PYX_ERR(1, 114, __pyx_L1_error)
   35316             :   #else
   35317           3 :   __pyx_array_type = &__pyx_type___pyx_array;
   35318             :   #endif
   35319             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35320             :   #endif
   35321             :   #if !CYTHON_USE_TYPE_SPECS
   35322           3 :   if (__Pyx_PyType_Ready(__pyx_array_type) < 0) __PYX_ERR(1, 114, __pyx_L1_error)
   35323             :   #endif
   35324             :   #if PY_MAJOR_VERSION < 3
   35325             :   __pyx_array_type->tp_print = 0;
   35326             :   #endif
   35327           3 :   if (__Pyx_SetVtable(__pyx_array_type, __pyx_vtabptr_array) < 0) __PYX_ERR(1, 114, __pyx_L1_error)
   35328             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35329           3 :   if (__Pyx_MergeVtables(__pyx_array_type) < 0) __PYX_ERR(1, 114, __pyx_L1_error)
   35330             :   #endif
   35331             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35332           3 :   if (__Pyx_setup_reduce((PyObject *) __pyx_array_type) < 0) __PYX_ERR(1, 114, __pyx_L1_error)
   35333             :   #endif
   35334             :   #if CYTHON_USE_TYPE_SPECS
   35335             :   __pyx_MemviewEnum_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_MemviewEnum_spec, NULL); if (unlikely(!__pyx_MemviewEnum_type)) __PYX_ERR(1, 302, __pyx_L1_error)
   35336             :   if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_MemviewEnum_spec, __pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 302, __pyx_L1_error)
   35337             :   #else
   35338           3 :   __pyx_MemviewEnum_type = &__pyx_type___pyx_MemviewEnum;
   35339             :   #endif
   35340             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35341             :   #endif
   35342             :   #if !CYTHON_USE_TYPE_SPECS
   35343           3 :   if (__Pyx_PyType_Ready(__pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 302, __pyx_L1_error)
   35344             :   #endif
   35345             :   #if PY_MAJOR_VERSION < 3
   35346             :   __pyx_MemviewEnum_type->tp_print = 0;
   35347             :   #endif
   35348             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35349           3 :   if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_MemviewEnum_type->tp_dictoffset && __pyx_MemviewEnum_type->tp_getattro == PyObject_GenericGetAttr)) {
   35350           3 :     __pyx_MemviewEnum_type->tp_getattro = __Pyx_PyObject_GenericGetAttr;
   35351             :   }
   35352             :   #endif
   35353             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35354           3 :   if (__Pyx_setup_reduce((PyObject *) __pyx_MemviewEnum_type) < 0) __PYX_ERR(1, 302, __pyx_L1_error)
   35355             :   #endif
   35356           3 :   __pyx_vtabptr_memoryview = &__pyx_vtable_memoryview;
   35357           3 :   __pyx_vtable_memoryview.get_item_pointer = (char *(*)(struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_get_item_pointer;
   35358           3 :   __pyx_vtable_memoryview.is_slice = (PyObject *(*)(struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_is_slice;
   35359           3 :   __pyx_vtable_memoryview.setitem_slice_assignment = (PyObject *(*)(struct __pyx_memoryview_obj *, PyObject *, PyObject *))__pyx_memoryview_setitem_slice_assignment;
   35360           3 :   __pyx_vtable_memoryview.setitem_slice_assign_scalar = (PyObject *(*)(struct __pyx_memoryview_obj *, struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_setitem_slice_assign_scalar;
   35361           3 :   __pyx_vtable_memoryview.setitem_indexed = (PyObject *(*)(struct __pyx_memoryview_obj *, PyObject *, PyObject *))__pyx_memoryview_setitem_indexed;
   35362           3 :   __pyx_vtable_memoryview.convert_item_to_object = (PyObject *(*)(struct __pyx_memoryview_obj *, char *))__pyx_memoryview_convert_item_to_object;
   35363           3 :   __pyx_vtable_memoryview.assign_item_from_object = (PyObject *(*)(struct __pyx_memoryview_obj *, char *, PyObject *))__pyx_memoryview_assign_item_from_object;
   35364           3 :   __pyx_vtable_memoryview._get_base = (PyObject *(*)(struct __pyx_memoryview_obj *))__pyx_memoryview__get_base;
   35365             :   #if CYTHON_USE_TYPE_SPECS
   35366             :   __pyx_memoryview_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_memoryview_spec, NULL); if (unlikely(!__pyx_memoryview_type)) __PYX_ERR(1, 337, __pyx_L1_error)
   35367             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35368             :   __pyx_memoryview_type->tp_as_buffer = &__pyx_tp_as_buffer_memoryview;
   35369             :   if (!__pyx_memoryview_type->tp_as_buffer->bf_releasebuffer && __pyx_memoryview_type->tp_base->tp_as_buffer && __pyx_memoryview_type->tp_base->tp_as_buffer->bf_releasebuffer) {
   35370             :     __pyx_memoryview_type->tp_as_buffer->bf_releasebuffer = __pyx_memoryview_type->tp_base->tp_as_buffer->bf_releasebuffer;
   35371             :   }
   35372             :   #elif defined(Py_bf_getbuffer) && defined(Py_bf_releasebuffer)
   35373             :   /* PY_VERSION_HEX >= 0x03090000 || Py_LIMITED_API >= 0x030B0000 */
   35374             :   #elif defined(_MSC_VER)
   35375             :   #pragma message ("The buffer protocol is not supported in the Limited C-API < 3.11.")
   35376             :   #else
   35377             :   #warning "The buffer protocol is not supported in the Limited C-API < 3.11."
   35378             :   #endif
   35379             :   if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryview_spec, __pyx_memoryview_type) < 0) __PYX_ERR(1, 337, __pyx_L1_error)
   35380             :   #else
   35381           3 :   __pyx_memoryview_type = &__pyx_type___pyx_memoryview;
   35382             :   #endif
   35383             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35384             :   #endif
   35385             :   #if !CYTHON_USE_TYPE_SPECS
   35386           3 :   if (__Pyx_PyType_Ready(__pyx_memoryview_type) < 0) __PYX_ERR(1, 337, __pyx_L1_error)
   35387             :   #endif
   35388             :   #if PY_MAJOR_VERSION < 3
   35389             :   __pyx_memoryview_type->tp_print = 0;
   35390             :   #endif
   35391             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35392           3 :   if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_memoryview_type->tp_dictoffset && __pyx_memoryview_type->tp_getattro == PyObject_GenericGetAttr)) {
   35393           3 :     __pyx_memoryview_type->tp_getattro = __Pyx_PyObject_GenericGetAttr;
   35394             :   }
   35395             :   #endif
   35396           3 :   if (__Pyx_SetVtable(__pyx_memoryview_type, __pyx_vtabptr_memoryview) < 0) __PYX_ERR(1, 337, __pyx_L1_error)
   35397             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35398           3 :   if (__Pyx_MergeVtables(__pyx_memoryview_type) < 0) __PYX_ERR(1, 337, __pyx_L1_error)
   35399             :   #endif
   35400             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35401           3 :   if (__Pyx_setup_reduce((PyObject *) __pyx_memoryview_type) < 0) __PYX_ERR(1, 337, __pyx_L1_error)
   35402             :   #endif
   35403           3 :   __pyx_vtabptr__memoryviewslice = &__pyx_vtable__memoryviewslice;
   35404           3 :   __pyx_vtable__memoryviewslice.__pyx_base = *__pyx_vtabptr_memoryview;
   35405           3 :   __pyx_vtable__memoryviewslice.__pyx_base.convert_item_to_object = (PyObject *(*)(struct __pyx_memoryview_obj *, char *))__pyx_memoryviewslice_convert_item_to_object;
   35406           3 :   __pyx_vtable__memoryviewslice.__pyx_base.assign_item_from_object = (PyObject *(*)(struct __pyx_memoryview_obj *, char *, PyObject *))__pyx_memoryviewslice_assign_item_from_object;
   35407           3 :   __pyx_vtable__memoryviewslice.__pyx_base._get_base = (PyObject *(*)(struct __pyx_memoryview_obj *))__pyx_memoryviewslice__get_base;
   35408             :   #if CYTHON_USE_TYPE_SPECS
   35409             :   __pyx_t_1 = PyTuple_Pack(1, (PyObject *)__pyx_memoryview_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 952, __pyx_L1_error)
   35410             :   __Pyx_GOTREF(__pyx_t_1);
   35411             :   __pyx_memoryviewslice_type = (PyTypeObject *) __Pyx_PyType_FromModuleAndSpec(__pyx_m, &__pyx_type___pyx_memoryviewslice_spec, __pyx_t_1);
   35412             :   __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   35413             :   if (unlikely(!__pyx_memoryviewslice_type)) __PYX_ERR(1, 952, __pyx_L1_error)
   35414             :   if (__Pyx_fix_up_extension_type_from_spec(&__pyx_type___pyx_memoryviewslice_spec, __pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 952, __pyx_L1_error)
   35415             :   #else
   35416           3 :   __pyx_memoryviewslice_type = &__pyx_type___pyx_memoryviewslice;
   35417             :   #endif
   35418             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35419           3 :   __pyx_memoryviewslice_type->tp_base = __pyx_memoryview_type;
   35420             :   #endif
   35421             :   #if !CYTHON_USE_TYPE_SPECS
   35422           3 :   if (__Pyx_PyType_Ready(__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 952, __pyx_L1_error)
   35423             :   #endif
   35424             :   #if PY_MAJOR_VERSION < 3
   35425             :   __pyx_memoryviewslice_type->tp_print = 0;
   35426             :   #endif
   35427             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35428           3 :   if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_memoryviewslice_type->tp_dictoffset && __pyx_memoryviewslice_type->tp_getattro == PyObject_GenericGetAttr)) {
   35429           3 :     __pyx_memoryviewslice_type->tp_getattro = __Pyx_PyObject_GenericGetAttr;
   35430             :   }
   35431             :   #endif
   35432           3 :   if (__Pyx_SetVtable(__pyx_memoryviewslice_type, __pyx_vtabptr__memoryviewslice) < 0) __PYX_ERR(1, 952, __pyx_L1_error)
   35433             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35434           3 :   if (__Pyx_MergeVtables(__pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 952, __pyx_L1_error)
   35435             :   #endif
   35436             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   35437           3 :   if (__Pyx_setup_reduce((PyObject *) __pyx_memoryviewslice_type) < 0) __PYX_ERR(1, 952, __pyx_L1_error)
   35438             :   #endif
   35439             :   __Pyx_RefNannyFinishContext();
   35440             :   return 0;
   35441           0 :   __pyx_L1_error:;
   35442           0 :   __Pyx_XDECREF(__pyx_t_1);
   35443           0 :   __Pyx_RefNannyFinishContext();
   35444           0 :   return -1;
   35445             : }
   35446             : 
   35447           3 : static int __Pyx_modinit_type_import_code(void) {
   35448             :   __Pyx_RefNannyDeclarations
   35449           3 :   PyObject *__pyx_t_1 = NULL;
   35450           3 :   int __pyx_lineno = 0;
   35451           3 :   const char *__pyx_filename = NULL;
   35452           3 :   int __pyx_clineno = 0;
   35453           3 :   __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0);
   35454             :   /*--- Type import code ---*/
   35455           3 :   __pyx_t_1 = PyImport_ImportModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 9, __pyx_L1_error)
   35456           3 :   __Pyx_GOTREF(__pyx_t_1);
   35457           3 :   __pyx_ptype_7cpython_4type_type = __Pyx_ImportType_3_0_11(__pyx_t_1, __Pyx_BUILTIN_MODULE_NAME, "type", 
   35458             :   #if defined(PYPY_VERSION_NUM) && PYPY_VERSION_NUM < 0x050B0000
   35459             :   sizeof(PyTypeObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyTypeObject),
   35460             :   #elif CYTHON_COMPILING_IN_LIMITED_API
   35461             :   sizeof(PyTypeObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyTypeObject),
   35462             :   #else
   35463             :   sizeof(PyHeapTypeObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyHeapTypeObject),
   35464             :   #endif
   35465           3 :   __Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_7cpython_4type_type) __PYX_ERR(3, 9, __pyx_L1_error)
   35466           3 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   35467           3 :   __pyx_t_1 = PyImport_ImportModule("numpy"); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 271, __pyx_L1_error)
   35468           3 :   __Pyx_GOTREF(__pyx_t_1);
   35469           3 :   __pyx_ptype_5numpy_dtype = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "dtype", sizeof(PyArray_Descr), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyArray_Descr),__Pyx_ImportType_CheckSize_Ignore_3_0_11); if (!__pyx_ptype_5numpy_dtype) __PYX_ERR(2, 271, __pyx_L1_error)
   35470           3 :   __pyx_ptype_5numpy_flatiter = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "flatiter", sizeof(PyArrayIterObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyArrayIterObject),__Pyx_ImportType_CheckSize_Ignore_3_0_11); if (!__pyx_ptype_5numpy_flatiter) __PYX_ERR(2, 316, __pyx_L1_error)
   35471           3 :   __pyx_ptype_5numpy_broadcast = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "broadcast", sizeof(PyArrayMultiIterObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyArrayMultiIterObject),__Pyx_ImportType_CheckSize_Ignore_3_0_11); if (!__pyx_ptype_5numpy_broadcast) __PYX_ERR(2, 320, __pyx_L1_error)
   35472           3 :   __pyx_ptype_5numpy_ndarray = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "ndarray", sizeof(PyArrayObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyArrayObject),__Pyx_ImportType_CheckSize_Ignore_3_0_11); if (!__pyx_ptype_5numpy_ndarray) __PYX_ERR(2, 359, __pyx_L1_error)
   35473           3 :   __pyx_ptype_5numpy_generic = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "generic", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_generic) __PYX_ERR(2, 847, __pyx_L1_error)
   35474           3 :   __pyx_ptype_5numpy_number = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "number", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_number) __PYX_ERR(2, 849, __pyx_L1_error)
   35475           3 :   __pyx_ptype_5numpy_integer = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "integer", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_integer) __PYX_ERR(2, 851, __pyx_L1_error)
   35476           3 :   __pyx_ptype_5numpy_signedinteger = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "signedinteger", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_signedinteger) __PYX_ERR(2, 853, __pyx_L1_error)
   35477           3 :   __pyx_ptype_5numpy_unsignedinteger = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "unsignedinteger", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_unsignedinteger) __PYX_ERR(2, 855, __pyx_L1_error)
   35478           3 :   __pyx_ptype_5numpy_inexact = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "inexact", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_inexact) __PYX_ERR(2, 857, __pyx_L1_error)
   35479           3 :   __pyx_ptype_5numpy_floating = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "floating", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_floating) __PYX_ERR(2, 859, __pyx_L1_error)
   35480           3 :   __pyx_ptype_5numpy_complexfloating = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "complexfloating", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_complexfloating) __PYX_ERR(2, 861, __pyx_L1_error)
   35481           3 :   __pyx_ptype_5numpy_flexible = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "flexible", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_flexible) __PYX_ERR(2, 863, __pyx_L1_error)
   35482           3 :   __pyx_ptype_5numpy_character = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "character", sizeof(PyObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyObject),__Pyx_ImportType_CheckSize_Warn_3_0_11); if (!__pyx_ptype_5numpy_character) __PYX_ERR(2, 865, __pyx_L1_error)
   35483           3 :   __pyx_ptype_5numpy_ufunc = __Pyx_ImportType_3_0_11(__pyx_t_1, "numpy", "ufunc", sizeof(PyUFuncObject), __PYX_GET_STRUCT_ALIGNMENT_3_0_11(PyUFuncObject),__Pyx_ImportType_CheckSize_Ignore_3_0_11); if (!__pyx_ptype_5numpy_ufunc) __PYX_ERR(2, 929, __pyx_L1_error)
   35484           3 :   __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
   35485             :   __Pyx_RefNannyFinishContext();
   35486             :   return 0;
   35487           0 :   __pyx_L1_error:;
   35488           0 :   __Pyx_XDECREF(__pyx_t_1);
   35489           0 :   __Pyx_RefNannyFinishContext();
   35490           0 :   return -1;
   35491             : }
   35492             : 
   35493             : static int __Pyx_modinit_variable_import_code(void) {
   35494             :   __Pyx_RefNannyDeclarations
   35495             :   __Pyx_RefNannySetupContext("__Pyx_modinit_variable_import_code", 0);
   35496             :   /*--- Variable import code ---*/
   35497             :   __Pyx_RefNannyFinishContext();
   35498             :   return 0;
   35499             : }
   35500             : 
   35501             : static int __Pyx_modinit_function_import_code(void) {
   35502             :   __Pyx_RefNannyDeclarations
   35503             :   __Pyx_RefNannySetupContext("__Pyx_modinit_function_import_code", 0);
   35504             :   /*--- Function import code ---*/
   35505             :   __Pyx_RefNannyFinishContext();
   35506             :   return 0;
   35507             : }
   35508             : 
   35509             : 
   35510             : #if PY_MAJOR_VERSION >= 3
   35511             : #if CYTHON_PEP489_MULTI_PHASE_INIT
   35512             : static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def); /*proto*/
   35513             : static int __pyx_pymod_exec__ni_label(PyObject* module); /*proto*/
   35514             : static PyModuleDef_Slot __pyx_moduledef_slots[] = {
   35515             :   {Py_mod_create, (void*)__pyx_pymod_create},
   35516             :   {Py_mod_exec, (void*)__pyx_pymod_exec__ni_label},
   35517             :   {0, NULL}
   35518             : };
   35519             : #endif
   35520             : 
   35521             : #ifdef __cplusplus
   35522             : namespace {
   35523             :   struct PyModuleDef __pyx_moduledef =
   35524             :   #else
   35525             :   static struct PyModuleDef __pyx_moduledef =
   35526             :   #endif
   35527             :   {
   35528             :       PyModuleDef_HEAD_INIT,
   35529             :       "_ni_label",
   35530             :       0, /* m_doc */
   35531             :     #if CYTHON_PEP489_MULTI_PHASE_INIT
   35532             :       0, /* m_size */
   35533             :     #elif CYTHON_USE_MODULE_STATE
   35534             :       sizeof(__pyx_mstate), /* m_size */
   35535             :     #else
   35536             :       -1, /* m_size */
   35537             :     #endif
   35538             :       __pyx_methods /* m_methods */,
   35539             :     #if CYTHON_PEP489_MULTI_PHASE_INIT
   35540             :       __pyx_moduledef_slots, /* m_slots */
   35541             :     #else
   35542             :       NULL, /* m_reload */
   35543             :     #endif
   35544             :     #if CYTHON_USE_MODULE_STATE
   35545             :       __pyx_m_traverse, /* m_traverse */
   35546             :       __pyx_m_clear, /* m_clear */
   35547             :       NULL /* m_free */
   35548             :     #else
   35549             :       NULL, /* m_traverse */
   35550             :       NULL, /* m_clear */
   35551             :       NULL /* m_free */
   35552             :     #endif
   35553             :   };
   35554             :   #ifdef __cplusplus
   35555             : } /* anonymous namespace */
   35556             : #endif
   35557             : #endif
   35558             : 
   35559             : #ifndef CYTHON_NO_PYINIT_EXPORT
   35560             : #define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
   35561             : #elif PY_MAJOR_VERSION < 3
   35562             : #ifdef __cplusplus
   35563             : #define __Pyx_PyMODINIT_FUNC extern "C" void
   35564             : #else
   35565             : #define __Pyx_PyMODINIT_FUNC void
   35566             : #endif
   35567             : #else
   35568             : #ifdef __cplusplus
   35569             : #define __Pyx_PyMODINIT_FUNC extern "C" PyObject *
   35570             : #else
   35571             : #define __Pyx_PyMODINIT_FUNC PyObject *
   35572             : #endif
   35573             : #endif
   35574             : 
   35575             : 
   35576             : #if PY_MAJOR_VERSION < 3
   35577             : __Pyx_PyMODINIT_FUNC init_ni_label(void) CYTHON_SMALL_CODE; /*proto*/
   35578             : __Pyx_PyMODINIT_FUNC init_ni_label(void)
   35579             : #else
   35580             : __Pyx_PyMODINIT_FUNC PyInit__ni_label(void) CYTHON_SMALL_CODE; /*proto*/
   35581           3 : __Pyx_PyMODINIT_FUNC PyInit__ni_label(void)
   35582             : #if CYTHON_PEP489_MULTI_PHASE_INIT
   35583             : {
   35584           3 :   return PyModuleDef_Init(&__pyx_moduledef);
   35585             : }
   35586           3 : static CYTHON_SMALL_CODE int __Pyx_check_single_interpreter(void) {
   35587             :     #if PY_VERSION_HEX >= 0x030700A1
   35588           3 :     static PY_INT64_T main_interpreter_id = -1;
   35589           3 :     PY_INT64_T current_id = PyInterpreterState_GetID(PyThreadState_Get()->interp);
   35590           3 :     if (main_interpreter_id == -1) {
   35591           3 :         main_interpreter_id = current_id;
   35592           6 :         return (unlikely(current_id == -1)) ? -1 : 0;
   35593           0 :     } else if (unlikely(main_interpreter_id != current_id))
   35594             :     #else
   35595             :     static PyInterpreterState *main_interpreter = NULL;
   35596             :     PyInterpreterState *current_interpreter = PyThreadState_Get()->interp;
   35597             :     if (!main_interpreter) {
   35598             :         main_interpreter = current_interpreter;
   35599             :     } else if (unlikely(main_interpreter != current_interpreter))
   35600             :     #endif
   35601             :     {
   35602           0 :         PyErr_SetString(
   35603             :             PyExc_ImportError,
   35604             :             "Interpreter change detected - this module can only be loaded into one interpreter per process.");
   35605           0 :         return -1;
   35606             :     }
   35607             :     return 0;
   35608             : }
   35609             : #if CYTHON_COMPILING_IN_LIMITED_API
   35610             : static CYTHON_SMALL_CODE int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *module, const char* from_name, const char* to_name, int allow_none)
   35611             : #else
   35612          12 : static CYTHON_SMALL_CODE int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict, const char* from_name, const char* to_name, int allow_none)
   35613             : #endif
   35614             : {
   35615          12 :     PyObject *value = PyObject_GetAttrString(spec, from_name);
   35616          12 :     int result = 0;
   35617          12 :     if (likely(value)) {
   35618          12 :         if (allow_none || value != Py_None) {
   35619             : #if CYTHON_COMPILING_IN_LIMITED_API
   35620             :             result = PyModule_AddObject(module, to_name, value);
   35621             : #else
   35622           9 :             result = PyDict_SetItemString(moddict, to_name, value);
   35623             : #endif
   35624             :         }
   35625          12 :         Py_DECREF(value);
   35626           0 :     } else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
   35627           0 :         PyErr_Clear();
   35628             :     } else {
   35629             :         result = -1;
   35630             :     }
   35631          12 :     return result;
   35632             : }
   35633           3 : static CYTHON_SMALL_CODE PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def) {
   35634           3 :     PyObject *module = NULL, *moddict, *modname;
   35635           3 :     CYTHON_UNUSED_VAR(def);
   35636           3 :     if (__Pyx_check_single_interpreter())
   35637             :         return NULL;
   35638           3 :     if (__pyx_m)
   35639           0 :         return __Pyx_NewRef(__pyx_m);
   35640           3 :     modname = PyObject_GetAttrString(spec, "name");
   35641           3 :     if (unlikely(!modname)) goto bad;
   35642           3 :     module = PyModule_NewObject(modname);
   35643           3 :     Py_DECREF(modname);
   35644           3 :     if (unlikely(!module)) goto bad;
   35645             : #if CYTHON_COMPILING_IN_LIMITED_API
   35646             :     moddict = module;
   35647             : #else
   35648           3 :     moddict = PyModule_GetDict(module);
   35649           3 :     if (unlikely(!moddict)) goto bad;
   35650             : #endif
   35651           3 :     if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "loader", "__loader__", 1) < 0)) goto bad;
   35652           3 :     if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "origin", "__file__", 1) < 0)) goto bad;
   35653           3 :     if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "parent", "__package__", 1) < 0)) goto bad;
   35654           3 :     if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "submodule_search_locations", "__path__", 0) < 0)) goto bad;
   35655             :     return module;
   35656           0 : bad:
   35657           0 :     Py_XDECREF(module);
   35658           0 :     return NULL;
   35659             : }
   35660             : 
   35661             : 
   35662           3 : static CYTHON_SMALL_CODE int __pyx_pymod_exec__ni_label(PyObject *__pyx_pyinit_module)
   35663             : #endif
   35664             : #endif
   35665             : {
   35666           3 :   int stringtab_initialized = 0;
   35667             :   #if CYTHON_USE_MODULE_STATE
   35668             :   int pystate_addmodule_run = 0;
   35669             :   #endif
   35670           3 :   PyObject *__pyx_t_1 = NULL;
   35671           3 :   PyObject *__pyx_t_2 = NULL;
   35672           3 :   PyObject *__pyx_t_3 = NULL;
   35673           3 :   PyObject *__pyx_t_4 = NULL;
   35674           3 :   PyObject *__pyx_t_5 = NULL;
   35675           3 :   int __pyx_t_6;
   35676           3 :   PyObject *__pyx_t_7 = NULL;
   35677           3 :   static PyThread_type_lock __pyx_t_8[8];
   35678           3 :   int __pyx_t_9;
   35679           3 :   PyObject *__pyx_t_10 = NULL;
   35680           3 :   int __pyx_lineno = 0;
   35681           3 :   const char *__pyx_filename = NULL;
   35682           3 :   int __pyx_clineno = 0;
   35683             :   __Pyx_RefNannyDeclarations
   35684             :   #if CYTHON_PEP489_MULTI_PHASE_INIT
   35685           3 :   if (__pyx_m) {
   35686           0 :     if (__pyx_m == __pyx_pyinit_module) return 0;
   35687           0 :     PyErr_SetString(PyExc_RuntimeError, "Module '_ni_label' has already been imported. Re-initialisation is not supported.");
   35688           0 :     return -1;
   35689             :   }
   35690             :   #elif PY_MAJOR_VERSION >= 3
   35691             :   if (__pyx_m) return __Pyx_NewRef(__pyx_m);
   35692             :   #endif
   35693             :   /*--- Module creation code ---*/
   35694             :   #if CYTHON_PEP489_MULTI_PHASE_INIT
   35695           3 :   __pyx_m = __pyx_pyinit_module;
   35696           3 :   Py_INCREF(__pyx_m);
   35697             :   #else
   35698             :   #if PY_MAJOR_VERSION < 3
   35699             :   __pyx_m = Py_InitModule4("_ni_label", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
   35700             :   if (unlikely(!__pyx_m)) __PYX_ERR(0, 1, __pyx_L1_error)
   35701             :   #elif CYTHON_USE_MODULE_STATE
   35702             :   __pyx_t_1 = PyModule_Create(&__pyx_moduledef); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1, __pyx_L1_error)
   35703             :   {
   35704             :     int add_module_result = PyState_AddModule(__pyx_t_1, &__pyx_moduledef);
   35705             :     __pyx_t_1 = 0; /* transfer ownership from __pyx_t_1 to "_ni_label" pseudovariable */
   35706             :     if (unlikely((add_module_result < 0))) __PYX_ERR(0, 1, __pyx_L1_error)
   35707             :     pystate_addmodule_run = 1;
   35708             :   }
   35709             :   #else
   35710             :   __pyx_m = PyModule_Create(&__pyx_moduledef);
   35711             :   if (unlikely(!__pyx_m)) __PYX_ERR(0, 1, __pyx_L1_error)
   35712             :   #endif
   35713             :   #endif
   35714           3 :   CYTHON_UNUSED_VAR(__pyx_t_1);
   35715           3 :   __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(0, 1, __pyx_L1_error)
   35716           3 :   Py_INCREF(__pyx_d);
   35717           3 :   __pyx_b = __Pyx_PyImport_AddModuleRef(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(0, 1, __pyx_L1_error)
   35718           3 :   __pyx_cython_runtime = __Pyx_PyImport_AddModuleRef((const char *) "cython_runtime"); if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(0, 1, __pyx_L1_error)
   35719           3 :   if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35720             :   #if CYTHON_REFNANNY
   35721             : __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
   35722             : if (!__Pyx_RefNanny) {
   35723             :   PyErr_Clear();
   35724             :   __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
   35725             :   if (!__Pyx_RefNanny)
   35726             :       Py_FatalError("failed to import 'refnanny' module");
   35727             : }
   35728             : #endif
   35729           3 :   __Pyx_RefNannySetupContext("__Pyx_PyMODINIT_FUNC PyInit__ni_label(void)", 0);
   35730           3 :   if (__Pyx_check_binary_version(__PYX_LIMITED_VERSION_HEX, __Pyx_get_runtime_version(), CYTHON_COMPILING_IN_LIMITED_API) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35731             :   #ifdef __Pxy_PyFrame_Initialize_Offsets
   35732             :   __Pxy_PyFrame_Initialize_Offsets();
   35733             :   #endif
   35734           3 :   __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(0, 1, __pyx_L1_error)
   35735           3 :   __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(0, 1, __pyx_L1_error)
   35736           3 :   __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(0, 1, __pyx_L1_error)
   35737             :   #ifdef __Pyx_CyFunction_USED
   35738           3 :   if (__pyx_CyFunction_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35739             :   #endif
   35740             :   #ifdef __Pyx_FusedFunction_USED
   35741           3 :   if (__pyx_FusedFunction_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35742             :   #endif
   35743             :   #ifdef __Pyx_Coroutine_USED
   35744             :   if (__pyx_Coroutine_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35745             :   #endif
   35746             :   #ifdef __Pyx_Generator_USED
   35747             :   if (__pyx_Generator_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35748             :   #endif
   35749             :   #ifdef __Pyx_AsyncGen_USED
   35750             :   if (__pyx_AsyncGen_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35751             :   #endif
   35752             :   #ifdef __Pyx_StopAsyncIteration_USED
   35753             :   if (__pyx_StopAsyncIteration_init(__pyx_m) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35754             :   #endif
   35755             :   /*--- Library function declarations ---*/
   35756             :   /*--- Threads initialization code ---*/
   35757             :   #if defined(WITH_THREAD) && PY_VERSION_HEX < 0x030700F0 && defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
   35758             :   PyEval_InitThreads();
   35759             :   #endif
   35760             :   /*--- Initialize various global constants etc. ---*/
   35761           3 :   if (__Pyx_InitConstants() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35762           3 :   stringtab_initialized = 1;
   35763           3 :   if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35764             :   #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
   35765             :   if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35766             :   #endif
   35767           3 :   if (__pyx_module_is_main__ni_label) {
   35768           0 :     if (PyObject_SetAttr(__pyx_m, __pyx_n_s_name_2, __pyx_n_s_main) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35769             :   }
   35770             :   #if PY_MAJOR_VERSION >= 3
   35771             :   {
   35772           3 :     PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 1, __pyx_L1_error)
   35773           3 :     if (!PyDict_GetItemString(modules, "_ni_label")) {
   35774           3 :       if (unlikely((PyDict_SetItemString(modules, "_ni_label", __pyx_m) < 0))) __PYX_ERR(0, 1, __pyx_L1_error)
   35775             :     }
   35776             :   }
   35777             :   #endif
   35778             :   /*--- Builtin init code ---*/
   35779           3 :   if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35780             :   /*--- Constants init code ---*/
   35781           3 :   if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35782             :   /*--- Global type/function init code ---*/
   35783           3 :   (void)__Pyx_modinit_global_init_code();
   35784           3 :   (void)__Pyx_modinit_variable_export_code();
   35785           3 :   (void)__Pyx_modinit_function_export_code();
   35786           3 :   if (unlikely((__Pyx_modinit_type_init_code() < 0))) __PYX_ERR(0, 1, __pyx_L1_error)
   35787           3 :   if (unlikely((__Pyx_modinit_type_import_code() < 0))) __PYX_ERR(0, 1, __pyx_L1_error)
   35788           3 :   (void)__Pyx_modinit_variable_import_code();
   35789           3 :   (void)__Pyx_modinit_function_import_code();
   35790             :   /*--- Execution code ---*/
   35791             :   #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
   35792             :   if (__Pyx_patch_abc() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   35793             :   #endif
   35794             : 
   35795             :   /* "View.MemoryView":99
   35796             :  * 
   35797             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35798             :  * try:             # <<<<<<<<<<<<<<
   35799             :  *     if __import__("sys").version_info >= (3, 3):
   35800             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35801             :  */
   35802             :   {
   35803           3 :     __Pyx_PyThreadState_declare
   35804           3 :     __Pyx_PyThreadState_assign
   35805           3 :     __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
   35806           3 :     __Pyx_XGOTREF(__pyx_t_1);
   35807           3 :     __Pyx_XGOTREF(__pyx_t_2);
   35808           3 :     __Pyx_XGOTREF(__pyx_t_3);
   35809             :     /*try:*/ {
   35810             : 
   35811             :       /* "View.MemoryView":100
   35812             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35813             :  * try:
   35814             :  *     if __import__("sys").version_info >= (3, 3):             # <<<<<<<<<<<<<<
   35815             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35816             :  *     else:
   35817             :  */
   35818           3 :       __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin___import__, __pyx_tuple__17, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 100, __pyx_L2_error)
   35819           3 :       __Pyx_GOTREF(__pyx_t_4);
   35820           3 :       __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_version_info); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 100, __pyx_L2_error)
   35821           3 :       __Pyx_GOTREF(__pyx_t_5);
   35822           3 :       __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   35823           3 :       __pyx_t_4 = PyObject_RichCompare(__pyx_t_5, __pyx_tuple__18, Py_GE); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 100, __pyx_L2_error)
   35824           3 :       __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   35825           3 :       __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely((__pyx_t_6 < 0))) __PYX_ERR(1, 100, __pyx_L2_error)
   35826           3 :       __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   35827           3 :       if (__pyx_t_6) {
   35828             : 
   35829             :         /* "View.MemoryView":101
   35830             :  * try:
   35831             :  *     if __import__("sys").version_info >= (3, 3):
   35832             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence             # <<<<<<<<<<<<<<
   35833             :  *     else:
   35834             :  *         __pyx_collections_abc_Sequence = __import__("collections").Sequence
   35835             :  */
   35836           3 :         __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin___import__, __pyx_tuple__19, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 101, __pyx_L2_error)
   35837           3 :         __Pyx_GOTREF(__pyx_t_4);
   35838           3 :         __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_abc); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 101, __pyx_L2_error)
   35839           3 :         __Pyx_GOTREF(__pyx_t_5);
   35840           3 :         __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   35841           3 :         __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_Sequence); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 101, __pyx_L2_error)
   35842           3 :         __Pyx_GOTREF(__pyx_t_4);
   35843           3 :         __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   35844           3 :         __Pyx_XGOTREF(__pyx_collections_abc_Sequence);
   35845           3 :         __Pyx_DECREF_SET(__pyx_collections_abc_Sequence, __pyx_t_4);
   35846           3 :         __Pyx_GIVEREF(__pyx_t_4);
   35847           3 :         __pyx_t_4 = 0;
   35848             : 
   35849             :         /* "View.MemoryView":100
   35850             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35851             :  * try:
   35852             :  *     if __import__("sys").version_info >= (3, 3):             # <<<<<<<<<<<<<<
   35853             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35854             :  *     else:
   35855             :  */
   35856           3 :         goto __pyx_L8;
   35857             :       }
   35858             : 
   35859             :       /* "View.MemoryView":103
   35860             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35861             :  *     else:
   35862             :  *         __pyx_collections_abc_Sequence = __import__("collections").Sequence             # <<<<<<<<<<<<<<
   35863             :  * except:
   35864             :  * 
   35865             :  */
   35866             :       /*else*/ {
   35867           0 :         __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin___import__, __pyx_tuple__20, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 103, __pyx_L2_error)
   35868           0 :         __Pyx_GOTREF(__pyx_t_4);
   35869           0 :         __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Sequence); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 103, __pyx_L2_error)
   35870           0 :         __Pyx_GOTREF(__pyx_t_5);
   35871           0 :         __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   35872           0 :         __Pyx_XGOTREF(__pyx_collections_abc_Sequence);
   35873           0 :         __Pyx_DECREF_SET(__pyx_collections_abc_Sequence, __pyx_t_5);
   35874           0 :         __Pyx_GIVEREF(__pyx_t_5);
   35875           0 :         __pyx_t_5 = 0;
   35876             :       }
   35877           3 :       __pyx_L8:;
   35878             : 
   35879             :       /* "View.MemoryView":99
   35880             :  * 
   35881             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35882             :  * try:             # <<<<<<<<<<<<<<
   35883             :  *     if __import__("sys").version_info >= (3, 3):
   35884             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35885             :  */
   35886             :     }
   35887           3 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   35888           3 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   35889           3 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   35890           3 :     goto __pyx_L7_try_end;
   35891           0 :     __pyx_L2_error:;
   35892           0 :     __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   35893           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   35894             : 
   35895             :     /* "View.MemoryView":104
   35896             :  *     else:
   35897             :  *         __pyx_collections_abc_Sequence = __import__("collections").Sequence
   35898             :  * except:             # <<<<<<<<<<<<<<
   35899             :  * 
   35900             :  *     __pyx_collections_abc_Sequence = None
   35901             :  */
   35902             :     /*except:*/ {
   35903           0 :       __Pyx_AddTraceback("View.MemoryView", __pyx_clineno, __pyx_lineno, __pyx_filename);
   35904           0 :       if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_7) < 0) __PYX_ERR(1, 104, __pyx_L4_except_error)
   35905           0 :       __Pyx_XGOTREF(__pyx_t_5);
   35906           0 :       __Pyx_XGOTREF(__pyx_t_4);
   35907           0 :       __Pyx_XGOTREF(__pyx_t_7);
   35908             : 
   35909             :       /* "View.MemoryView":106
   35910             :  * except:
   35911             :  * 
   35912             :  *     __pyx_collections_abc_Sequence = None             # <<<<<<<<<<<<<<
   35913             :  * 
   35914             :  * 
   35915             :  */
   35916           0 :       __Pyx_INCREF(Py_None);
   35917           0 :       __Pyx_XGOTREF(__pyx_collections_abc_Sequence);
   35918           0 :       __Pyx_DECREF_SET(__pyx_collections_abc_Sequence, Py_None);
   35919           0 :       __Pyx_GIVEREF(Py_None);
   35920           0 :       __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   35921           0 :       __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   35922           0 :       __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
   35923           0 :       goto __pyx_L3_exception_handled;
   35924             :     }
   35925             : 
   35926             :     /* "View.MemoryView":99
   35927             :  * 
   35928             :  * cdef object __pyx_collections_abc_Sequence "__pyx_collections_abc_Sequence"
   35929             :  * try:             # <<<<<<<<<<<<<<
   35930             :  *     if __import__("sys").version_info >= (3, 3):
   35931             :  *         __pyx_collections_abc_Sequence = __import__("collections.abc").abc.Sequence
   35932             :  */
   35933           0 :     __pyx_L4_except_error:;
   35934           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   35935           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   35936           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   35937           0 :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   35938           0 :     goto __pyx_L1_error;
   35939           0 :     __pyx_L3_exception_handled:;
   35940           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   35941           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   35942           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   35943           0 :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   35944           3 :     __pyx_L7_try_end:;
   35945             :   }
   35946             : 
   35947             :   /* "View.MemoryView":241
   35948             :  * 
   35949             :  * 
   35950             :  *     try:             # <<<<<<<<<<<<<<
   35951             :  *         count = __pyx_collections_abc_Sequence.count
   35952             :  *         index = __pyx_collections_abc_Sequence.index
   35953             :  */
   35954             :   {
   35955           3 :     __Pyx_PyThreadState_declare
   35956           3 :     __Pyx_PyThreadState_assign
   35957           3 :     __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_2, &__pyx_t_1);
   35958           3 :     __Pyx_XGOTREF(__pyx_t_3);
   35959           3 :     __Pyx_XGOTREF(__pyx_t_2);
   35960           3 :     __Pyx_XGOTREF(__pyx_t_1);
   35961             :     /*try:*/ {
   35962             : 
   35963             :       /* "View.MemoryView":242
   35964             :  * 
   35965             :  *     try:
   35966             :  *         count = __pyx_collections_abc_Sequence.count             # <<<<<<<<<<<<<<
   35967             :  *         index = __pyx_collections_abc_Sequence.index
   35968             :  *     except:
   35969             :  */
   35970           3 :       __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_count); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 242, __pyx_L11_error)
   35971           3 :       __Pyx_GOTREF(__pyx_t_7);
   35972           3 :       if (__Pyx_SetItemOnTypeDict(__pyx_array_type, __pyx_n_s_count, __pyx_t_7) < 0) __PYX_ERR(1, 242, __pyx_L11_error)
   35973           3 :       __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   35974           3 :       PyType_Modified(__pyx_array_type);
   35975             : 
   35976             :       /* "View.MemoryView":243
   35977             :  *     try:
   35978             :  *         count = __pyx_collections_abc_Sequence.count
   35979             :  *         index = __pyx_collections_abc_Sequence.index             # <<<<<<<<<<<<<<
   35980             :  *     except:
   35981             :  *         pass
   35982             :  */
   35983           3 :       __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_index); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 243, __pyx_L11_error)
   35984           3 :       __Pyx_GOTREF(__pyx_t_7);
   35985           3 :       if (__Pyx_SetItemOnTypeDict(__pyx_array_type, __pyx_n_s_index, __pyx_t_7) < 0) __PYX_ERR(1, 243, __pyx_L11_error)
   35986           3 :       __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   35987           3 :       PyType_Modified(__pyx_array_type);
   35988             : 
   35989             :       /* "View.MemoryView":241
   35990             :  * 
   35991             :  * 
   35992             :  *     try:             # <<<<<<<<<<<<<<
   35993             :  *         count = __pyx_collections_abc_Sequence.count
   35994             :  *         index = __pyx_collections_abc_Sequence.index
   35995             :  */
   35996             :     }
   35997           3 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   35998           3 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   35999           3 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   36000           3 :     goto __pyx_L16_try_end;
   36001           0 :     __pyx_L11_error:;
   36002           0 :     __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   36003           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   36004           0 :     __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
   36005             : 
   36006             :     /* "View.MemoryView":244
   36007             :  *         count = __pyx_collections_abc_Sequence.count
   36008             :  *         index = __pyx_collections_abc_Sequence.index
   36009             :  *     except:             # <<<<<<<<<<<<<<
   36010             :  *         pass
   36011             :  * 
   36012             :  */
   36013             :     /*except:*/ {
   36014           0 :       __Pyx_ErrRestore(0,0,0);
   36015           0 :       goto __pyx_L12_exception_handled;
   36016             :     }
   36017           0 :     __pyx_L12_exception_handled:;
   36018           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   36019           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   36020           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   36021           0 :     __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_2, __pyx_t_1);
   36022           3 :     __pyx_L16_try_end:;
   36023             :   }
   36024             : 
   36025             :   /* "View.MemoryView":309
   36026             :  *         return self.name
   36027             :  * 
   36028             :  * cdef generic = Enum("<strided and direct or indirect>")             # <<<<<<<<<<<<<<
   36029             :  * cdef strided = Enum("<strided and direct>") # default
   36030             :  * cdef indirect = Enum("<strided and indirect>")
   36031             :  */
   36032           3 :   __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__21, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 309, __pyx_L1_error)
   36033           3 :   __Pyx_GOTREF(__pyx_t_7);
   36034           3 :   __Pyx_XGOTREF(generic);
   36035           3 :   __Pyx_DECREF_SET(generic, __pyx_t_7);
   36036           3 :   __Pyx_GIVEREF(__pyx_t_7);
   36037           3 :   __pyx_t_7 = 0;
   36038             : 
   36039             :   /* "View.MemoryView":310
   36040             :  * 
   36041             :  * cdef generic = Enum("<strided and direct or indirect>")
   36042             :  * cdef strided = Enum("<strided and direct>") # default             # <<<<<<<<<<<<<<
   36043             :  * cdef indirect = Enum("<strided and indirect>")
   36044             :  * 
   36045             :  */
   36046           3 :   __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__22, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 310, __pyx_L1_error)
   36047           3 :   __Pyx_GOTREF(__pyx_t_7);
   36048           3 :   __Pyx_XGOTREF(strided);
   36049           3 :   __Pyx_DECREF_SET(strided, __pyx_t_7);
   36050           3 :   __Pyx_GIVEREF(__pyx_t_7);
   36051           3 :   __pyx_t_7 = 0;
   36052             : 
   36053             :   /* "View.MemoryView":311
   36054             :  * cdef generic = Enum("<strided and direct or indirect>")
   36055             :  * cdef strided = Enum("<strided and direct>") # default
   36056             :  * cdef indirect = Enum("<strided and indirect>")             # <<<<<<<<<<<<<<
   36057             :  * 
   36058             :  * 
   36059             :  */
   36060           3 :   __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__23, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 311, __pyx_L1_error)
   36061           3 :   __Pyx_GOTREF(__pyx_t_7);
   36062           3 :   __Pyx_XGOTREF(indirect);
   36063           3 :   __Pyx_DECREF_SET(indirect, __pyx_t_7);
   36064           3 :   __Pyx_GIVEREF(__pyx_t_7);
   36065           3 :   __pyx_t_7 = 0;
   36066             : 
   36067             :   /* "View.MemoryView":314
   36068             :  * 
   36069             :  * 
   36070             :  * cdef contiguous = Enum("<contiguous and direct>")             # <<<<<<<<<<<<<<
   36071             :  * cdef indirect_contiguous = Enum("<contiguous and indirect>")
   36072             :  * 
   36073             :  */
   36074           3 :   __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__24, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 314, __pyx_L1_error)
   36075           3 :   __Pyx_GOTREF(__pyx_t_7);
   36076           3 :   __Pyx_XGOTREF(contiguous);
   36077           3 :   __Pyx_DECREF_SET(contiguous, __pyx_t_7);
   36078           3 :   __Pyx_GIVEREF(__pyx_t_7);
   36079           3 :   __pyx_t_7 = 0;
   36080             : 
   36081             :   /* "View.MemoryView":315
   36082             :  * 
   36083             :  * cdef contiguous = Enum("<contiguous and direct>")
   36084             :  * cdef indirect_contiguous = Enum("<contiguous and indirect>")             # <<<<<<<<<<<<<<
   36085             :  * 
   36086             :  * 
   36087             :  */
   36088           3 :   __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__25, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 315, __pyx_L1_error)
   36089           3 :   __Pyx_GOTREF(__pyx_t_7);
   36090           3 :   __Pyx_XGOTREF(indirect_contiguous);
   36091           3 :   __Pyx_DECREF_SET(indirect_contiguous, __pyx_t_7);
   36092           3 :   __Pyx_GIVEREF(__pyx_t_7);
   36093           3 :   __pyx_t_7 = 0;
   36094             : 
   36095             :   /* "View.MemoryView":323
   36096             :  * 
   36097             :  * 
   36098             :  * cdef int __pyx_memoryview_thread_locks_used = 0             # <<<<<<<<<<<<<<
   36099             :  * cdef PyThread_type_lock[8] __pyx_memoryview_thread_locks = [
   36100             :  *     PyThread_allocate_lock(),
   36101             :  */
   36102           3 :   __pyx_memoryview_thread_locks_used = 0;
   36103             : 
   36104             :   /* "View.MemoryView":324
   36105             :  * 
   36106             :  * cdef int __pyx_memoryview_thread_locks_used = 0
   36107             :  * cdef PyThread_type_lock[8] __pyx_memoryview_thread_locks = [             # <<<<<<<<<<<<<<
   36108             :  *     PyThread_allocate_lock(),
   36109             :  *     PyThread_allocate_lock(),
   36110             :  */
   36111           3 :   __pyx_t_8[0] = PyThread_allocate_lock();
   36112           3 :   __pyx_t_8[1] = PyThread_allocate_lock();
   36113           3 :   __pyx_t_8[2] = PyThread_allocate_lock();
   36114           3 :   __pyx_t_8[3] = PyThread_allocate_lock();
   36115           3 :   __pyx_t_8[4] = PyThread_allocate_lock();
   36116           3 :   __pyx_t_8[5] = PyThread_allocate_lock();
   36117           3 :   __pyx_t_8[6] = PyThread_allocate_lock();
   36118           3 :   __pyx_t_8[7] = PyThread_allocate_lock();
   36119           3 :   memcpy(&(__pyx_memoryview_thread_locks[0]), __pyx_t_8, sizeof(__pyx_memoryview_thread_locks[0]) * (8));
   36120             : 
   36121             :   /* "View.MemoryView":982
   36122             :  * 
   36123             :  * 
   36124             :  *     try:             # <<<<<<<<<<<<<<
   36125             :  *         count = __pyx_collections_abc_Sequence.count
   36126             :  *         index = __pyx_collections_abc_Sequence.index
   36127             :  */
   36128             :   {
   36129           3 :     __Pyx_PyThreadState_declare
   36130           3 :     __Pyx_PyThreadState_assign
   36131           3 :     __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
   36132           3 :     __Pyx_XGOTREF(__pyx_t_1);
   36133           3 :     __Pyx_XGOTREF(__pyx_t_2);
   36134           3 :     __Pyx_XGOTREF(__pyx_t_3);
   36135             :     /*try:*/ {
   36136             : 
   36137             :       /* "View.MemoryView":983
   36138             :  * 
   36139             :  *     try:
   36140             :  *         count = __pyx_collections_abc_Sequence.count             # <<<<<<<<<<<<<<
   36141             :  *         index = __pyx_collections_abc_Sequence.index
   36142             :  *     except:
   36143             :  */
   36144           3 :       __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_count); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 983, __pyx_L17_error)
   36145           3 :       __Pyx_GOTREF(__pyx_t_7);
   36146           3 :       if (__Pyx_SetItemOnTypeDict(__pyx_memoryviewslice_type, __pyx_n_s_count, __pyx_t_7) < 0) __PYX_ERR(1, 983, __pyx_L17_error)
   36147           3 :       __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36148           3 :       PyType_Modified(__pyx_memoryviewslice_type);
   36149             : 
   36150             :       /* "View.MemoryView":984
   36151             :  *     try:
   36152             :  *         count = __pyx_collections_abc_Sequence.count
   36153             :  *         index = __pyx_collections_abc_Sequence.index             # <<<<<<<<<<<<<<
   36154             :  *     except:
   36155             :  *         pass
   36156             :  */
   36157           3 :       __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_index); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 984, __pyx_L17_error)
   36158           3 :       __Pyx_GOTREF(__pyx_t_7);
   36159           3 :       if (__Pyx_SetItemOnTypeDict(__pyx_memoryviewslice_type, __pyx_n_s_index, __pyx_t_7) < 0) __PYX_ERR(1, 984, __pyx_L17_error)
   36160           3 :       __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36161           3 :       PyType_Modified(__pyx_memoryviewslice_type);
   36162             : 
   36163             :       /* "View.MemoryView":982
   36164             :  * 
   36165             :  * 
   36166             :  *     try:             # <<<<<<<<<<<<<<
   36167             :  *         count = __pyx_collections_abc_Sequence.count
   36168             :  *         index = __pyx_collections_abc_Sequence.index
   36169             :  */
   36170             :     }
   36171           3 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   36172           3 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   36173           3 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   36174           3 :     goto __pyx_L22_try_end;
   36175           0 :     __pyx_L17_error:;
   36176           0 :     __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   36177           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   36178           0 :     __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
   36179             : 
   36180             :     /* "View.MemoryView":985
   36181             :  *         count = __pyx_collections_abc_Sequence.count
   36182             :  *         index = __pyx_collections_abc_Sequence.index
   36183             :  *     except:             # <<<<<<<<<<<<<<
   36184             :  *         pass
   36185             :  * 
   36186             :  */
   36187             :     /*except:*/ {
   36188           0 :       __Pyx_ErrRestore(0,0,0);
   36189           0 :       goto __pyx_L18_exception_handled;
   36190             :     }
   36191           0 :     __pyx_L18_exception_handled:;
   36192           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   36193           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   36194           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   36195           0 :     __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
   36196           3 :     __pyx_L22_try_end:;
   36197             :   }
   36198             : 
   36199             :   /* "View.MemoryView":988
   36200             :  *         pass
   36201             :  * 
   36202             :  * try:             # <<<<<<<<<<<<<<
   36203             :  *     if __pyx_collections_abc_Sequence:
   36204             :  * 
   36205             :  */
   36206             :   {
   36207           3 :     __Pyx_PyThreadState_declare
   36208           3 :     __Pyx_PyThreadState_assign
   36209           3 :     __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_2, &__pyx_t_1);
   36210           3 :     __Pyx_XGOTREF(__pyx_t_3);
   36211           3 :     __Pyx_XGOTREF(__pyx_t_2);
   36212           3 :     __Pyx_XGOTREF(__pyx_t_1);
   36213             :     /*try:*/ {
   36214             : 
   36215             :       /* "View.MemoryView":989
   36216             :  * 
   36217             :  * try:
   36218             :  *     if __pyx_collections_abc_Sequence:             # <<<<<<<<<<<<<<
   36219             :  * 
   36220             :  * 
   36221             :  */
   36222           3 :       __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_collections_abc_Sequence); if (unlikely((__pyx_t_6 < 0))) __PYX_ERR(1, 989, __pyx_L23_error)
   36223           3 :       if (__pyx_t_6) {
   36224             : 
   36225             :         /* "View.MemoryView":993
   36226             :  * 
   36227             :  * 
   36228             :  *         __pyx_collections_abc_Sequence.register(_memoryviewslice)             # <<<<<<<<<<<<<<
   36229             :  *         __pyx_collections_abc_Sequence.register(array)
   36230             :  * except:
   36231             :  */
   36232           3 :         __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_register); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 993, __pyx_L23_error)
   36233           3 :         __Pyx_GOTREF(__pyx_t_7);
   36234           3 :         __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_memoryviewslice_type)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 993, __pyx_L23_error)
   36235           3 :         __Pyx_GOTREF(__pyx_t_4);
   36236           3 :         __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36237           3 :         __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36238             : 
   36239             :         /* "View.MemoryView":994
   36240             :  * 
   36241             :  *         __pyx_collections_abc_Sequence.register(_memoryviewslice)
   36242             :  *         __pyx_collections_abc_Sequence.register(array)             # <<<<<<<<<<<<<<
   36243             :  * except:
   36244             :  *     pass  # ignore failure, it's a minor issue
   36245             :  */
   36246           3 :         __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_collections_abc_Sequence, __pyx_n_s_register); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 994, __pyx_L23_error)
   36247           3 :         __Pyx_GOTREF(__pyx_t_4);
   36248           3 :         __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_array_type)); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 994, __pyx_L23_error)
   36249           3 :         __Pyx_GOTREF(__pyx_t_7);
   36250           3 :         __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36251           6 :         __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36252             : 
   36253             :         /* "View.MemoryView":989
   36254             :  * 
   36255             :  * try:
   36256             :  *     if __pyx_collections_abc_Sequence:             # <<<<<<<<<<<<<<
   36257             :  * 
   36258             :  * 
   36259             :  */
   36260             :       }
   36261             : 
   36262             :       /* "View.MemoryView":988
   36263             :  *         pass
   36264             :  * 
   36265             :  * try:             # <<<<<<<<<<<<<<
   36266             :  *     if __pyx_collections_abc_Sequence:
   36267             :  * 
   36268             :  */
   36269             :     }
   36270           3 :     __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
   36271           3 :     __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
   36272           3 :     __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
   36273           3 :     goto __pyx_L28_try_end;
   36274           0 :     __pyx_L23_error:;
   36275           0 :     __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
   36276           0 :     __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
   36277           0 :     __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
   36278             : 
   36279             :     /* "View.MemoryView":995
   36280             :  *         __pyx_collections_abc_Sequence.register(_memoryviewslice)
   36281             :  *         __pyx_collections_abc_Sequence.register(array)
   36282             :  * except:             # <<<<<<<<<<<<<<
   36283             :  *     pass  # ignore failure, it's a minor issue
   36284             :  * 
   36285             :  */
   36286             :     /*except:*/ {
   36287           0 :       __Pyx_ErrRestore(0,0,0);
   36288           0 :       goto __pyx_L24_exception_handled;
   36289             :     }
   36290           0 :     __pyx_L24_exception_handled:;
   36291           0 :     __Pyx_XGIVEREF(__pyx_t_3);
   36292           0 :     __Pyx_XGIVEREF(__pyx_t_2);
   36293           0 :     __Pyx_XGIVEREF(__pyx_t_1);
   36294           0 :     __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_2, __pyx_t_1);
   36295           3 :     __pyx_L28_try_end:;
   36296             :   }
   36297             : 
   36298             :   /* "(tree fragment)":1
   36299             :  * def __pyx_unpickle_Enum(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
   36300             :  *     cdef object __pyx_PickleError
   36301             :  *     cdef object __pyx_result
   36302             :  */
   36303           3 :   __pyx_t_7 = PyCFunction_NewEx(&__pyx_mdef_15View_dot_MemoryView_1__pyx_unpickle_Enum, NULL, __pyx_n_s_View_MemoryView); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 1, __pyx_L1_error)
   36304           3 :   __Pyx_GOTREF(__pyx_t_7);
   36305           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Enum, __pyx_t_7) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
   36306           3 :   __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36307             : 
   36308             :   /* "_ni_label.pyx":6
   36309             :  * ######################################################################
   36310             :  * 
   36311             :  * import numpy as np             # <<<<<<<<<<<<<<
   36312             :  * cimport numpy as np
   36313             :  * 
   36314             :  */
   36315           3 :   __pyx_t_7 = __Pyx_ImportDottedModule(__pyx_n_s_numpy, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 6, __pyx_L1_error)
   36316           3 :   __Pyx_GOTREF(__pyx_t_7);
   36317           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_np, __pyx_t_7) < 0) __PYX_ERR(0, 6, __pyx_L1_error)
   36318           3 :   __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36319             : 
   36320             :   /* "_ni_label.pyx":9
   36321             :  * cimport numpy as np
   36322             :  * 
   36323             :  * np.import_array()             # <<<<<<<<<<<<<<
   36324             :  * 
   36325             :  * cdef extern from *:
   36326             :  */
   36327           3 :   __pyx_t_9 = __pyx_f_5numpy_import_array(); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 9, __pyx_L1_error)
   36328             : 
   36329             :   /* "_ni_label.pyx":31
   36330             :  *     void *PyDataMem_RENEW(void *, size_t)
   36331             :  * 
   36332             :  * class NeedMoreBits(Exception):             # <<<<<<<<<<<<<<
   36333             :  *     pass
   36334             :  * 
   36335             :  */
   36336           3 :   __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 31, __pyx_L1_error)
   36337           3 :   __Pyx_GOTREF(__pyx_t_7);
   36338           3 :   __Pyx_INCREF((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0]));
   36339           3 :   __Pyx_GIVEREF((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0]));
   36340           3 :   if (__Pyx_PyTuple_SET_ITEM(__pyx_t_7, 0, ((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])))) __PYX_ERR(0, 31, __pyx_L1_error);
   36341           3 :   __pyx_t_4 = __Pyx_PEP560_update_bases(__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 31, __pyx_L1_error)
   36342           3 :   __Pyx_GOTREF(__pyx_t_4);
   36343           3 :   __pyx_t_5 = __Pyx_CalculateMetaclass(NULL, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 31, __pyx_L1_error)
   36344           3 :   __Pyx_GOTREF(__pyx_t_5);
   36345           3 :   __pyx_t_10 = __Pyx_Py3MetaclassPrepare(__pyx_t_5, __pyx_t_4, __pyx_n_s_NeedMoreBits, __pyx_n_s_NeedMoreBits, (PyObject *) NULL, __pyx_n_s_ni_label, (PyObject *) NULL); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 31, __pyx_L1_error)
   36346           3 :   __Pyx_GOTREF(__pyx_t_10);
   36347           3 :   if (__pyx_t_4 != __pyx_t_7) {
   36348           0 :     if (unlikely((PyDict_SetItemString(__pyx_t_10, "__orig_bases__", __pyx_t_7) < 0))) __PYX_ERR(0, 31, __pyx_L1_error)
   36349             :   }
   36350           3 :   __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36351           3 :   __pyx_t_7 = __Pyx_Py3ClassCreate(__pyx_t_5, __pyx_n_s_NeedMoreBits, __pyx_t_4, __pyx_t_10, NULL, 0, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 31, __pyx_L1_error)
   36352           3 :   __Pyx_GOTREF(__pyx_t_7);
   36353           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_NeedMoreBits, __pyx_t_7) < 0) __PYX_ERR(0, 31, __pyx_L1_error)
   36354           3 :   __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
   36355           3 :   __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
   36356           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36357           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36358             : 
   36359             :   /* "_ni_label.pyx":93
   36360             :  * # Function specializers
   36361             :  * ######################################################################
   36362             :  * def get_nonzero_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   36363             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   36364             :  * 
   36365             :  */
   36366           3 :   __pyx_t_4 = __Pyx_PyDict_NewPresized(10); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 93, __pyx_L1_error)
   36367           3 :   __Pyx_GOTREF(__pyx_t_4);
   36368           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_0__pyx_mdef_9_ni_label_9get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36369           3 :   __Pyx_GOTREF(__pyx_t_5);
   36370           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36371           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int8_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36372           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36373           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_1__pyx_mdef_9_ni_label_11get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36374           3 :   __Pyx_GOTREF(__pyx_t_5);
   36375           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36376           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int16_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36377           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36378           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_2__pyx_mdef_9_ni_label_13get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36379           3 :   __Pyx_GOTREF(__pyx_t_5);
   36380           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36381           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int32_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36382           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36383           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_3__pyx_mdef_9_ni_label_15get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36384           3 :   __Pyx_GOTREF(__pyx_t_5);
   36385           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36386           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int64_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36387           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36388           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_4__pyx_mdef_9_ni_label_17get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36389           3 :   __Pyx_GOTREF(__pyx_t_5);
   36390           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36391           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint8_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36392           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36393           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_5__pyx_mdef_9_ni_label_19get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36394           3 :   __Pyx_GOTREF(__pyx_t_5);
   36395           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36396           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint16_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36397           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36398           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_6__pyx_mdef_9_ni_label_21get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36399           3 :   __Pyx_GOTREF(__pyx_t_5);
   36400           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36401           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint32_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36402           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36403           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_7__pyx_mdef_9_ni_label_23get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36404           3 :   __Pyx_GOTREF(__pyx_t_5);
   36405           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36406           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint64_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36407           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36408           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_8__pyx_mdef_9_ni_label_25get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36409           3 :   __Pyx_GOTREF(__pyx_t_5);
   36410           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36411           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_float32_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36412           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36413           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_9__pyx_mdef_9_ni_label_27get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36414           3 :   __Pyx_GOTREF(__pyx_t_5);
   36415           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36416           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_float64_t, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36417           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36418           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_mdef_9_ni_label_1get_nonzero_line, 0, __pyx_n_s_get_nonzero_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__29)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 93, __pyx_L1_error)
   36419           3 :   __Pyx_GOTREF(__pyx_t_5);
   36420           3 :   if (!__Pyx_CyFunction_InitDefaults(__pyx_t_5, sizeof(__pyx_defaults), 1)) __PYX_ERR(0, 93, __pyx_L1_error)
   36421           3 :   __pyx_t_10 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 93, __pyx_L1_error)
   36422           3 :   __Pyx_GOTREF(__pyx_t_10);
   36423           3 :   __Pyx_CyFunction_Defaults(__pyx_defaults, __pyx_t_5)->__pyx_arg__fused_sigindex = __pyx_t_10;
   36424           3 :   __Pyx_GIVEREF(__pyx_t_10);
   36425           3 :   __pyx_t_10 = 0;
   36426           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36427           3 :   ((__pyx_FusedFunctionObject *) __pyx_t_5)->__signatures__ = __pyx_t_4;
   36428           3 :   __Pyx_GIVEREF(__pyx_t_4);
   36429           3 :   __pyx_t_4 = 0;
   36430           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_nonzero_line, __pyx_t_5) < 0) __PYX_ERR(0, 93, __pyx_L1_error)
   36431           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36432             : 
   36433             :   /* "_ni_label.pyx":96
   36434             :  *     return <Py_intptr_t> fused_nonzero_line[data_t]
   36435             :  * 
   36436             :  * def get_read_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   36437             :  *     return <Py_intptr_t> fused_read_line[data_t]
   36438             :  * 
   36439             :  */
   36440           3 :   __pyx_t_5 = __Pyx_PyDict_NewPresized(10); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 96, __pyx_L1_error)
   36441           3 :   __Pyx_GOTREF(__pyx_t_5);
   36442           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_0__pyx_mdef_9_ni_label_31get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36443           3 :   __Pyx_GOTREF(__pyx_t_4);
   36444           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36445           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_int8_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36446           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36447           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_1__pyx_mdef_9_ni_label_33get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36448           3 :   __Pyx_GOTREF(__pyx_t_4);
   36449           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36450           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_int16_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36451           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36452           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_2__pyx_mdef_9_ni_label_35get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36453           3 :   __Pyx_GOTREF(__pyx_t_4);
   36454           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36455           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_int32_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36456           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36457           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_3__pyx_mdef_9_ni_label_37get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36458           3 :   __Pyx_GOTREF(__pyx_t_4);
   36459           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36460           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_int64_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36461           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36462           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_4__pyx_mdef_9_ni_label_39get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36463           3 :   __Pyx_GOTREF(__pyx_t_4);
   36464           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36465           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_uint8_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36466           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36467           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_5__pyx_mdef_9_ni_label_41get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36468           3 :   __Pyx_GOTREF(__pyx_t_4);
   36469           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36470           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_uint16_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36471           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36472           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_6__pyx_mdef_9_ni_label_43get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36473           3 :   __Pyx_GOTREF(__pyx_t_4);
   36474           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36475           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_uint32_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36476           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36477           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_7__pyx_mdef_9_ni_label_45get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36478           3 :   __Pyx_GOTREF(__pyx_t_4);
   36479           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36480           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_uint64_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36481           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36482           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_8__pyx_mdef_9_ni_label_47get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36483           3 :   __Pyx_GOTREF(__pyx_t_4);
   36484           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36485           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_float32_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36486           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36487           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_fuse_9__pyx_mdef_9_ni_label_49get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36488           3 :   __Pyx_GOTREF(__pyx_t_4);
   36489           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36490           3 :   if (PyDict_SetItem(__pyx_t_5, __pyx_n_s_float64_t, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36491           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36492           3 :   __pyx_t_4 = __pyx_FusedFunction_New(&__pyx_mdef_9_ni_label_3get_read_line, 0, __pyx_n_s_get_read_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__30)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
   36493           3 :   __Pyx_GOTREF(__pyx_t_4);
   36494           3 :   if (!__Pyx_CyFunction_InitDefaults(__pyx_t_4, sizeof(__pyx_defaults1), 1)) __PYX_ERR(0, 96, __pyx_L1_error)
   36495           3 :   __pyx_t_10 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 96, __pyx_L1_error)
   36496           3 :   __Pyx_GOTREF(__pyx_t_10);
   36497           3 :   __Pyx_CyFunction_Defaults(__pyx_defaults1, __pyx_t_4)->__pyx_arg__fused_sigindex = __pyx_t_10;
   36498           3 :   __Pyx_GIVEREF(__pyx_t_10);
   36499           3 :   __pyx_t_10 = 0;
   36500           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_4, __pyx_empty_tuple);
   36501           3 :   ((__pyx_FusedFunctionObject *) __pyx_t_4)->__signatures__ = __pyx_t_5;
   36502           3 :   __Pyx_GIVEREF(__pyx_t_5);
   36503           3 :   __pyx_t_5 = 0;
   36504           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_read_line, __pyx_t_4) < 0) __PYX_ERR(0, 96, __pyx_L1_error)
   36505           3 :   __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
   36506             : 
   36507             :   /* "_ni_label.pyx":99
   36508             :  *     return <Py_intptr_t> fused_read_line[data_t]
   36509             :  * 
   36510             :  * def get_write_line(np.ndarray[data_t] a):             # <<<<<<<<<<<<<<
   36511             :  *     return <Py_intptr_t> fused_write_line[data_t]
   36512             :  * 
   36513             :  */
   36514           3 :   __pyx_t_4 = __Pyx_PyDict_NewPresized(10); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 99, __pyx_L1_error)
   36515           3 :   __Pyx_GOTREF(__pyx_t_4);
   36516           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_0__pyx_mdef_9_ni_label_53get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36517           3 :   __Pyx_GOTREF(__pyx_t_5);
   36518           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36519           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int8_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36520           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36521           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_1__pyx_mdef_9_ni_label_55get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36522           3 :   __Pyx_GOTREF(__pyx_t_5);
   36523           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36524           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int16_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36525           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36526           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_2__pyx_mdef_9_ni_label_57get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36527           3 :   __Pyx_GOTREF(__pyx_t_5);
   36528           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36529           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int32_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36530           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36531           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_3__pyx_mdef_9_ni_label_59get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36532           3 :   __Pyx_GOTREF(__pyx_t_5);
   36533           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36534           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_int64_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36535           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36536           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_4__pyx_mdef_9_ni_label_61get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36537           3 :   __Pyx_GOTREF(__pyx_t_5);
   36538           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36539           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint8_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36540           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36541           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_5__pyx_mdef_9_ni_label_63get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36542           3 :   __Pyx_GOTREF(__pyx_t_5);
   36543           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36544           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint16_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36545           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36546           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_6__pyx_mdef_9_ni_label_65get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36547           3 :   __Pyx_GOTREF(__pyx_t_5);
   36548           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36549           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint32_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36550           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36551           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_7__pyx_mdef_9_ni_label_67get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36552           3 :   __Pyx_GOTREF(__pyx_t_5);
   36553           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36554           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_uint64_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36555           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36556           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_8__pyx_mdef_9_ni_label_69get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36557           3 :   __Pyx_GOTREF(__pyx_t_5);
   36558           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36559           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_float32_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36560           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36561           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_fuse_9__pyx_mdef_9_ni_label_71get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36562           3 :   __Pyx_GOTREF(__pyx_t_5);
   36563           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36564           3 :   if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_float64_t, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36565           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36566           3 :   __pyx_t_5 = __pyx_FusedFunction_New(&__pyx_mdef_9_ni_label_5get_write_line, 0, __pyx_n_s_get_write_line, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__31)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 99, __pyx_L1_error)
   36567           3 :   __Pyx_GOTREF(__pyx_t_5);
   36568           3 :   if (!__Pyx_CyFunction_InitDefaults(__pyx_t_5, sizeof(__pyx_defaults2), 1)) __PYX_ERR(0, 99, __pyx_L1_error)
   36569           3 :   __pyx_t_10 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 99, __pyx_L1_error)
   36570           3 :   __Pyx_GOTREF(__pyx_t_10);
   36571           3 :   __Pyx_CyFunction_Defaults(__pyx_defaults2, __pyx_t_5)->__pyx_arg__fused_sigindex = __pyx_t_10;
   36572           3 :   __Pyx_GIVEREF(__pyx_t_10);
   36573           3 :   __pyx_t_10 = 0;
   36574           6 :   __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_5, __pyx_empty_tuple);
   36575           3 :   ((__pyx_FusedFunctionObject *) __pyx_t_5)->__signatures__ = __pyx_t_4;
   36576           3 :   __Pyx_GIVEREF(__pyx_t_4);
   36577           3 :   __pyx_t_4 = 0;
   36578           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_write_line, __pyx_t_5) < 0) __PYX_ERR(0, 99, __pyx_L1_error)
   36579           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36580             : 
   36581             :   /* "_ni_label.pyx":200
   36582             :  * # Label regions
   36583             :  * ######################################################################
   36584             :  * cpdef _label(np.ndarray input,             # <<<<<<<<<<<<<<
   36585             :  *              np.ndarray structure,
   36586             :  *              np.ndarray output):
   36587             :  */
   36588           3 :   __pyx_t_5 = __Pyx_CyFunction_New(&__pyx_mdef_9_ni_label_7_label, 0, __pyx_n_s_label, NULL, __pyx_n_s_ni_label, __pyx_d, ((PyObject *)__pyx_codeobj__33)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 200, __pyx_L1_error)
   36589           3 :   __Pyx_GOTREF(__pyx_t_5);
   36590           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_label, __pyx_t_5) < 0) __PYX_ERR(0, 200, __pyx_L1_error)
   36591           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36592             : 
   36593             :   /* "_ni_label.pyx":1
   36594             :  * ######################################################################             # <<<<<<<<<<<<<<
   36595             :  * # Cython version of scipy.ndimage.measurements.label().
   36596             :  * # Requires Cython version 0.17 or greater due to type templating.
   36597             :  */
   36598           3 :   __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1, __pyx_L1_error)
   36599           3 :   __Pyx_GOTREF(__pyx_t_5);
   36600           3 :   if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_5) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
   36601           3 :   __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
   36602             : 
   36603             :   /*--- Wrapped vars code ---*/
   36604             : 
   36605           3 :   goto __pyx_L0;
   36606           0 :   __pyx_L1_error:;
   36607           0 :   __Pyx_XDECREF(__pyx_t_4);
   36608           0 :   __Pyx_XDECREF(__pyx_t_5);
   36609           0 :   __Pyx_XDECREF(__pyx_t_7);
   36610           0 :   __Pyx_XDECREF(__pyx_t_10);
   36611           0 :   if (__pyx_m) {
   36612           0 :     if (__pyx_d && stringtab_initialized) {
   36613           0 :       __Pyx_AddTraceback("init _ni_label", __pyx_clineno, __pyx_lineno, __pyx_filename);
   36614             :     }
   36615             :     #if !CYTHON_USE_MODULE_STATE
   36616           0 :     Py_CLEAR(__pyx_m);
   36617             :     #else
   36618             :     Py_DECREF(__pyx_m);
   36619             :     if (pystate_addmodule_run) {
   36620             :       PyObject *tp, *value, *tb;
   36621             :       PyErr_Fetch(&tp, &value, &tb);
   36622             :       PyState_RemoveModule(&__pyx_moduledef);
   36623             :       PyErr_Restore(tp, value, tb);
   36624             :     }
   36625             :     #endif
   36626           0 :   } else if (!PyErr_Occurred()) {
   36627           0 :     PyErr_SetString(PyExc_ImportError, "init _ni_label");
   36628             :   }
   36629           0 :   __pyx_L0:;
   36630           3 :   __Pyx_RefNannyFinishContext();
   36631             :   #if CYTHON_PEP489_MULTI_PHASE_INIT
   36632           3 :   return (__pyx_m != NULL) ? 0 : -1;
   36633             :   #elif PY_MAJOR_VERSION >= 3
   36634             :   return __pyx_m;
   36635             :   #else
   36636             :   return;
   36637             :   #endif
   36638             : }
   36639             : /* #### Code section: cleanup_globals ### */
   36640             : /* #### Code section: cleanup_module ### */
   36641             : /* #### Code section: main_method ### */
   36642             : /* #### Code section: utility_code_pragmas ### */
   36643             : #ifdef _MSC_VER
   36644             : #pragma warning( push )
   36645             : /* Warning 4127: conditional expression is constant
   36646             :  * Cython uses constant conditional expressions to allow in inline functions to be optimized at
   36647             :  * compile-time, so this warning is not useful
   36648             :  */
   36649             : #pragma warning( disable : 4127 )
   36650             : #endif
   36651             : 
   36652             : 
   36653             : 
   36654             : /* #### Code section: utility_code_def ### */
   36655             : 
   36656             : /* --- Runtime support code --- */
   36657             : /* Refnanny */
   36658             : #if CYTHON_REFNANNY
   36659             : static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
   36660             :     PyObject *m = NULL, *p = NULL;
   36661             :     void *r = NULL;
   36662             :     m = PyImport_ImportModule(modname);
   36663             :     if (!m) goto end;
   36664             :     p = PyObject_GetAttrString(m, "RefNannyAPI");
   36665             :     if (!p) goto end;
   36666             :     r = PyLong_AsVoidPtr(p);
   36667             : end:
   36668             :     Py_XDECREF(p);
   36669             :     Py_XDECREF(m);
   36670             :     return (__Pyx_RefNannyAPIStruct *)r;
   36671             : }
   36672             : #endif
   36673             : 
   36674             : /* PyErrExceptionMatches */
   36675             : #if CYTHON_FAST_THREAD_STATE
   36676           0 : static int __Pyx_PyErr_ExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
   36677           0 :     Py_ssize_t i, n;
   36678           0 :     n = PyTuple_GET_SIZE(tuple);
   36679             : #if PY_MAJOR_VERSION >= 3
   36680           0 :     for (i=0; i<n; i++) {
   36681           0 :         if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
   36682             :     }
   36683             : #endif
   36684           0 :     for (i=0; i<n; i++) {
   36685           0 :         if (__Pyx_PyErr_GivenExceptionMatches(exc_type, PyTuple_GET_ITEM(tuple, i))) return 1;
   36686             :     }
   36687             :     return 0;
   36688             : }
   36689           9 : static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) {
   36690           9 :     int result;
   36691           9 :     PyObject *exc_type;
   36692             : #if PY_VERSION_HEX >= 0x030C00A6
   36693           9 :     PyObject *current_exception = tstate->current_exception;
   36694           9 :     if (unlikely(!current_exception)) return 0;
   36695           9 :     exc_type = (PyObject*) Py_TYPE(current_exception);
   36696           9 :     if (exc_type == err) return 1;
   36697             : #else
   36698             :     exc_type = tstate->curexc_type;
   36699             :     if (exc_type == err) return 1;
   36700             :     if (unlikely(!exc_type)) return 0;
   36701             : #endif
   36702             :     #if CYTHON_AVOID_BORROWED_REFS
   36703             :     Py_INCREF(exc_type);
   36704             :     #endif
   36705           0 :     if (unlikely(PyTuple_Check(err))) {
   36706           0 :         result = __Pyx_PyErr_ExceptionMatchesTuple(exc_type, err);
   36707             :     } else {
   36708           0 :         result = __Pyx_PyErr_GivenExceptionMatches(exc_type, err);
   36709             :     }
   36710             :     #if CYTHON_AVOID_BORROWED_REFS
   36711             :     Py_DECREF(exc_type);
   36712             :     #endif
   36713             :     return result;
   36714             : }
   36715             : #endif
   36716             : 
   36717             : /* PyErrFetchRestore */
   36718             : #if CYTHON_FAST_THREAD_STATE
   36719           9 : static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
   36720             : #if PY_VERSION_HEX >= 0x030C00A6
   36721           9 :     PyObject *tmp_value;
   36722           9 :     assert(type == NULL || (value != NULL && type == (PyObject*) Py_TYPE(value)));
   36723           9 :     if (value) {
   36724             :         #if CYTHON_COMPILING_IN_CPYTHON
   36725           0 :         if (unlikely(((PyBaseExceptionObject*) value)->traceback != tb))
   36726             :         #endif
   36727           0 :             PyException_SetTraceback(value, tb);
   36728             :     }
   36729           9 :     tmp_value = tstate->current_exception;
   36730           9 :     tstate->current_exception = value;
   36731           9 :     Py_XDECREF(tmp_value);
   36732           9 :     Py_XDECREF(type);
   36733           9 :     Py_XDECREF(tb);
   36734             : #else
   36735             :     PyObject *tmp_type, *tmp_value, *tmp_tb;
   36736             :     tmp_type = tstate->curexc_type;
   36737             :     tmp_value = tstate->curexc_value;
   36738             :     tmp_tb = tstate->curexc_traceback;
   36739             :     tstate->curexc_type = type;
   36740             :     tstate->curexc_value = value;
   36741             :     tstate->curexc_traceback = tb;
   36742             :     Py_XDECREF(tmp_type);
   36743             :     Py_XDECREF(tmp_value);
   36744             :     Py_XDECREF(tmp_tb);
   36745             : #endif
   36746           9 : }
   36747           0 : static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
   36748             : #if PY_VERSION_HEX >= 0x030C00A6
   36749           0 :     PyObject* exc_value;
   36750           0 :     exc_value = tstate->current_exception;
   36751           0 :     tstate->current_exception = 0;
   36752           0 :     *value = exc_value;
   36753           0 :     *type = NULL;
   36754           0 :     *tb = NULL;
   36755           0 :     if (exc_value) {
   36756           0 :         *type = (PyObject*) Py_TYPE(exc_value);
   36757           0 :         Py_INCREF(*type);
   36758             :         #if CYTHON_COMPILING_IN_CPYTHON
   36759           0 :         *tb = ((PyBaseExceptionObject*) exc_value)->traceback;
   36760           0 :         Py_XINCREF(*tb);
   36761             :         #else
   36762             :         *tb = PyException_GetTraceback(exc_value);
   36763             :         #endif
   36764             :     }
   36765             : #else
   36766             :     *type = tstate->curexc_type;
   36767             :     *value = tstate->curexc_value;
   36768             :     *tb = tstate->curexc_traceback;
   36769             :     tstate->curexc_type = 0;
   36770             :     tstate->curexc_value = 0;
   36771             :     tstate->curexc_traceback = 0;
   36772             : #endif
   36773           0 : }
   36774             : #endif
   36775             : 
   36776             : /* PyObjectGetAttrStr */
   36777             : #if CYTHON_USE_TYPE_SLOTS
   36778        3939 : static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
   36779        3939 :     PyTypeObject* tp = Py_TYPE(obj);
   36780        3939 :     if (likely(tp->tp_getattro))
   36781        3939 :         return tp->tp_getattro(obj, attr_name);
   36782             : #if PY_MAJOR_VERSION < 3
   36783             :     if (likely(tp->tp_getattr))
   36784             :         return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
   36785             : #endif
   36786           0 :     return PyObject_GetAttr(obj, attr_name);
   36787             : }
   36788             : #endif
   36789             : 
   36790             : /* PyObjectGetAttrStrNoError */
   36791             : #if __PYX_LIMITED_VERSION_HEX < 0x030d00A1
   36792           9 : static void __Pyx_PyObject_GetAttrStr_ClearAttributeError(void) {
   36793           9 :     __Pyx_PyThreadState_declare
   36794           9 :     __Pyx_PyThreadState_assign
   36795           9 :     if (likely(__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
   36796           9 :         __Pyx_PyErr_Clear();
   36797           9 : }
   36798             : #endif
   36799          84 : static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name) {
   36800          84 :     PyObject *result;
   36801             : #if __PYX_LIMITED_VERSION_HEX >= 0x030d00A1
   36802             :     (void) PyObject_GetOptionalAttr(obj, attr_name, &result);
   36803             :     return result;
   36804             : #else
   36805             : #if CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_TYPE_SLOTS && PY_VERSION_HEX >= 0x030700B1
   36806          84 :     PyTypeObject* tp = Py_TYPE(obj);
   36807          84 :     if (likely(tp->tp_getattro == PyObject_GenericGetAttr)) {
   36808           9 :         return _PyObject_GenericGetAttrWithDict(obj, attr_name, NULL, 1);
   36809             :     }
   36810             : #endif
   36811          75 :     result = __Pyx_PyObject_GetAttrStr(obj, attr_name);
   36812          75 :     if (unlikely(!result)) {
   36813           9 :         __Pyx_PyObject_GetAttrStr_ClearAttributeError();
   36814             :     }
   36815             :     return result;
   36816             : #endif
   36817             : }
   36818             : 
   36819             : /* GetBuiltinName */
   36820          33 : static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
   36821          33 :     PyObject* result = __Pyx_PyObject_GetAttrStrNoError(__pyx_b, name);
   36822          33 :     if (unlikely(!result) && !PyErr_Occurred()) {
   36823           0 :         PyErr_Format(PyExc_NameError,
   36824             : #if PY_MAJOR_VERSION >= 3
   36825             :             "name '%U' is not defined", name);
   36826             : #else
   36827             :             "name '%.200s' is not defined", PyString_AS_STRING(name));
   36828             : #endif
   36829             :     }
   36830          33 :     return result;
   36831             : }
   36832             : 
   36833             : /* TupleAndListFromArray */
   36834             : #if CYTHON_COMPILING_IN_CPYTHON
   36835             : static CYTHON_INLINE void __Pyx_copy_object_array(PyObject *const *CYTHON_RESTRICT src, PyObject** CYTHON_RESTRICT dest, Py_ssize_t length) {
   36836             :     PyObject *v;
   36837             :     Py_ssize_t i;
   36838             :     for (i = 0; i < length; i++) {
   36839             :         v = dest[i] = src[i];
   36840             :         Py_INCREF(v);
   36841             :     }
   36842             : }
   36843             : static CYTHON_INLINE PyObject *
   36844             : __Pyx_PyTuple_FromArray(PyObject *const *src, Py_ssize_t n)
   36845             : {
   36846             :     PyObject *res;
   36847             :     if (n <= 0) {
   36848             :         Py_INCREF(__pyx_empty_tuple);
   36849             :         return __pyx_empty_tuple;
   36850             :     }
   36851             :     res = PyTuple_New(n);
   36852             :     if (unlikely(res == NULL)) return NULL;
   36853             :     __Pyx_copy_object_array(src, ((PyTupleObject*)res)->ob_item, n);
   36854             :     return res;
   36855             : }
   36856             : static CYTHON_INLINE PyObject *
   36857             : __Pyx_PyList_FromArray(PyObject *const *src, Py_ssize_t n)
   36858             : {
   36859             :     PyObject *res;
   36860             :     if (n <= 0) {
   36861             :         return PyList_New(0);
   36862             :     }
   36863             :     res = PyList_New(n);
   36864             :     if (unlikely(res == NULL)) return NULL;
   36865             :     __Pyx_copy_object_array(src, ((PyListObject*)res)->ob_item, n);
   36866             :     return res;
   36867             : }
   36868             : #endif
   36869             : 
   36870             : /* BytesEquals */
   36871             : static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals) {
   36872             : #if CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API
   36873             :     return PyObject_RichCompareBool(s1, s2, equals);
   36874             : #else
   36875             :     if (s1 == s2) {
   36876             :         return (equals == Py_EQ);
   36877             :     } else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) {
   36878             :         const char *ps1, *ps2;
   36879             :         Py_ssize_t length = PyBytes_GET_SIZE(s1);
   36880             :         if (length != PyBytes_GET_SIZE(s2))
   36881             :             return (equals == Py_NE);
   36882             :         ps1 = PyBytes_AS_STRING(s1);
   36883             :         ps2 = PyBytes_AS_STRING(s2);
   36884             :         if (ps1[0] != ps2[0]) {
   36885             :             return (equals == Py_NE);
   36886             :         } else if (length == 1) {
   36887             :             return (equals == Py_EQ);
   36888             :         } else {
   36889             :             int result;
   36890             : #if CYTHON_USE_UNICODE_INTERNALS && (PY_VERSION_HEX < 0x030B0000)
   36891             :             Py_hash_t hash1, hash2;
   36892             :             hash1 = ((PyBytesObject*)s1)->ob_shash;
   36893             :             hash2 = ((PyBytesObject*)s2)->ob_shash;
   36894             :             if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
   36895             :                 return (equals == Py_NE);
   36896             :             }
   36897             : #endif
   36898             :             result = memcmp(ps1, ps2, (size_t)length);
   36899             :             return (equals == Py_EQ) ? (result == 0) : (result != 0);
   36900             :         }
   36901             :     } else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
   36902             :         return (equals == Py_NE);
   36903             :     } else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) {
   36904             :         return (equals == Py_NE);
   36905             :     } else {
   36906             :         int result;
   36907             :         PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
   36908             :         if (!py_result)
   36909             :             return -1;
   36910             :         result = __Pyx_PyObject_IsTrue(py_result);
   36911             :         Py_DECREF(py_result);
   36912             :         return result;
   36913             :     }
   36914             : #endif
   36915             : }
   36916             : 
   36917             : /* UnicodeEquals */
   36918           0 : static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
   36919             : #if CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API
   36920             :     return PyObject_RichCompareBool(s1, s2, equals);
   36921             : #else
   36922             : #if PY_MAJOR_VERSION < 3
   36923             :     PyObject* owned_ref = NULL;
   36924             : #endif
   36925           0 :     int s1_is_unicode, s2_is_unicode;
   36926           0 :     if (s1 == s2) {
   36927           0 :         goto return_eq;
   36928             :     }
   36929           0 :     s1_is_unicode = PyUnicode_CheckExact(s1);
   36930           0 :     s2_is_unicode = PyUnicode_CheckExact(s2);
   36931             : #if PY_MAJOR_VERSION < 3
   36932             :     if ((s1_is_unicode & (!s2_is_unicode)) && PyString_CheckExact(s2)) {
   36933             :         owned_ref = PyUnicode_FromObject(s2);
   36934             :         if (unlikely(!owned_ref))
   36935             :             return -1;
   36936             :         s2 = owned_ref;
   36937             :         s2_is_unicode = 1;
   36938             :     } else if ((s2_is_unicode & (!s1_is_unicode)) && PyString_CheckExact(s1)) {
   36939             :         owned_ref = PyUnicode_FromObject(s1);
   36940             :         if (unlikely(!owned_ref))
   36941             :             return -1;
   36942             :         s1 = owned_ref;
   36943             :         s1_is_unicode = 1;
   36944             :     } else if (((!s2_is_unicode) & (!s1_is_unicode))) {
   36945             :         return __Pyx_PyBytes_Equals(s1, s2, equals);
   36946             :     }
   36947             : #endif
   36948           0 :     if (s1_is_unicode & s2_is_unicode) {
   36949           0 :         Py_ssize_t length;
   36950           0 :         int kind;
   36951           0 :         void *data1, *data2;
   36952           0 :         if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0))
   36953             :             return -1;
   36954           0 :         length = __Pyx_PyUnicode_GET_LENGTH(s1);
   36955           0 :         if (length != __Pyx_PyUnicode_GET_LENGTH(s2)) {
   36956           0 :             goto return_ne;
   36957             :         }
   36958             : #if CYTHON_USE_UNICODE_INTERNALS
   36959             :         {
   36960           0 :             Py_hash_t hash1, hash2;
   36961             :         #if CYTHON_PEP393_ENABLED
   36962           0 :             hash1 = ((PyASCIIObject*)s1)->hash;
   36963           0 :             hash2 = ((PyASCIIObject*)s2)->hash;
   36964             :         #else
   36965             :             hash1 = ((PyUnicodeObject*)s1)->hash;
   36966             :             hash2 = ((PyUnicodeObject*)s2)->hash;
   36967             :         #endif
   36968           0 :             if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
   36969           0 :                 goto return_ne;
   36970             :             }
   36971             :         }
   36972             : #endif
   36973           0 :         kind = __Pyx_PyUnicode_KIND(s1);
   36974           0 :         if (kind != __Pyx_PyUnicode_KIND(s2)) {
   36975           0 :             goto return_ne;
   36976             :         }
   36977           0 :         data1 = __Pyx_PyUnicode_DATA(s1);
   36978           0 :         data2 = __Pyx_PyUnicode_DATA(s2);
   36979           0 :         if (__Pyx_PyUnicode_READ(kind, data1, 0) != __Pyx_PyUnicode_READ(kind, data2, 0)) {
   36980           0 :             goto return_ne;
   36981           0 :         } else if (length == 1) {
   36982           0 :             goto return_eq;
   36983             :         } else {
   36984           0 :             int result = memcmp(data1, data2, (size_t)(length * kind));
   36985             :             #if PY_MAJOR_VERSION < 3
   36986             :             Py_XDECREF(owned_ref);
   36987             :             #endif
   36988           0 :             return (equals == Py_EQ) ? (result == 0) : (result != 0);
   36989             :         }
   36990           0 :     } else if ((s1 == Py_None) & s2_is_unicode) {
   36991           0 :         goto return_ne;
   36992           0 :     } else if ((s2 == Py_None) & s1_is_unicode) {
   36993           0 :         goto return_ne;
   36994             :     } else {
   36995           0 :         int result;
   36996           0 :         PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
   36997             :         #if PY_MAJOR_VERSION < 3
   36998             :         Py_XDECREF(owned_ref);
   36999             :         #endif
   37000           0 :         if (!py_result)
   37001             :             return -1;
   37002           0 :         result = __Pyx_PyObject_IsTrue(py_result);
   37003           0 :         Py_DECREF(py_result);
   37004           0 :         return result;
   37005             :     }
   37006           0 : return_eq:
   37007             :     #if PY_MAJOR_VERSION < 3
   37008             :     Py_XDECREF(owned_ref);
   37009             :     #endif
   37010           0 :     return (equals == Py_EQ);
   37011           0 : return_ne:
   37012             :     #if PY_MAJOR_VERSION < 3
   37013             :     Py_XDECREF(owned_ref);
   37014             :     #endif
   37015           0 :     return (equals == Py_NE);
   37016             : #endif
   37017             : }
   37018             : 
   37019             : /* fastcall */
   37020             : #if CYTHON_METH_FASTCALL
   37021           0 : static CYTHON_INLINE PyObject * __Pyx_GetKwValue_FASTCALL(PyObject *kwnames, PyObject *const *kwvalues, PyObject *s)
   37022             : {
   37023           0 :     Py_ssize_t i, n = PyTuple_GET_SIZE(kwnames);
   37024           0 :     for (i = 0; i < n; i++)
   37025             :     {
   37026           0 :         if (s == PyTuple_GET_ITEM(kwnames, i)) return kwvalues[i];
   37027             :     }
   37028           0 :     for (i = 0; i < n; i++)
   37029             :     {
   37030           0 :         int eq = __Pyx_PyUnicode_Equals(s, PyTuple_GET_ITEM(kwnames, i), Py_EQ);
   37031           0 :         if (unlikely(eq != 0)) {
   37032           0 :             if (unlikely(eq < 0)) return NULL;
   37033           0 :             return kwvalues[i];
   37034             :         }
   37035             :     }
   37036             :     return NULL;
   37037             : }
   37038             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030d0000
   37039             : CYTHON_UNUSED static PyObject *__Pyx_KwargsAsDict_FASTCALL(PyObject *kwnames, PyObject *const *kwvalues) {
   37040             :     Py_ssize_t i, nkwargs = PyTuple_GET_SIZE(kwnames);
   37041             :     PyObject *dict;
   37042             :     dict = PyDict_New();
   37043             :     if (unlikely(!dict))
   37044             :         return NULL;
   37045             :     for (i=0; i<nkwargs; i++) {
   37046             :         PyObject *key = PyTuple_GET_ITEM(kwnames, i);
   37047             :         if (unlikely(PyDict_SetItem(dict, key, kwvalues[i]) < 0))
   37048             :             goto bad;
   37049             :     }
   37050             :     return dict;
   37051             : bad:
   37052             :     Py_DECREF(dict);
   37053             :     return NULL;
   37054             : }
   37055             : #endif
   37056             : #endif
   37057             : 
   37058             : /* RaiseArgTupleInvalid */
   37059           0 : static void __Pyx_RaiseArgtupleInvalid(
   37060             :     const char* func_name,
   37061             :     int exact,
   37062             :     Py_ssize_t num_min,
   37063             :     Py_ssize_t num_max,
   37064             :     Py_ssize_t num_found)
   37065             : {
   37066           0 :     Py_ssize_t num_expected;
   37067           0 :     const char *more_or_less;
   37068           0 :     if (num_found < num_min) {
   37069             :         num_expected = num_min;
   37070             :         more_or_less = "at least";
   37071             :     } else {
   37072           0 :         num_expected = num_max;
   37073           0 :         more_or_less = "at most";
   37074             :     }
   37075           0 :     if (exact) {
   37076           0 :         more_or_less = "exactly";
   37077             :     }
   37078           0 :     PyErr_Format(PyExc_TypeError,
   37079             :                  "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)",
   37080             :                  func_name, more_or_less, num_expected,
   37081             :                  (num_expected == 1) ? "" : "s", num_found);
   37082           0 : }
   37083             : 
   37084             : /* RaiseDoubleKeywords */
   37085           0 : static void __Pyx_RaiseDoubleKeywordsError(
   37086             :     const char* func_name,
   37087             :     PyObject* kw_name)
   37088             : {
   37089           0 :     PyErr_Format(PyExc_TypeError,
   37090             :         #if PY_MAJOR_VERSION >= 3
   37091             :         "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
   37092             :         #else
   37093             :         "%s() got multiple values for keyword argument '%s'", func_name,
   37094             :         PyString_AsString(kw_name));
   37095             :         #endif
   37096             : }
   37097             : 
   37098             : /* ParseKeywords */
   37099           0 : static int __Pyx_ParseOptionalKeywords(
   37100             :     PyObject *kwds,
   37101             :     PyObject *const *kwvalues,
   37102             :     PyObject **argnames[],
   37103             :     PyObject *kwds2,
   37104             :     PyObject *values[],
   37105             :     Py_ssize_t num_pos_args,
   37106             :     const char* function_name)
   37107             : {
   37108           0 :     PyObject *key = 0, *value = 0;
   37109           0 :     Py_ssize_t pos = 0;
   37110           0 :     PyObject*** name;
   37111           0 :     PyObject*** first_kw_arg = argnames + num_pos_args;
   37112           0 :     int kwds_is_tuple = CYTHON_METH_FASTCALL && likely(PyTuple_Check(kwds));
   37113           0 :     while (1) {
   37114           0 :         Py_XDECREF(key); key = NULL;
   37115           0 :         Py_XDECREF(value); value = NULL;
   37116           0 :         if (kwds_is_tuple) {
   37117           0 :             Py_ssize_t size;
   37118             : #if CYTHON_ASSUME_SAFE_MACROS
   37119           0 :             size = PyTuple_GET_SIZE(kwds);
   37120             : #else
   37121             :             size = PyTuple_Size(kwds);
   37122             :             if (size < 0) goto bad;
   37123             : #endif
   37124           0 :             if (pos >= size) break;
   37125             : #if CYTHON_AVOID_BORROWED_REFS
   37126             :             key = __Pyx_PySequence_ITEM(kwds, pos);
   37127             :             if (!key) goto bad;
   37128             : #elif CYTHON_ASSUME_SAFE_MACROS
   37129           0 :             key = PyTuple_GET_ITEM(kwds, pos);
   37130             : #else
   37131             :             key = PyTuple_GetItem(kwds, pos);
   37132             :             if (!key) goto bad;
   37133             : #endif
   37134           0 :             value = kwvalues[pos];
   37135           0 :             pos++;
   37136             :         }
   37137             :         else
   37138             :         {
   37139           0 :             if (!PyDict_Next(kwds, &pos, &key, &value)) break;
   37140             : #if CYTHON_AVOID_BORROWED_REFS
   37141             :             Py_INCREF(key);
   37142             : #endif
   37143             :         }
   37144           0 :         name = first_kw_arg;
   37145           0 :         while (*name && (**name != key)) name++;
   37146           0 :         if (*name) {
   37147           0 :             values[name-argnames] = value;
   37148             : #if CYTHON_AVOID_BORROWED_REFS
   37149             :             Py_INCREF(value);
   37150             :             Py_DECREF(key);
   37151             : #endif
   37152           0 :             key = NULL;
   37153           0 :             value = NULL;
   37154           0 :             continue;
   37155             :         }
   37156             : #if !CYTHON_AVOID_BORROWED_REFS
   37157           0 :         Py_INCREF(key);
   37158             : #endif
   37159           0 :         Py_INCREF(value);
   37160           0 :         name = first_kw_arg;
   37161             :         #if PY_MAJOR_VERSION < 3
   37162             :         if (likely(PyString_Check(key))) {
   37163             :             while (*name) {
   37164             :                 if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
   37165             :                         && _PyString_Eq(**name, key)) {
   37166             :                     values[name-argnames] = value;
   37167             : #if CYTHON_AVOID_BORROWED_REFS
   37168             :                     value = NULL;
   37169             : #endif
   37170             :                     break;
   37171             :                 }
   37172             :                 name++;
   37173             :             }
   37174             :             if (*name) continue;
   37175             :             else {
   37176             :                 PyObject*** argname = argnames;
   37177             :                 while (argname != first_kw_arg) {
   37178             :                     if ((**argname == key) || (
   37179             :                             (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
   37180             :                              && _PyString_Eq(**argname, key))) {
   37181             :                         goto arg_passed_twice;
   37182             :                     }
   37183             :                     argname++;
   37184             :                 }
   37185             :             }
   37186             :         } else
   37187             :         #endif
   37188           0 :         if (likely(PyUnicode_Check(key))) {
   37189           0 :             while (*name) {
   37190           0 :                 int cmp = (
   37191             :                 #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
   37192           0 :                     (__Pyx_PyUnicode_GET_LENGTH(**name) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
   37193             :                 #endif
   37194           0 :                     PyUnicode_Compare(**name, key)
   37195             :                 );
   37196           0 :                 if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
   37197           0 :                 if (cmp == 0) {
   37198           0 :                     values[name-argnames] = value;
   37199             : #if CYTHON_AVOID_BORROWED_REFS
   37200             :                     value = NULL;
   37201             : #endif
   37202           0 :                     break;
   37203             :                 }
   37204           0 :                 name++;
   37205             :             }
   37206           0 :             if (*name) continue;
   37207             :             else {
   37208             :                 PyObject*** argname = argnames;
   37209           0 :                 while (argname != first_kw_arg) {
   37210           0 :                     int cmp = (**argname == key) ? 0 :
   37211             :                     #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
   37212           0 :                         (__Pyx_PyUnicode_GET_LENGTH(**argname) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
   37213             :                     #endif
   37214           0 :                         PyUnicode_Compare(**argname, key);
   37215           0 :                     if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
   37216           0 :                     if (cmp == 0) goto arg_passed_twice;
   37217           0 :                     argname++;
   37218             :                 }
   37219             :             }
   37220             :         } else
   37221           0 :             goto invalid_keyword_type;
   37222           0 :         if (kwds2) {
   37223           0 :             if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
   37224             :         } else {
   37225           0 :             goto invalid_keyword;
   37226             :         }
   37227             :     }
   37228           0 :     Py_XDECREF(key);
   37229           0 :     Py_XDECREF(value);
   37230           0 :     return 0;
   37231           0 : arg_passed_twice:
   37232           0 :     __Pyx_RaiseDoubleKeywordsError(function_name, key);
   37233           0 :     goto bad;
   37234           0 : invalid_keyword_type:
   37235           0 :     PyErr_Format(PyExc_TypeError,
   37236             :         "%.200s() keywords must be strings", function_name);
   37237           0 :     goto bad;
   37238           0 : invalid_keyword:
   37239             :     #if PY_MAJOR_VERSION < 3
   37240             :     PyErr_Format(PyExc_TypeError,
   37241             :         "%.200s() got an unexpected keyword argument '%.200s'",
   37242             :         function_name, PyString_AsString(key));
   37243             :     #else
   37244           0 :     PyErr_Format(PyExc_TypeError,
   37245             :         "%s() got an unexpected keyword argument '%U'",
   37246             :         function_name, key);
   37247             :     #endif
   37248           0 : bad:
   37249           0 :     Py_XDECREF(key);
   37250           0 :     Py_XDECREF(value);
   37251           0 :     return -1;
   37252             : }
   37253             : 
   37254             : /* ArgTypeTest */
   37255           0 : static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact)
   37256             : {
   37257           0 :     __Pyx_TypeName type_name;
   37258           0 :     __Pyx_TypeName obj_type_name;
   37259           0 :     if (unlikely(!type)) {
   37260           0 :         PyErr_SetString(PyExc_SystemError, "Missing type object");
   37261           0 :         return 0;
   37262             :     }
   37263           0 :     else if (exact) {
   37264             :         #if PY_MAJOR_VERSION == 2
   37265             :         if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj))) return 1;
   37266             :         #endif
   37267             :     }
   37268             :     else {
   37269           0 :         if (likely(__Pyx_TypeCheck(obj, type))) return 1;
   37270             :     }
   37271           0 :     type_name = __Pyx_PyType_GetName(type);
   37272           0 :     obj_type_name = __Pyx_PyType_GetName(Py_TYPE(obj));
   37273           0 :     PyErr_Format(PyExc_TypeError,
   37274             :         "Argument '%.200s' has incorrect type (expected " __Pyx_FMT_TYPENAME
   37275             :         ", got " __Pyx_FMT_TYPENAME ")", name, type_name, obj_type_name);
   37276           0 :     __Pyx_DECREF_TypeName(type_name);
   37277           0 :     __Pyx_DECREF_TypeName(obj_type_name);
   37278           0 :     return 0;
   37279             : }
   37280             : 
   37281             : /* RaiseException */
   37282             : #if PY_MAJOR_VERSION < 3
   37283             : static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
   37284             :     __Pyx_PyThreadState_declare
   37285             :     CYTHON_UNUSED_VAR(cause);
   37286             :     Py_XINCREF(type);
   37287             :     if (!value || value == Py_None)
   37288             :         value = NULL;
   37289             :     else
   37290             :         Py_INCREF(value);
   37291             :     if (!tb || tb == Py_None)
   37292             :         tb = NULL;
   37293             :     else {
   37294             :         Py_INCREF(tb);
   37295             :         if (!PyTraceBack_Check(tb)) {
   37296             :             PyErr_SetString(PyExc_TypeError,
   37297             :                 "raise: arg 3 must be a traceback or None");
   37298             :             goto raise_error;
   37299             :         }
   37300             :     }
   37301             :     if (PyType_Check(type)) {
   37302             : #if CYTHON_COMPILING_IN_PYPY
   37303             :         if (!value) {
   37304             :             Py_INCREF(Py_None);
   37305             :             value = Py_None;
   37306             :         }
   37307             : #endif
   37308             :         PyErr_NormalizeException(&type, &value, &tb);
   37309             :     } else {
   37310             :         if (value) {
   37311             :             PyErr_SetString(PyExc_TypeError,
   37312             :                 "instance exception may not have a separate value");
   37313             :             goto raise_error;
   37314             :         }
   37315             :         value = type;
   37316             :         type = (PyObject*) Py_TYPE(type);
   37317             :         Py_INCREF(type);
   37318             :         if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
   37319             :             PyErr_SetString(PyExc_TypeError,
   37320             :                 "raise: exception class must be a subclass of BaseException");
   37321             :             goto raise_error;
   37322             :         }
   37323             :     }
   37324             :     __Pyx_PyThreadState_assign
   37325             :     __Pyx_ErrRestore(type, value, tb);
   37326             :     return;
   37327             : raise_error:
   37328             :     Py_XDECREF(value);
   37329             :     Py_XDECREF(type);
   37330             :     Py_XDECREF(tb);
   37331             :     return;
   37332             : }
   37333             : #else
   37334           0 : static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
   37335           0 :     PyObject* owned_instance = NULL;
   37336           0 :     if (tb == Py_None) {
   37337             :         tb = 0;
   37338           0 :     } else if (tb && !PyTraceBack_Check(tb)) {
   37339           0 :         PyErr_SetString(PyExc_TypeError,
   37340             :             "raise: arg 3 must be a traceback or None");
   37341           0 :         goto bad;
   37342             :     }
   37343           0 :     if (value == Py_None)
   37344           0 :         value = 0;
   37345           0 :     if (PyExceptionInstance_Check(type)) {
   37346           0 :         if (value) {
   37347           0 :             PyErr_SetString(PyExc_TypeError,
   37348             :                 "instance exception may not have a separate value");
   37349           0 :             goto bad;
   37350             :         }
   37351             :         value = type;
   37352             :         type = (PyObject*) Py_TYPE(value);
   37353           0 :     } else if (PyExceptionClass_Check(type)) {
   37354           0 :         PyObject *instance_class = NULL;
   37355           0 :         if (value && PyExceptionInstance_Check(value)) {
   37356           0 :             instance_class = (PyObject*) Py_TYPE(value);
   37357           0 :             if (instance_class != type) {
   37358           0 :                 int is_subclass = PyObject_IsSubclass(instance_class, type);
   37359           0 :                 if (!is_subclass) {
   37360             :                     instance_class = NULL;
   37361           0 :                 } else if (unlikely(is_subclass == -1)) {
   37362           0 :                     goto bad;
   37363             :                 } else {
   37364             :                     type = instance_class;
   37365             :                 }
   37366             :             }
   37367             :         }
   37368             :         if (!instance_class) {
   37369           0 :             PyObject *args;
   37370           0 :             if (!value)
   37371           0 :                 args = PyTuple_New(0);
   37372           0 :             else if (PyTuple_Check(value)) {
   37373           0 :                 Py_INCREF(value);
   37374           0 :                 args = value;
   37375             :             } else
   37376           0 :                 args = PyTuple_Pack(1, value);
   37377           0 :             if (!args)
   37378           0 :                 goto bad;
   37379           0 :             owned_instance = PyObject_Call(type, args, NULL);
   37380           0 :             Py_DECREF(args);
   37381           0 :             if (!owned_instance)
   37382           0 :                 goto bad;
   37383           0 :             value = owned_instance;
   37384           0 :             if (!PyExceptionInstance_Check(value)) {
   37385           0 :                 PyErr_Format(PyExc_TypeError,
   37386             :                              "calling %R should have returned an instance of "
   37387             :                              "BaseException, not %R",
   37388             :                              type, Py_TYPE(value));
   37389           0 :                 goto bad;
   37390             :             }
   37391             :         }
   37392             :     } else {
   37393           0 :         PyErr_SetString(PyExc_TypeError,
   37394             :             "raise: exception class must be a subclass of BaseException");
   37395           0 :         goto bad;
   37396             :     }
   37397           0 :     if (cause) {
   37398           0 :         PyObject *fixed_cause;
   37399           0 :         if (cause == Py_None) {
   37400             :             fixed_cause = NULL;
   37401           0 :         } else if (PyExceptionClass_Check(cause)) {
   37402           0 :             fixed_cause = PyObject_CallObject(cause, NULL);
   37403           0 :             if (fixed_cause == NULL)
   37404           0 :                 goto bad;
   37405           0 :         } else if (PyExceptionInstance_Check(cause)) {
   37406           0 :             fixed_cause = cause;
   37407           0 :             Py_INCREF(fixed_cause);
   37408             :         } else {
   37409           0 :             PyErr_SetString(PyExc_TypeError,
   37410             :                             "exception causes must derive from "
   37411             :                             "BaseException");
   37412           0 :             goto bad;
   37413             :         }
   37414           0 :         PyException_SetCause(value, fixed_cause);
   37415             :     }
   37416           0 :     PyErr_SetObject(type, value);
   37417           0 :     if (tb) {
   37418             :       #if PY_VERSION_HEX >= 0x030C00A6
   37419           0 :         PyException_SetTraceback(value, tb);
   37420             :       #elif CYTHON_FAST_THREAD_STATE
   37421             :         PyThreadState *tstate = __Pyx_PyThreadState_Current;
   37422             :         PyObject* tmp_tb = tstate->curexc_traceback;
   37423             :         if (tb != tmp_tb) {
   37424             :             Py_INCREF(tb);
   37425             :             tstate->curexc_traceback = tb;
   37426             :             Py_XDECREF(tmp_tb);
   37427             :         }
   37428             : #else
   37429             :         PyObject *tmp_type, *tmp_value, *tmp_tb;
   37430             :         PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
   37431             :         Py_INCREF(tb);
   37432             :         PyErr_Restore(tmp_type, tmp_value, tb);
   37433             :         Py_XDECREF(tmp_tb);
   37434             : #endif
   37435             :     }
   37436           0 : bad:
   37437           0 :     Py_XDECREF(owned_instance);
   37438           0 :     return;
   37439             : }
   37440             : #endif
   37441             : 
   37442             : /* PyFunctionFastCall */
   37443             : #if CYTHON_FAST_PYCALL && !CYTHON_VECTORCALL
   37444             : static PyObject* __Pyx_PyFunction_FastCallNoKw(PyCodeObject *co, PyObject **args, Py_ssize_t na,
   37445             :                                                PyObject *globals) {
   37446             :     PyFrameObject *f;
   37447             :     PyThreadState *tstate = __Pyx_PyThreadState_Current;
   37448             :     PyObject **fastlocals;
   37449             :     Py_ssize_t i;
   37450             :     PyObject *result;
   37451             :     assert(globals != NULL);
   37452             :     /* XXX Perhaps we should create a specialized
   37453             :        PyFrame_New() that doesn't take locals, but does
   37454             :        take builtins without sanity checking them.
   37455             :        */
   37456             :     assert(tstate != NULL);
   37457             :     f = PyFrame_New(tstate, co, globals, NULL);
   37458             :     if (f == NULL) {
   37459             :         return NULL;
   37460             :     }
   37461             :     fastlocals = __Pyx_PyFrame_GetLocalsplus(f);
   37462             :     for (i = 0; i < na; i++) {
   37463             :         Py_INCREF(*args);
   37464             :         fastlocals[i] = *args++;
   37465             :     }
   37466             :     result = PyEval_EvalFrameEx(f,0);
   37467             :     ++tstate->recursion_depth;
   37468             :     Py_DECREF(f);
   37469             :     --tstate->recursion_depth;
   37470             :     return result;
   37471             : }
   37472             : static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs) {
   37473             :     PyCodeObject *co = (PyCodeObject *)PyFunction_GET_CODE(func);
   37474             :     PyObject *globals = PyFunction_GET_GLOBALS(func);
   37475             :     PyObject *argdefs = PyFunction_GET_DEFAULTS(func);
   37476             :     PyObject *closure;
   37477             : #if PY_MAJOR_VERSION >= 3
   37478             :     PyObject *kwdefs;
   37479             : #endif
   37480             :     PyObject *kwtuple, **k;
   37481             :     PyObject **d;
   37482             :     Py_ssize_t nd;
   37483             :     Py_ssize_t nk;
   37484             :     PyObject *result;
   37485             :     assert(kwargs == NULL || PyDict_Check(kwargs));
   37486             :     nk = kwargs ? PyDict_Size(kwargs) : 0;
   37487             :     #if PY_MAJOR_VERSION < 3
   37488             :     if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object"))) {
   37489             :         return NULL;
   37490             :     }
   37491             :     #else
   37492             :     if (unlikely(Py_EnterRecursiveCall(" while calling a Python object"))) {
   37493             :         return NULL;
   37494             :     }
   37495             :     #endif
   37496             :     if (
   37497             : #if PY_MAJOR_VERSION >= 3
   37498             :             co->co_kwonlyargcount == 0 &&
   37499             : #endif
   37500             :             likely(kwargs == NULL || nk == 0) &&
   37501             :             co->co_flags == (CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE)) {
   37502             :         if (argdefs == NULL && co->co_argcount == nargs) {
   37503             :             result = __Pyx_PyFunction_FastCallNoKw(co, args, nargs, globals);
   37504             :             goto done;
   37505             :         }
   37506             :         else if (nargs == 0 && argdefs != NULL
   37507             :                  && co->co_argcount == Py_SIZE(argdefs)) {
   37508             :             /* function called with no arguments, but all parameters have
   37509             :                a default value: use default values as arguments .*/
   37510             :             args = &PyTuple_GET_ITEM(argdefs, 0);
   37511             :             result =__Pyx_PyFunction_FastCallNoKw(co, args, Py_SIZE(argdefs), globals);
   37512             :             goto done;
   37513             :         }
   37514             :     }
   37515             :     if (kwargs != NULL) {
   37516             :         Py_ssize_t pos, i;
   37517             :         kwtuple = PyTuple_New(2 * nk);
   37518             :         if (kwtuple == NULL) {
   37519             :             result = NULL;
   37520             :             goto done;
   37521             :         }
   37522             :         k = &PyTuple_GET_ITEM(kwtuple, 0);
   37523             :         pos = i = 0;
   37524             :         while (PyDict_Next(kwargs, &pos, &k[i], &k[i+1])) {
   37525             :             Py_INCREF(k[i]);
   37526             :             Py_INCREF(k[i+1]);
   37527             :             i += 2;
   37528             :         }
   37529             :         nk = i / 2;
   37530             :     }
   37531             :     else {
   37532             :         kwtuple = NULL;
   37533             :         k = NULL;
   37534             :     }
   37535             :     closure = PyFunction_GET_CLOSURE(func);
   37536             : #if PY_MAJOR_VERSION >= 3
   37537             :     kwdefs = PyFunction_GET_KW_DEFAULTS(func);
   37538             : #endif
   37539             :     if (argdefs != NULL) {
   37540             :         d = &PyTuple_GET_ITEM(argdefs, 0);
   37541             :         nd = Py_SIZE(argdefs);
   37542             :     }
   37543             :     else {
   37544             :         d = NULL;
   37545             :         nd = 0;
   37546             :     }
   37547             : #if PY_MAJOR_VERSION >= 3
   37548             :     result = PyEval_EvalCodeEx((PyObject*)co, globals, (PyObject *)NULL,
   37549             :                                args, (int)nargs,
   37550             :                                k, (int)nk,
   37551             :                                d, (int)nd, kwdefs, closure);
   37552             : #else
   37553             :     result = PyEval_EvalCodeEx(co, globals, (PyObject *)NULL,
   37554             :                                args, (int)nargs,
   37555             :                                k, (int)nk,
   37556             :                                d, (int)nd, closure);
   37557             : #endif
   37558             :     Py_XDECREF(kwtuple);
   37559             : done:
   37560             :     Py_LeaveRecursiveCall();
   37561             :     return result;
   37562             : }
   37563             : #endif
   37564             : 
   37565             : /* PyObjectCall */
   37566             : #if CYTHON_COMPILING_IN_CPYTHON
   37567         386 : static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
   37568         386 :     PyObject *result;
   37569         386 :     ternaryfunc call = Py_TYPE(func)->tp_call;
   37570         386 :     if (unlikely(!call))
   37571           0 :         return PyObject_Call(func, arg, kw);
   37572             :     #if PY_MAJOR_VERSION < 3
   37573             :     if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
   37574             :         return NULL;
   37575             :     #else
   37576         386 :     if (unlikely(Py_EnterRecursiveCall(" while calling a Python object")))
   37577             :         return NULL;
   37578             :     #endif
   37579         386 :     result = (*call)(func, arg, kw);
   37580         386 :     Py_LeaveRecursiveCall();
   37581         386 :     if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
   37582           0 :         PyErr_SetString(
   37583             :             PyExc_SystemError,
   37584             :             "NULL result without error in PyObject_Call");
   37585             :     }
   37586             :     return result;
   37587             : }
   37588             : #endif
   37589             : 
   37590             : /* PyObjectCallMethO */
   37591             : #if CYTHON_COMPILING_IN_CPYTHON
   37592           0 : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) {
   37593           0 :     PyObject *self, *result;
   37594           0 :     PyCFunction cfunc;
   37595           0 :     cfunc = __Pyx_CyOrPyCFunction_GET_FUNCTION(func);
   37596           0 :     self = __Pyx_CyOrPyCFunction_GET_SELF(func);
   37597             :     #if PY_MAJOR_VERSION < 3
   37598             :     if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
   37599             :         return NULL;
   37600             :     #else
   37601           0 :     if (unlikely(Py_EnterRecursiveCall(" while calling a Python object")))
   37602             :         return NULL;
   37603             :     #endif
   37604           0 :     result = cfunc(self, arg);
   37605           0 :     Py_LeaveRecursiveCall();
   37606           0 :     if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
   37607           0 :         PyErr_SetString(
   37608             :             PyExc_SystemError,
   37609             :             "NULL result without error in PyObject_Call");
   37610             :     }
   37611             :     return result;
   37612             : }
   37613             : #endif
   37614             : 
   37615             : /* PyObjectFastCall */
   37616             : #if PY_VERSION_HEX < 0x03090000 || CYTHON_COMPILING_IN_LIMITED_API
   37617             : static PyObject* __Pyx_PyObject_FastCall_fallback(PyObject *func, PyObject **args, size_t nargs, PyObject *kwargs) {
   37618             :     PyObject *argstuple;
   37619             :     PyObject *result = 0;
   37620             :     size_t i;
   37621             :     argstuple = PyTuple_New((Py_ssize_t)nargs);
   37622             :     if (unlikely(!argstuple)) return NULL;
   37623             :     for (i = 0; i < nargs; i++) {
   37624             :         Py_INCREF(args[i]);
   37625             :         if (__Pyx_PyTuple_SET_ITEM(argstuple, (Py_ssize_t)i, args[i]) < 0) goto bad;
   37626             :     }
   37627             :     result = __Pyx_PyObject_Call(func, argstuple, kwargs);
   37628             :   bad:
   37629             :     Py_DECREF(argstuple);
   37630             :     return result;
   37631             : }
   37632             : #endif
   37633        1024 : static CYTHON_INLINE PyObject* __Pyx_PyObject_FastCallDict(PyObject *func, PyObject **args, size_t _nargs, PyObject *kwargs) {
   37634        1024 :     Py_ssize_t nargs = __Pyx_PyVectorcall_NARGS(_nargs);
   37635             : #if CYTHON_COMPILING_IN_CPYTHON
   37636        1024 :     if (nargs == 0 && kwargs == NULL) {
   37637         119 :         if (__Pyx_CyOrPyCFunction_Check(func) && likely( __Pyx_CyOrPyCFunction_GET_FLAGS(func) & METH_NOARGS))
   37638           0 :             return __Pyx_PyObject_CallMethO(func, NULL);
   37639             :     }
   37640         905 :     else if (nargs == 1 && kwargs == NULL) {
   37641         899 :         if (__Pyx_CyOrPyCFunction_Check(func) && likely( __Pyx_CyOrPyCFunction_GET_FLAGS(func) & METH_O))
   37642           0 :             return __Pyx_PyObject_CallMethO(func, args[0]);
   37643             :     }
   37644             : #endif
   37645             :     #if PY_VERSION_HEX < 0x030800B1
   37646             :     #if CYTHON_FAST_PYCCALL
   37647             :     if (PyCFunction_Check(func)) {
   37648             :         if (kwargs) {
   37649             :             return _PyCFunction_FastCallDict(func, args, nargs, kwargs);
   37650             :         } else {
   37651             :             return _PyCFunction_FastCallKeywords(func, args, nargs, NULL);
   37652             :         }
   37653             :     }
   37654             :     #if PY_VERSION_HEX >= 0x030700A1
   37655             :     if (!kwargs && __Pyx_IS_TYPE(func, &PyMethodDescr_Type)) {
   37656             :         return _PyMethodDescr_FastCallKeywords(func, args, nargs, NULL);
   37657             :     }
   37658             :     #endif
   37659             :     #endif
   37660             :     #if CYTHON_FAST_PYCALL
   37661             :     if (PyFunction_Check(func)) {
   37662             :         return __Pyx_PyFunction_FastCallDict(func, args, nargs, kwargs);
   37663             :     }
   37664             :     #endif
   37665             :     #endif
   37666        1024 :     if (kwargs == NULL) {
   37667             :         #if CYTHON_VECTORCALL
   37668             :         #if PY_VERSION_HEX < 0x03090000
   37669             :         vectorcallfunc f = _PyVectorcall_Function(func);
   37670             :         #else
   37671        1024 :         vectorcallfunc f = PyVectorcall_Function(func);
   37672             :         #endif
   37673        1024 :         if (f) {
   37674         667 :             return f(func, args, (size_t)nargs, NULL);
   37675             :         }
   37676             :         #elif defined(__Pyx_CyFunction_USED) && CYTHON_BACKPORT_VECTORCALL
   37677             :         if (__Pyx_CyFunction_CheckExact(func)) {
   37678             :             __pyx_vectorcallfunc f = __Pyx_CyFunction_func_vectorcall(func);
   37679             :             if (f) return f(func, args, (size_t)nargs, NULL);
   37680             :         }
   37681             :         #endif
   37682             :     }
   37683         357 :     if (nargs == 0) {
   37684           0 :         return __Pyx_PyObject_Call(func, __pyx_empty_tuple, kwargs);
   37685             :     }
   37686             :     #if PY_VERSION_HEX >= 0x03090000 && !CYTHON_COMPILING_IN_LIMITED_API
   37687         357 :     return PyObject_VectorcallDict(func, args, (size_t)nargs, kwargs);
   37688             :     #else
   37689             :     return __Pyx_PyObject_FastCall_fallback(func, args, (size_t)nargs, kwargs);
   37690             :     #endif
   37691             : }
   37692             : 
   37693             : /* RaiseUnexpectedTypeError */
   37694             : static int
   37695           0 : __Pyx_RaiseUnexpectedTypeError(const char *expected, PyObject *obj)
   37696             : {
   37697           0 :     __Pyx_TypeName obj_type_name = __Pyx_PyType_GetName(Py_TYPE(obj));
   37698           0 :     PyErr_Format(PyExc_TypeError, "Expected %s, got " __Pyx_FMT_TYPENAME,
   37699             :                  expected, obj_type_name);
   37700           0 :     __Pyx_DECREF_TypeName(obj_type_name);
   37701           0 :     return 0;
   37702             : }
   37703             : 
   37704             : /* CIntToDigits */
   37705             : static const char DIGIT_PAIRS_10[2*10*10+1] = {
   37706             :     "00010203040506070809"
   37707             :     "10111213141516171819"
   37708             :     "20212223242526272829"
   37709             :     "30313233343536373839"
   37710             :     "40414243444546474849"
   37711             :     "50515253545556575859"
   37712             :     "60616263646566676869"
   37713             :     "70717273747576777879"
   37714             :     "80818283848586878889"
   37715             :     "90919293949596979899"
   37716             : };
   37717             : static const char DIGIT_PAIRS_8[2*8*8+1] = {
   37718             :     "0001020304050607"
   37719             :     "1011121314151617"
   37720             :     "2021222324252627"
   37721             :     "3031323334353637"
   37722             :     "4041424344454647"
   37723             :     "5051525354555657"
   37724             :     "6061626364656667"
   37725             :     "7071727374757677"
   37726             : };
   37727             : static const char DIGITS_HEX[2*16+1] = {
   37728             :     "0123456789abcdef"
   37729             :     "0123456789ABCDEF"
   37730             : };
   37731             : 
   37732             : /* BuildPyUnicode */
   37733           0 : static PyObject* __Pyx_PyUnicode_BuildFromAscii(Py_ssize_t ulength, char* chars, int clength,
   37734             :                                                 int prepend_sign, char padding_char) {
   37735           0 :     PyObject *uval;
   37736           0 :     Py_ssize_t uoffset = ulength - clength;
   37737             : #if CYTHON_USE_UNICODE_INTERNALS
   37738           0 :     Py_ssize_t i;
   37739             : #if CYTHON_PEP393_ENABLED
   37740           0 :     void *udata;
   37741           0 :     uval = PyUnicode_New(ulength, 127);
   37742           0 :     if (unlikely(!uval)) return NULL;
   37743           0 :     udata = PyUnicode_DATA(uval);
   37744             : #else
   37745             :     Py_UNICODE *udata;
   37746             :     uval = PyUnicode_FromUnicode(NULL, ulength);
   37747             :     if (unlikely(!uval)) return NULL;
   37748             :     udata = PyUnicode_AS_UNICODE(uval);
   37749             : #endif
   37750           0 :     if (uoffset > 0) {
   37751           0 :         i = 0;
   37752           0 :         if (prepend_sign) {
   37753           0 :             __Pyx_PyUnicode_WRITE(PyUnicode_1BYTE_KIND, udata, 0, '-');
   37754           0 :             i++;
   37755             :         }
   37756           0 :         for (; i < uoffset; i++) {
   37757           0 :             __Pyx_PyUnicode_WRITE(PyUnicode_1BYTE_KIND, udata, i, padding_char);
   37758             :         }
   37759             :     }
   37760           0 :     for (i=0; i < clength; i++) {
   37761           0 :         __Pyx_PyUnicode_WRITE(PyUnicode_1BYTE_KIND, udata, uoffset+i, chars[i]);
   37762             :     }
   37763             : #else
   37764             :     {
   37765             :         PyObject *sign = NULL, *padding = NULL;
   37766             :         uval = NULL;
   37767             :         if (uoffset > 0) {
   37768             :             prepend_sign = !!prepend_sign;
   37769             :             if (uoffset > prepend_sign) {
   37770             :                 padding = PyUnicode_FromOrdinal(padding_char);
   37771             :                 if (likely(padding) && uoffset > prepend_sign + 1) {
   37772             :                     PyObject *tmp;
   37773             :                     PyObject *repeat = PyInt_FromSsize_t(uoffset - prepend_sign);
   37774             :                     if (unlikely(!repeat)) goto done_or_error;
   37775             :                     tmp = PyNumber_Multiply(padding, repeat);
   37776             :                     Py_DECREF(repeat);
   37777             :                     Py_DECREF(padding);
   37778             :                     padding = tmp;
   37779             :                 }
   37780             :                 if (unlikely(!padding)) goto done_or_error;
   37781             :             }
   37782             :             if (prepend_sign) {
   37783             :                 sign = PyUnicode_FromOrdinal('-');
   37784             :                 if (unlikely(!sign)) goto done_or_error;
   37785             :             }
   37786             :         }
   37787             :         uval = PyUnicode_DecodeASCII(chars, clength, NULL);
   37788             :         if (likely(uval) && padding) {
   37789             :             PyObject *tmp = PyNumber_Add(padding, uval);
   37790             :             Py_DECREF(uval);
   37791             :             uval = tmp;
   37792             :         }
   37793             :         if (likely(uval) && sign) {
   37794             :             PyObject *tmp = PyNumber_Add(sign, uval);
   37795             :             Py_DECREF(uval);
   37796             :             uval = tmp;
   37797             :         }
   37798             : done_or_error:
   37799             :         Py_XDECREF(padding);
   37800             :         Py_XDECREF(sign);
   37801             :     }
   37802             : #endif
   37803             :     return uval;
   37804             : }
   37805             : 
   37806             : /* CIntToPyUnicode */
   37807           0 : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_From_int(int value, Py_ssize_t width, char padding_char, char format_char) {
   37808           0 :     char digits[sizeof(int)*3+2];
   37809           0 :     char *dpos, *end = digits + sizeof(int)*3+2;
   37810           0 :     const char *hex_digits = DIGITS_HEX;
   37811           0 :     Py_ssize_t length, ulength;
   37812           0 :     int prepend_sign, last_one_off;
   37813           0 :     int remaining;
   37814             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   37815             : #pragma GCC diagnostic push
   37816             : #pragma GCC diagnostic ignored "-Wconversion"
   37817             : #endif
   37818           0 :     const int neg_one = (int) -1, const_zero = (int) 0;
   37819             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   37820             : #pragma GCC diagnostic pop
   37821             : #endif
   37822           0 :     const int is_unsigned = neg_one > const_zero;
   37823           0 :     if (format_char == 'X') {
   37824           0 :         hex_digits += 16;
   37825           0 :         format_char = 'x';
   37826             :     }
   37827           0 :     remaining = value;
   37828           0 :     last_one_off = 0;
   37829           0 :     dpos = end;
   37830           0 :     do {
   37831           0 :         int digit_pos;
   37832           0 :         switch (format_char) {
   37833           0 :         case 'o':
   37834           0 :             digit_pos = abs((int)(remaining % (8*8)));
   37835           0 :             remaining = (int) (remaining / (8*8));
   37836           0 :             dpos -= 2;
   37837           0 :             memcpy(dpos, DIGIT_PAIRS_8 + digit_pos * 2, 2);
   37838           0 :             last_one_off = (digit_pos < 8);
   37839           0 :             break;
   37840           0 :         case 'd':
   37841           0 :             digit_pos = abs((int)(remaining % (10*10)));
   37842           0 :             remaining = (int) (remaining / (10*10));
   37843           0 :             dpos -= 2;
   37844           0 :             memcpy(dpos, DIGIT_PAIRS_10 + digit_pos * 2, 2);
   37845           0 :             last_one_off = (digit_pos < 10);
   37846           0 :             break;
   37847           0 :         case 'x':
   37848           0 :             *(--dpos) = hex_digits[abs((int)(remaining % 16))];
   37849           0 :             remaining = (int) (remaining / 16);
   37850           0 :             break;
   37851             :         default:
   37852             :             assert(0);
   37853             :             break;
   37854             :         }
   37855           0 :     } while (unlikely(remaining != 0));
   37856           0 :     assert(!last_one_off || *dpos == '0');
   37857           0 :     dpos += last_one_off;
   37858           0 :     length = end - dpos;
   37859           0 :     ulength = length;
   37860           0 :     prepend_sign = 0;
   37861           0 :     if (!is_unsigned && value <= neg_one) {
   37862           0 :         if (padding_char == ' ' || width <= length + 1) {
   37863           0 :             *(--dpos) = '-';
   37864           0 :             ++length;
   37865             :         } else {
   37866             :             prepend_sign = 1;
   37867             :         }
   37868           0 :         ++ulength;
   37869             :     }
   37870           0 :     if (width > ulength) {
   37871             :         ulength = width;
   37872             :     }
   37873           0 :     if (ulength == 1) {
   37874           0 :         return PyUnicode_FromOrdinal(*dpos);
   37875             :     }
   37876           0 :     return __Pyx_PyUnicode_BuildFromAscii(ulength, dpos, (int) length, prepend_sign, padding_char);
   37877             : }
   37878             : 
   37879             : /* CIntToPyUnicode */
   37880           0 : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_From_Py_ssize_t(Py_ssize_t value, Py_ssize_t width, char padding_char, char format_char) {
   37881           0 :     char digits[sizeof(Py_ssize_t)*3+2];
   37882           0 :     char *dpos, *end = digits + sizeof(Py_ssize_t)*3+2;
   37883           0 :     const char *hex_digits = DIGITS_HEX;
   37884           0 :     Py_ssize_t length, ulength;
   37885           0 :     int prepend_sign, last_one_off;
   37886           0 :     Py_ssize_t remaining;
   37887             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   37888             : #pragma GCC diagnostic push
   37889             : #pragma GCC diagnostic ignored "-Wconversion"
   37890             : #endif
   37891           0 :     const Py_ssize_t neg_one = (Py_ssize_t) -1, const_zero = (Py_ssize_t) 0;
   37892             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   37893             : #pragma GCC diagnostic pop
   37894             : #endif
   37895           0 :     const int is_unsigned = neg_one > const_zero;
   37896           0 :     if (format_char == 'X') {
   37897           0 :         hex_digits += 16;
   37898           0 :         format_char = 'x';
   37899             :     }
   37900           0 :     remaining = value;
   37901           0 :     last_one_off = 0;
   37902           0 :     dpos = end;
   37903           0 :     do {
   37904           0 :         int digit_pos;
   37905           0 :         switch (format_char) {
   37906           0 :         case 'o':
   37907           0 :             digit_pos = abs((int)(remaining % (8*8)));
   37908           0 :             remaining = (Py_ssize_t) (remaining / (8*8));
   37909           0 :             dpos -= 2;
   37910           0 :             memcpy(dpos, DIGIT_PAIRS_8 + digit_pos * 2, 2);
   37911           0 :             last_one_off = (digit_pos < 8);
   37912           0 :             break;
   37913           0 :         case 'd':
   37914           0 :             digit_pos = abs((int)(remaining % (10*10)));
   37915           0 :             remaining = (Py_ssize_t) (remaining / (10*10));
   37916           0 :             dpos -= 2;
   37917           0 :             memcpy(dpos, DIGIT_PAIRS_10 + digit_pos * 2, 2);
   37918           0 :             last_one_off = (digit_pos < 10);
   37919           0 :             break;
   37920           0 :         case 'x':
   37921           0 :             *(--dpos) = hex_digits[abs((int)(remaining % 16))];
   37922           0 :             remaining = (Py_ssize_t) (remaining / 16);
   37923           0 :             break;
   37924             :         default:
   37925             :             assert(0);
   37926             :             break;
   37927             :         }
   37928           0 :     } while (unlikely(remaining != 0));
   37929           0 :     assert(!last_one_off || *dpos == '0');
   37930           0 :     dpos += last_one_off;
   37931           0 :     length = end - dpos;
   37932           0 :     ulength = length;
   37933           0 :     prepend_sign = 0;
   37934           0 :     if (!is_unsigned && value <= neg_one) {
   37935           0 :         if (padding_char == ' ' || width <= length + 1) {
   37936           0 :             *(--dpos) = '-';
   37937           0 :             ++length;
   37938             :         } else {
   37939             :             prepend_sign = 1;
   37940             :         }
   37941           0 :         ++ulength;
   37942             :     }
   37943           0 :     if (width > ulength) {
   37944             :         ulength = width;
   37945             :     }
   37946           0 :     if (ulength == 1) {
   37947           0 :         return PyUnicode_FromOrdinal(*dpos);
   37948             :     }
   37949           0 :     return __Pyx_PyUnicode_BuildFromAscii(ulength, dpos, (int) length, prepend_sign, padding_char);
   37950             : }
   37951             : 
   37952             : /* JoinPyUnicode */
   37953           0 : static PyObject* __Pyx_PyUnicode_Join(PyObject* value_tuple, Py_ssize_t value_count, Py_ssize_t result_ulength,
   37954             :                                       Py_UCS4 max_char) {
   37955             : #if CYTHON_USE_UNICODE_INTERNALS && CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   37956           0 :     PyObject *result_uval;
   37957           0 :     int result_ukind, kind_shift;
   37958           0 :     Py_ssize_t i, char_pos;
   37959           0 :     void *result_udata;
   37960           0 :     CYTHON_MAYBE_UNUSED_VAR(max_char);
   37961             : #if CYTHON_PEP393_ENABLED
   37962           0 :     result_uval = PyUnicode_New(result_ulength, max_char);
   37963           0 :     if (unlikely(!result_uval)) return NULL;
   37964           0 :     result_ukind = (max_char <= 255) ? PyUnicode_1BYTE_KIND : (max_char <= 65535) ? PyUnicode_2BYTE_KIND : PyUnicode_4BYTE_KIND;
   37965           0 :     kind_shift = (result_ukind == PyUnicode_4BYTE_KIND) ? 2 : result_ukind - 1;
   37966           0 :     result_udata = PyUnicode_DATA(result_uval);
   37967             : #else
   37968             :     result_uval = PyUnicode_FromUnicode(NULL, result_ulength);
   37969             :     if (unlikely(!result_uval)) return NULL;
   37970             :     result_ukind = sizeof(Py_UNICODE);
   37971             :     kind_shift = (result_ukind == 4) ? 2 : result_ukind - 1;
   37972             :     result_udata = PyUnicode_AS_UNICODE(result_uval);
   37973             : #endif
   37974           0 :     assert(kind_shift == 2 || kind_shift == 1 || kind_shift == 0);
   37975           0 :     char_pos = 0;
   37976           0 :     for (i=0; i < value_count; i++) {
   37977           0 :         int ukind;
   37978           0 :         Py_ssize_t ulength;
   37979           0 :         void *udata;
   37980           0 :         PyObject *uval = PyTuple_GET_ITEM(value_tuple, i);
   37981           0 :         if (unlikely(__Pyx_PyUnicode_READY(uval)))
   37982             :             goto bad;
   37983           0 :         ulength = __Pyx_PyUnicode_GET_LENGTH(uval);
   37984           0 :         if (unlikely(!ulength))
   37985           0 :             continue;
   37986           0 :         if (unlikely((PY_SSIZE_T_MAX >> kind_shift) - ulength < char_pos))
   37987           0 :             goto overflow;
   37988           0 :         ukind = __Pyx_PyUnicode_KIND(uval);
   37989           0 :         udata = __Pyx_PyUnicode_DATA(uval);
   37990           0 :         if (!CYTHON_PEP393_ENABLED || ukind == result_ukind) {
   37991           0 :             memcpy((char *)result_udata + (char_pos << kind_shift), udata, (size_t) (ulength << kind_shift));
   37992             :         } else {
   37993             :             #if PY_VERSION_HEX >= 0x030d0000
   37994             :             if (unlikely(PyUnicode_CopyCharacters(result_uval, char_pos, uval, 0, ulength) < 0)) goto bad;
   37995             :             #elif CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030300F0 || defined(_PyUnicode_FastCopyCharacters)
   37996           0 :             _PyUnicode_FastCopyCharacters(result_uval, char_pos, uval, 0, ulength);
   37997             :             #else
   37998             :             Py_ssize_t j;
   37999             :             for (j=0; j < ulength; j++) {
   38000             :                 Py_UCS4 uchar = __Pyx_PyUnicode_READ(ukind, udata, j);
   38001             :                 __Pyx_PyUnicode_WRITE(result_ukind, result_udata, char_pos+j, uchar);
   38002             :             }
   38003             :             #endif
   38004             :         }
   38005           0 :         char_pos += ulength;
   38006             :     }
   38007             :     return result_uval;
   38008           0 : overflow:
   38009           0 :     PyErr_SetString(PyExc_OverflowError, "join() result is too long for a Python string");
   38010           0 : bad:
   38011           0 :     Py_DECREF(result_uval);
   38012             :     return NULL;
   38013             : #else
   38014             :     CYTHON_UNUSED_VAR(max_char);
   38015             :     CYTHON_UNUSED_VAR(result_ulength);
   38016             :     CYTHON_UNUSED_VAR(value_count);
   38017             :     return PyUnicode_Join(__pyx_empty_unicode, value_tuple);
   38018             : #endif
   38019             : }
   38020             : 
   38021             : /* GetAttr */
   38022           0 : static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *o, PyObject *n) {
   38023             : #if CYTHON_USE_TYPE_SLOTS
   38024             : #if PY_MAJOR_VERSION >= 3
   38025           0 :     if (likely(PyUnicode_Check(n)))
   38026             : #else
   38027             :     if (likely(PyString_Check(n)))
   38028             : #endif
   38029           0 :         return __Pyx_PyObject_GetAttrStr(o, n);
   38030             : #endif
   38031           0 :     return PyObject_GetAttr(o, n);
   38032             : }
   38033             : 
   38034             : /* GetItemInt */
   38035           0 : static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
   38036           0 :     PyObject *r;
   38037           0 :     if (unlikely(!j)) return NULL;
   38038           0 :     r = PyObject_GetItem(o, j);
   38039           0 :     Py_DECREF(j);
   38040             :     return r;
   38041             : }
   38042         357 : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
   38043             :                                                               CYTHON_NCP_UNUSED int wraparound,
   38044             :                                                               CYTHON_NCP_UNUSED int boundscheck) {
   38045             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   38046         357 :     Py_ssize_t wrapped_i = i;
   38047         357 :     if (wraparound & unlikely(i < 0)) {
   38048           0 :         wrapped_i += PyList_GET_SIZE(o);
   38049             :     }
   38050         357 :     if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyList_GET_SIZE(o)))) {
   38051         357 :         PyObject *r = PyList_GET_ITEM(o, wrapped_i);
   38052         357 :         Py_INCREF(r);
   38053         357 :         return r;
   38054             :     }
   38055           0 :     return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
   38056             : #else
   38057             :     return PySequence_GetItem(o, i);
   38058             : #endif
   38059             : }
   38060         357 : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
   38061             :                                                               CYTHON_NCP_UNUSED int wraparound,
   38062             :                                                               CYTHON_NCP_UNUSED int boundscheck) {
   38063             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   38064         357 :     Py_ssize_t wrapped_i = i;
   38065         357 :     if (wraparound & unlikely(i < 0)) {
   38066           0 :         wrapped_i += PyTuple_GET_SIZE(o);
   38067             :     }
   38068         357 :     if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyTuple_GET_SIZE(o)))) {
   38069         357 :         PyObject *r = PyTuple_GET_ITEM(o, wrapped_i);
   38070         357 :         Py_INCREF(r);
   38071         357 :         return r;
   38072             :     }
   38073           0 :     return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
   38074             : #else
   38075             :     return PySequence_GetItem(o, i);
   38076             : #endif
   38077             : }
   38078           0 : static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list,
   38079             :                                                      CYTHON_NCP_UNUSED int wraparound,
   38080             :                                                      CYTHON_NCP_UNUSED int boundscheck) {
   38081             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
   38082           0 :     if (is_list || PyList_CheckExact(o)) {
   38083           0 :         Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
   38084           0 :         if ((!boundscheck) || (likely(__Pyx_is_valid_index(n, PyList_GET_SIZE(o))))) {
   38085           0 :             PyObject *r = PyList_GET_ITEM(o, n);
   38086           0 :             Py_INCREF(r);
   38087           0 :             return r;
   38088             :         }
   38089             :     }
   38090           0 :     else if (PyTuple_CheckExact(o)) {
   38091           0 :         Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
   38092           0 :         if ((!boundscheck) || likely(__Pyx_is_valid_index(n, PyTuple_GET_SIZE(o)))) {
   38093           0 :             PyObject *r = PyTuple_GET_ITEM(o, n);
   38094           0 :             Py_INCREF(r);
   38095           0 :             return r;
   38096             :         }
   38097             :     } else {
   38098           0 :         PyMappingMethods *mm = Py_TYPE(o)->tp_as_mapping;
   38099           0 :         PySequenceMethods *sm = Py_TYPE(o)->tp_as_sequence;
   38100           0 :         if (mm && mm->mp_subscript) {
   38101           0 :             PyObject *r, *key = PyInt_FromSsize_t(i);
   38102           0 :             if (unlikely(!key)) return NULL;
   38103           0 :             r = mm->mp_subscript(o, key);
   38104           0 :             Py_DECREF(key);
   38105           0 :             return r;
   38106             :         }
   38107           0 :         if (likely(sm && sm->sq_item)) {
   38108           0 :             if (wraparound && unlikely(i < 0) && likely(sm->sq_length)) {
   38109           0 :                 Py_ssize_t l = sm->sq_length(o);
   38110           0 :                 if (likely(l >= 0)) {
   38111           0 :                     i += l;
   38112             :                 } else {
   38113           0 :                     if (!PyErr_ExceptionMatches(PyExc_OverflowError))
   38114             :                         return NULL;
   38115           0 :                     PyErr_Clear();
   38116             :                 }
   38117             :             }
   38118           0 :             return sm->sq_item(o, i);
   38119             :         }
   38120             :     }
   38121             : #else
   38122             :     if (is_list || !PyMapping_Check(o)) {
   38123             :         return PySequence_GetItem(o, i);
   38124             :     }
   38125             : #endif
   38126           0 :     return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
   38127             : }
   38128             : 
   38129             : /* PyObjectCallOneArg */
   38130           6 : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
   38131           6 :     PyObject *args[2] = {NULL, arg};
   38132           6 :     return __Pyx_PyObject_FastCall(func, args+1, 1 | __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET);
   38133             : }
   38134             : 
   38135             : /* ObjectGetItem */
   38136             : #if CYTHON_USE_TYPE_SLOTS
   38137           0 : static PyObject *__Pyx_PyObject_GetIndex(PyObject *obj, PyObject *index) {
   38138           0 :     PyObject *runerr = NULL;
   38139           0 :     Py_ssize_t key_value;
   38140           0 :     key_value = __Pyx_PyIndex_AsSsize_t(index);
   38141           0 :     if (likely(key_value != -1 || !(runerr = PyErr_Occurred()))) {
   38142           0 :         return __Pyx_GetItemInt_Fast(obj, key_value, 0, 1, 1);
   38143             :     }
   38144           0 :     if (PyErr_GivenExceptionMatches(runerr, PyExc_OverflowError)) {
   38145           0 :         __Pyx_TypeName index_type_name = __Pyx_PyType_GetName(Py_TYPE(index));
   38146           0 :         PyErr_Clear();
   38147           0 :         PyErr_Format(PyExc_IndexError,
   38148             :             "cannot fit '" __Pyx_FMT_TYPENAME "' into an index-sized integer", index_type_name);
   38149             :         __Pyx_DECREF_TypeName(index_type_name);
   38150             :     }
   38151             :     return NULL;
   38152             : }
   38153           0 : static PyObject *__Pyx_PyObject_GetItem_Slow(PyObject *obj, PyObject *key) {
   38154           0 :     __Pyx_TypeName obj_type_name;
   38155           0 :     if (likely(PyType_Check(obj))) {
   38156           0 :         PyObject *meth = __Pyx_PyObject_GetAttrStrNoError(obj, __pyx_n_s_class_getitem);
   38157           0 :         if (!meth) {
   38158           0 :             PyErr_Clear();
   38159             :         } else {
   38160           0 :             PyObject *result = __Pyx_PyObject_CallOneArg(meth, key);
   38161           0 :             Py_DECREF(meth);
   38162           0 :             return result;
   38163             :         }
   38164             :     }
   38165           0 :     obj_type_name = __Pyx_PyType_GetName(Py_TYPE(obj));
   38166           0 :     PyErr_Format(PyExc_TypeError,
   38167             :         "'" __Pyx_FMT_TYPENAME "' object is not subscriptable", obj_type_name);
   38168           0 :     __Pyx_DECREF_TypeName(obj_type_name);
   38169           0 :     return NULL;
   38170             : }
   38171         357 : static PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject *key) {
   38172         357 :     PyTypeObject *tp = Py_TYPE(obj);
   38173         357 :     PyMappingMethods *mm = tp->tp_as_mapping;
   38174         357 :     PySequenceMethods *sm = tp->tp_as_sequence;
   38175         357 :     if (likely(mm && mm->mp_subscript)) {
   38176         357 :         return mm->mp_subscript(obj, key);
   38177             :     }
   38178           0 :     if (likely(sm && sm->sq_item)) {
   38179           0 :         return __Pyx_PyObject_GetIndex(obj, key);
   38180             :     }
   38181           0 :     return __Pyx_PyObject_GetItem_Slow(obj, key);
   38182             : }
   38183             : #endif
   38184             : 
   38185             : /* KeywordStringCheck */
   38186           0 : static int __Pyx_CheckKeywordStrings(
   38187             :     PyObject *kw,
   38188             :     const char* function_name,
   38189             :     int kw_allowed)
   38190             : {
   38191           0 :     PyObject* key = 0;
   38192           0 :     Py_ssize_t pos = 0;
   38193             : #if CYTHON_COMPILING_IN_PYPY
   38194             :     if (!kw_allowed && PyDict_Next(kw, &pos, &key, 0))
   38195             :         goto invalid_keyword;
   38196             :     return 1;
   38197             : #else
   38198           0 :     if (CYTHON_METH_FASTCALL && likely(PyTuple_Check(kw))) {
   38199           0 :         Py_ssize_t kwsize;
   38200             : #if CYTHON_ASSUME_SAFE_MACROS
   38201           0 :         kwsize = PyTuple_GET_SIZE(kw);
   38202             : #else
   38203             :         kwsize = PyTuple_Size(kw);
   38204             :         if (kwsize < 0) return 0;
   38205             : #endif
   38206           0 :         if (unlikely(kwsize == 0))
   38207             :             return 1;
   38208           0 :         if (!kw_allowed) {
   38209             : #if CYTHON_ASSUME_SAFE_MACROS
   38210           0 :             key = PyTuple_GET_ITEM(kw, 0);
   38211             : #else
   38212             :             key = PyTuple_GetItem(kw, pos);
   38213             :             if (!key) return 0;
   38214             : #endif
   38215           0 :             goto invalid_keyword;
   38216             :         }
   38217             : #if PY_VERSION_HEX < 0x03090000
   38218             :         for (pos = 0; pos < kwsize; pos++) {
   38219             : #if CYTHON_ASSUME_SAFE_MACROS
   38220             :             key = PyTuple_GET_ITEM(kw, pos);
   38221             : #else
   38222             :             key = PyTuple_GetItem(kw, pos);
   38223             :             if (!key) return 0;
   38224             : #endif
   38225             :             if (unlikely(!PyUnicode_Check(key)))
   38226             :                 goto invalid_keyword_type;
   38227             :         }
   38228             : #endif
   38229             :         return 1;
   38230             :     }
   38231           0 :     while (PyDict_Next(kw, &pos, &key, 0)) {
   38232             :         #if PY_MAJOR_VERSION < 3
   38233             :         if (unlikely(!PyString_Check(key)))
   38234             :         #endif
   38235           0 :             if (unlikely(!PyUnicode_Check(key)))
   38236           0 :                 goto invalid_keyword_type;
   38237             :     }
   38238           0 :     if (!kw_allowed && unlikely(key))
   38239           0 :         goto invalid_keyword;
   38240             :     return 1;
   38241           0 : invalid_keyword_type:
   38242           0 :     PyErr_Format(PyExc_TypeError,
   38243             :         "%.200s() keywords must be strings", function_name);
   38244           0 :     return 0;
   38245             : #endif
   38246           0 : invalid_keyword:
   38247             :     #if PY_MAJOR_VERSION < 3
   38248             :     PyErr_Format(PyExc_TypeError,
   38249             :         "%.200s() got an unexpected keyword argument '%.200s'",
   38250             :         function_name, PyString_AsString(key));
   38251             :     #else
   38252           0 :     PyErr_Format(PyExc_TypeError,
   38253             :         "%s() got an unexpected keyword argument '%U'",
   38254             :         function_name, key);
   38255             :     #endif
   38256           0 :     return 0;
   38257             : }
   38258             : 
   38259             : /* DivInt[Py_ssize_t] */
   38260           0 : static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t a, Py_ssize_t b) {
   38261           0 :     Py_ssize_t q = a / b;
   38262           0 :     Py_ssize_t r = a - q*b;
   38263           0 :     q -= ((r != 0) & ((r ^ b) < 0));
   38264           0 :     return q;
   38265             : }
   38266             : 
   38267             : /* GetAttr3 */
   38268             : #if __PYX_LIMITED_VERSION_HEX < 0x030d00A1
   38269           0 : static PyObject *__Pyx_GetAttr3Default(PyObject *d) {
   38270           0 :     __Pyx_PyThreadState_declare
   38271           0 :     __Pyx_PyThreadState_assign
   38272           0 :     if (unlikely(!__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
   38273             :         return NULL;
   38274           0 :     __Pyx_PyErr_Clear();
   38275           0 :     Py_INCREF(d);
   38276             :     return d;
   38277             : }
   38278             : #endif
   38279           0 : static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *o, PyObject *n, PyObject *d) {
   38280           0 :     PyObject *r;
   38281             : #if __PYX_LIMITED_VERSION_HEX >= 0x030d00A1
   38282             :     int res = PyObject_GetOptionalAttr(o, n, &r);
   38283             :     return (res != 0) ? r : __Pyx_NewRef(d);
   38284             : #else
   38285             :   #if CYTHON_USE_TYPE_SLOTS
   38286           0 :     if (likely(PyString_Check(n))) {
   38287           0 :         r = __Pyx_PyObject_GetAttrStrNoError(o, n);
   38288           0 :         if (unlikely(!r) && likely(!PyErr_Occurred())) {
   38289           0 :             r = __Pyx_NewRef(d);
   38290             :         }
   38291           0 :         return r;
   38292             :     }
   38293             :   #endif
   38294           0 :     r = PyObject_GetAttr(o, n);
   38295           0 :     return (likely(r)) ? r : __Pyx_GetAttr3Default(d);
   38296             : #endif
   38297             : }
   38298             : 
   38299             : /* PyDictVersioning */
   38300             : #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
   38301             : static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj) {
   38302             :     PyObject *dict = Py_TYPE(obj)->tp_dict;
   38303             :     return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
   38304             : }
   38305             : static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj) {
   38306             :     PyObject **dictptr = NULL;
   38307             :     Py_ssize_t offset = Py_TYPE(obj)->tp_dictoffset;
   38308             :     if (offset) {
   38309             : #if CYTHON_COMPILING_IN_CPYTHON
   38310             :         dictptr = (likely(offset > 0)) ? (PyObject **) ((char *)obj + offset) : _PyObject_GetDictPtr(obj);
   38311             : #else
   38312             :         dictptr = _PyObject_GetDictPtr(obj);
   38313             : #endif
   38314             :     }
   38315             :     return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
   38316             : }
   38317             : static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version) {
   38318             :     PyObject *dict = Py_TYPE(obj)->tp_dict;
   38319             :     if (unlikely(!dict) || unlikely(tp_dict_version != __PYX_GET_DICT_VERSION(dict)))
   38320             :         return 0;
   38321             :     return obj_dict_version == __Pyx_get_object_dict_version(obj);
   38322             : }
   38323             : #endif
   38324             : 
   38325             : /* GetModuleGlobalName */
   38326             : #if CYTHON_USE_DICT_VERSIONS
   38327             : static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value)
   38328             : #else
   38329        1555 : static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name)
   38330             : #endif
   38331             : {
   38332        1555 :     PyObject *result;
   38333             : #if !CYTHON_AVOID_BORROWED_REFS
   38334             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && PY_VERSION_HEX < 0x030d0000
   38335        1555 :     result = _PyDict_GetItem_KnownHash(__pyx_d, name, ((PyASCIIObject *) name)->hash);
   38336             :     __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
   38337        1555 :     if (likely(result)) {
   38338        3110 :         return __Pyx_NewRef(result);
   38339           0 :     } else if (unlikely(PyErr_Occurred())) {
   38340             :         return NULL;
   38341             :     }
   38342             : #elif CYTHON_COMPILING_IN_LIMITED_API
   38343             :     if (unlikely(!__pyx_m)) {
   38344             :         return NULL;
   38345             :     }
   38346             :     result = PyObject_GetAttr(__pyx_m, name);
   38347             :     if (likely(result)) {
   38348             :         return result;
   38349             :     }
   38350             : #else
   38351             :     result = PyDict_GetItem(__pyx_d, name);
   38352             :     __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
   38353             :     if (likely(result)) {
   38354             :         return __Pyx_NewRef(result);
   38355             :     }
   38356             : #endif
   38357             : #else
   38358             :     result = PyObject_GetItem(__pyx_d, name);
   38359             :     __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
   38360             :     if (likely(result)) {
   38361             :         return __Pyx_NewRef(result);
   38362             :     }
   38363             :     PyErr_Clear();
   38364             : #endif
   38365           0 :     return __Pyx_GetBuiltinName(name);
   38366             : }
   38367             : 
   38368             : /* RaiseTooManyValuesToUnpack */
   38369           0 : static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
   38370           0 :     PyErr_Format(PyExc_ValueError,
   38371             :                  "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T "d)", expected);
   38372           0 : }
   38373             : 
   38374             : /* RaiseNeedMoreValuesToUnpack */
   38375           0 : static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
   38376           0 :     PyErr_Format(PyExc_ValueError,
   38377             :                  "need more than %" CYTHON_FORMAT_SSIZE_T "d value%.1s to unpack",
   38378             :                  index, (index == 1) ? "" : "s");
   38379           0 : }
   38380             : 
   38381             : /* RaiseNoneIterError */
   38382           0 : static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) {
   38383           0 :     PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
   38384           0 : }
   38385             : 
   38386             : /* ExtTypeTest */
   38387         722 : static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type) {
   38388         722 :     __Pyx_TypeName obj_type_name;
   38389         722 :     __Pyx_TypeName type_name;
   38390         722 :     if (unlikely(!type)) {
   38391           0 :         PyErr_SetString(PyExc_SystemError, "Missing type object");
   38392           0 :         return 0;
   38393             :     }
   38394         722 :     if (likely(__Pyx_TypeCheck(obj, type)))
   38395             :         return 1;
   38396           0 :     obj_type_name = __Pyx_PyType_GetName(Py_TYPE(obj));
   38397           0 :     type_name = __Pyx_PyType_GetName(type);
   38398           0 :     PyErr_Format(PyExc_TypeError,
   38399             :                  "Cannot convert " __Pyx_FMT_TYPENAME " to " __Pyx_FMT_TYPENAME,
   38400             :                  obj_type_name, type_name);
   38401           0 :     __Pyx_DECREF_TypeName(obj_type_name);
   38402           0 :     __Pyx_DECREF_TypeName(type_name);
   38403           0 :     return 0;
   38404             : }
   38405             : 
   38406             : /* GetTopmostException */
   38407             : #if CYTHON_USE_EXC_INFO_STACK && CYTHON_FAST_THREAD_STATE
   38408             : static _PyErr_StackItem *
   38409         134 : __Pyx_PyErr_GetTopmostException(PyThreadState *tstate)
   38410             : {
   38411         134 :     _PyErr_StackItem *exc_info = tstate->exc_info;
   38412         189 :     while ((exc_info->exc_value == NULL || exc_info->exc_value == Py_None) &&
   38413         189 :            exc_info->previous_item != NULL)
   38414             :     {
   38415             :         exc_info = exc_info->previous_item;
   38416             :     }
   38417         134 :     return exc_info;
   38418             : }
   38419             : #endif
   38420             : 
   38421             : /* SaveResetException */
   38422             : #if CYTHON_FAST_THREAD_STATE
   38423         134 : static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
   38424             :   #if CYTHON_USE_EXC_INFO_STACK && PY_VERSION_HEX >= 0x030B00a4
   38425         134 :     _PyErr_StackItem *exc_info = __Pyx_PyErr_GetTopmostException(tstate);
   38426         134 :     PyObject *exc_value = exc_info->exc_value;
   38427         134 :     if (exc_value == NULL || exc_value == Py_None) {
   38428         134 :         *value = NULL;
   38429         134 :         *type = NULL;
   38430         134 :         *tb = NULL;
   38431             :     } else {
   38432           0 :         *value = exc_value;
   38433           0 :         Py_INCREF(*value);
   38434           0 :         *type = (PyObject*) Py_TYPE(exc_value);
   38435           0 :         Py_INCREF(*type);
   38436           0 :         *tb = PyException_GetTraceback(exc_value);
   38437             :     }
   38438             :   #elif CYTHON_USE_EXC_INFO_STACK
   38439             :     _PyErr_StackItem *exc_info = __Pyx_PyErr_GetTopmostException(tstate);
   38440             :     *type = exc_info->exc_type;
   38441             :     *value = exc_info->exc_value;
   38442             :     *tb = exc_info->exc_traceback;
   38443             :     Py_XINCREF(*type);
   38444             :     Py_XINCREF(*value);
   38445             :     Py_XINCREF(*tb);
   38446             :   #else
   38447             :     *type = tstate->exc_type;
   38448             :     *value = tstate->exc_value;
   38449             :     *tb = tstate->exc_traceback;
   38450             :     Py_XINCREF(*type);
   38451             :     Py_XINCREF(*value);
   38452             :     Py_XINCREF(*tb);
   38453             :   #endif
   38454         134 : }
   38455           0 : static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
   38456             :   #if CYTHON_USE_EXC_INFO_STACK && PY_VERSION_HEX >= 0x030B00a4
   38457           0 :     _PyErr_StackItem *exc_info = tstate->exc_info;
   38458           0 :     PyObject *tmp_value = exc_info->exc_value;
   38459           0 :     exc_info->exc_value = value;
   38460           0 :     Py_XDECREF(tmp_value);
   38461           0 :     Py_XDECREF(type);
   38462           0 :     Py_XDECREF(tb);
   38463             :   #else
   38464             :     PyObject *tmp_type, *tmp_value, *tmp_tb;
   38465             :     #if CYTHON_USE_EXC_INFO_STACK
   38466             :     _PyErr_StackItem *exc_info = tstate->exc_info;
   38467             :     tmp_type = exc_info->exc_type;
   38468             :     tmp_value = exc_info->exc_value;
   38469             :     tmp_tb = exc_info->exc_traceback;
   38470             :     exc_info->exc_type = type;
   38471             :     exc_info->exc_value = value;
   38472             :     exc_info->exc_traceback = tb;
   38473             :     #else
   38474             :     tmp_type = tstate->exc_type;
   38475             :     tmp_value = tstate->exc_value;
   38476             :     tmp_tb = tstate->exc_traceback;
   38477             :     tstate->exc_type = type;
   38478             :     tstate->exc_value = value;
   38479             :     tstate->exc_traceback = tb;
   38480             :     #endif
   38481             :     Py_XDECREF(tmp_type);
   38482             :     Py_XDECREF(tmp_value);
   38483             :     Py_XDECREF(tmp_tb);
   38484             :   #endif
   38485           0 : }
   38486             : #endif
   38487             : 
   38488             : /* GetException */
   38489             : #if CYTHON_FAST_THREAD_STATE
   38490           0 : static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb)
   38491             : #else
   38492             : static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb)
   38493             : #endif
   38494             : {
   38495           0 :     PyObject *local_type = NULL, *local_value, *local_tb = NULL;
   38496             : #if CYTHON_FAST_THREAD_STATE
   38497           0 :     PyObject *tmp_type, *tmp_value, *tmp_tb;
   38498             :   #if PY_VERSION_HEX >= 0x030C00A6
   38499           0 :     local_value = tstate->current_exception;
   38500           0 :     tstate->current_exception = 0;
   38501           0 :     if (likely(local_value)) {
   38502           0 :         local_type = (PyObject*) Py_TYPE(local_value);
   38503           0 :         Py_INCREF(local_type);
   38504           0 :         local_tb = PyException_GetTraceback(local_value);
   38505             :     }
   38506             :   #else
   38507             :     local_type = tstate->curexc_type;
   38508             :     local_value = tstate->curexc_value;
   38509             :     local_tb = tstate->curexc_traceback;
   38510             :     tstate->curexc_type = 0;
   38511             :     tstate->curexc_value = 0;
   38512             :     tstate->curexc_traceback = 0;
   38513             :   #endif
   38514             : #else
   38515             :     PyErr_Fetch(&local_type, &local_value, &local_tb);
   38516             : #endif
   38517           0 :     PyErr_NormalizeException(&local_type, &local_value, &local_tb);
   38518             : #if CYTHON_FAST_THREAD_STATE && PY_VERSION_HEX >= 0x030C00A6
   38519           0 :     if (unlikely(tstate->current_exception))
   38520             : #elif CYTHON_FAST_THREAD_STATE
   38521             :     if (unlikely(tstate->curexc_type))
   38522             : #else
   38523             :     if (unlikely(PyErr_Occurred()))
   38524             : #endif
   38525           0 :         goto bad;
   38526             :     #if PY_MAJOR_VERSION >= 3
   38527           0 :     if (local_tb) {
   38528           0 :         if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
   38529           0 :             goto bad;
   38530             :     }
   38531             :     #endif
   38532           0 :     Py_XINCREF(local_tb);
   38533           0 :     Py_XINCREF(local_type);
   38534           0 :     Py_XINCREF(local_value);
   38535           0 :     *type = local_type;
   38536           0 :     *value = local_value;
   38537           0 :     *tb = local_tb;
   38538             : #if CYTHON_FAST_THREAD_STATE
   38539             :     #if CYTHON_USE_EXC_INFO_STACK
   38540             :     {
   38541           0 :         _PyErr_StackItem *exc_info = tstate->exc_info;
   38542             :       #if PY_VERSION_HEX >= 0x030B00a4
   38543           0 :         tmp_value = exc_info->exc_value;
   38544           0 :         exc_info->exc_value = local_value;
   38545           0 :         tmp_type = NULL;
   38546           0 :         tmp_tb = NULL;
   38547           0 :         Py_XDECREF(local_type);
   38548           0 :         Py_XDECREF(local_tb);
   38549             :       #else
   38550             :         tmp_type = exc_info->exc_type;
   38551             :         tmp_value = exc_info->exc_value;
   38552             :         tmp_tb = exc_info->exc_traceback;
   38553             :         exc_info->exc_type = local_type;
   38554             :         exc_info->exc_value = local_value;
   38555             :         exc_info->exc_traceback = local_tb;
   38556             :       #endif
   38557             :     }
   38558             :     #else
   38559             :     tmp_type = tstate->exc_type;
   38560             :     tmp_value = tstate->exc_value;
   38561             :     tmp_tb = tstate->exc_traceback;
   38562             :     tstate->exc_type = local_type;
   38563             :     tstate->exc_value = local_value;
   38564             :     tstate->exc_traceback = local_tb;
   38565             :     #endif
   38566           0 :     Py_XDECREF(tmp_type);
   38567           0 :     Py_XDECREF(tmp_value);
   38568           0 :     Py_XDECREF(tmp_tb);
   38569             : #else
   38570             :     PyErr_SetExcInfo(local_type, local_value, local_tb);
   38571             : #endif
   38572           0 :     return 0;
   38573           0 : bad:
   38574           0 :     *type = 0;
   38575           0 :     *value = 0;
   38576           0 :     *tb = 0;
   38577           0 :     Py_XDECREF(local_type);
   38578           0 :     Py_XDECREF(local_value);
   38579           0 :     Py_XDECREF(local_tb);
   38580           0 :     return -1;
   38581             : }
   38582             : 
   38583             : /* SwapException */
   38584             : #if CYTHON_FAST_THREAD_STATE
   38585           0 : static CYTHON_INLINE void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
   38586           0 :     PyObject *tmp_type, *tmp_value, *tmp_tb;
   38587             :   #if CYTHON_USE_EXC_INFO_STACK && PY_VERSION_HEX >= 0x030B00a4
   38588           0 :     _PyErr_StackItem *exc_info = tstate->exc_info;
   38589           0 :     tmp_value = exc_info->exc_value;
   38590           0 :     exc_info->exc_value = *value;
   38591           0 :     if (tmp_value == NULL || tmp_value == Py_None) {
   38592           0 :         Py_XDECREF(tmp_value);
   38593           0 :         tmp_value = NULL;
   38594           0 :         tmp_type = NULL;
   38595           0 :         tmp_tb = NULL;
   38596             :     } else {
   38597           0 :         tmp_type = (PyObject*) Py_TYPE(tmp_value);
   38598           0 :         Py_INCREF(tmp_type);
   38599             :         #if CYTHON_COMPILING_IN_CPYTHON
   38600           0 :         tmp_tb = ((PyBaseExceptionObject*) tmp_value)->traceback;
   38601           0 :         Py_XINCREF(tmp_tb);
   38602             :         #else
   38603             :         tmp_tb = PyException_GetTraceback(tmp_value);
   38604             :         #endif
   38605             :     }
   38606             :   #elif CYTHON_USE_EXC_INFO_STACK
   38607             :     _PyErr_StackItem *exc_info = tstate->exc_info;
   38608             :     tmp_type = exc_info->exc_type;
   38609             :     tmp_value = exc_info->exc_value;
   38610             :     tmp_tb = exc_info->exc_traceback;
   38611             :     exc_info->exc_type = *type;
   38612             :     exc_info->exc_value = *value;
   38613             :     exc_info->exc_traceback = *tb;
   38614             :   #else
   38615             :     tmp_type = tstate->exc_type;
   38616             :     tmp_value = tstate->exc_value;
   38617             :     tmp_tb = tstate->exc_traceback;
   38618             :     tstate->exc_type = *type;
   38619             :     tstate->exc_value = *value;
   38620             :     tstate->exc_traceback = *tb;
   38621             :   #endif
   38622           0 :     *type = tmp_type;
   38623           0 :     *value = tmp_value;
   38624           0 :     *tb = tmp_tb;
   38625           0 : }
   38626             : #else
   38627             : static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb) {
   38628             :     PyObject *tmp_type, *tmp_value, *tmp_tb;
   38629             :     PyErr_GetExcInfo(&tmp_type, &tmp_value, &tmp_tb);
   38630             :     PyErr_SetExcInfo(*type, *value, *tb);
   38631             :     *type = tmp_type;
   38632             :     *value = tmp_value;
   38633             :     *tb = tmp_tb;
   38634             : }
   38635             : #endif
   38636             : 
   38637             : /* Import */
   38638           1 : static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) {
   38639           1 :     PyObject *module = 0;
   38640           1 :     PyObject *empty_dict = 0;
   38641           1 :     PyObject *empty_list = 0;
   38642             :     #if PY_MAJOR_VERSION < 3
   38643             :     PyObject *py_import;
   38644             :     py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
   38645             :     if (unlikely(!py_import))
   38646             :         goto bad;
   38647             :     if (!from_list) {
   38648             :         empty_list = PyList_New(0);
   38649             :         if (unlikely(!empty_list))
   38650             :             goto bad;
   38651             :         from_list = empty_list;
   38652             :     }
   38653             :     #endif
   38654           1 :     empty_dict = PyDict_New();
   38655           1 :     if (unlikely(!empty_dict))
   38656           0 :         goto bad;
   38657             :     {
   38658             :         #if PY_MAJOR_VERSION >= 3
   38659           1 :         if (level == -1) {
   38660           0 :             if (strchr(__Pyx_MODULE_NAME, '.') != NULL) {
   38661             :                 module = PyImport_ImportModuleLevelObject(
   38662             :                     name, __pyx_d, empty_dict, from_list, 1);
   38663             :                 if (unlikely(!module)) {
   38664             :                     if (unlikely(!PyErr_ExceptionMatches(PyExc_ImportError)))
   38665             :                         goto bad;
   38666             :                     PyErr_Clear();
   38667             :                 }
   38668             :             }
   38669           0 :             level = 0;
   38670             :         }
   38671             :         #endif
   38672           1 :         if (!module) {
   38673             :             #if PY_MAJOR_VERSION < 3
   38674             :             PyObject *py_level = PyInt_FromLong(level);
   38675             :             if (unlikely(!py_level))
   38676             :                 goto bad;
   38677             :             module = PyObject_CallFunctionObjArgs(py_import,
   38678             :                 name, __pyx_d, empty_dict, from_list, py_level, (PyObject *)NULL);
   38679             :             Py_DECREF(py_level);
   38680             :             #else
   38681           1 :             module = PyImport_ImportModuleLevelObject(
   38682           1 :                 name, __pyx_d, empty_dict, from_list, level);
   38683             :             #endif
   38684             :         }
   38685             :     }
   38686           1 : bad:
   38687           1 :     Py_XDECREF(empty_dict);
   38688           1 :     Py_XDECREF(empty_list);
   38689             :     #if PY_MAJOR_VERSION < 3
   38690             :     Py_XDECREF(py_import);
   38691             :     #endif
   38692           1 :     return module;
   38693             : }
   38694             : 
   38695             : /* ImportDottedModule */
   38696             : #if PY_MAJOR_VERSION >= 3
   38697           0 : static PyObject *__Pyx__ImportDottedModule_Error(PyObject *name, PyObject *parts_tuple, Py_ssize_t count) {
   38698           0 :     PyObject *partial_name = NULL, *slice = NULL, *sep = NULL;
   38699           0 :     if (unlikely(PyErr_Occurred())) {
   38700           0 :         PyErr_Clear();
   38701             :     }
   38702           0 :     if (likely(PyTuple_GET_SIZE(parts_tuple) == count)) {
   38703             :         partial_name = name;
   38704             :     } else {
   38705           0 :         slice = PySequence_GetSlice(parts_tuple, 0, count);
   38706           0 :         if (unlikely(!slice))
   38707           0 :             goto bad;
   38708           0 :         sep = PyUnicode_FromStringAndSize(".", 1);
   38709           0 :         if (unlikely(!sep))
   38710           0 :             goto bad;
   38711           0 :         partial_name = PyUnicode_Join(sep, slice);
   38712             :     }
   38713           0 :     PyErr_Format(
   38714             : #if PY_MAJOR_VERSION < 3
   38715             :         PyExc_ImportError,
   38716             :         "No module named '%s'", PyString_AS_STRING(partial_name));
   38717             : #else
   38718             : #if PY_VERSION_HEX >= 0x030600B1
   38719             :         PyExc_ModuleNotFoundError,
   38720             : #else
   38721             :         PyExc_ImportError,
   38722             : #endif
   38723             :         "No module named '%U'", partial_name);
   38724             : #endif
   38725           0 : bad:
   38726           0 :     Py_XDECREF(sep);
   38727           0 :     Py_XDECREF(slice);
   38728           0 :     Py_XDECREF(partial_name);
   38729           0 :     return NULL;
   38730             : }
   38731             : #endif
   38732             : #if PY_MAJOR_VERSION >= 3
   38733           3 : static PyObject *__Pyx__ImportDottedModule_Lookup(PyObject *name) {
   38734           3 :     PyObject *imported_module;
   38735             : #if PY_VERSION_HEX < 0x030700A1 || (CYTHON_COMPILING_IN_PYPY && PYPY_VERSION_NUM  < 0x07030400)
   38736             :     PyObject *modules = PyImport_GetModuleDict();
   38737             :     if (unlikely(!modules))
   38738             :         return NULL;
   38739             :     imported_module = __Pyx_PyDict_GetItemStr(modules, name);
   38740             :     Py_XINCREF(imported_module);
   38741             : #else
   38742           6 :     imported_module = PyImport_GetModule(name);
   38743             : #endif
   38744           3 :     return imported_module;
   38745             : }
   38746             : #endif
   38747             : #if PY_MAJOR_VERSION >= 3
   38748           0 : static PyObject *__Pyx_ImportDottedModule_WalkParts(PyObject *module, PyObject *name, PyObject *parts_tuple) {
   38749           0 :     Py_ssize_t i, nparts;
   38750           0 :     nparts = PyTuple_GET_SIZE(parts_tuple);
   38751           0 :     for (i=1; i < nparts && module; i++) {
   38752           0 :         PyObject *part, *submodule;
   38753             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   38754           0 :         part = PyTuple_GET_ITEM(parts_tuple, i);
   38755             : #else
   38756             :         part = PySequence_ITEM(parts_tuple, i);
   38757             : #endif
   38758           0 :         submodule = __Pyx_PyObject_GetAttrStrNoError(module, part);
   38759             : #if !(CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS)
   38760             :         Py_DECREF(part);
   38761             : #endif
   38762           0 :         Py_DECREF(module);
   38763           0 :         module = submodule;
   38764             :     }
   38765           0 :     if (unlikely(!module)) {
   38766           0 :         return __Pyx__ImportDottedModule_Error(name, parts_tuple, i);
   38767             :     }
   38768             :     return module;
   38769             : }
   38770             : #endif
   38771           0 : static PyObject *__Pyx__ImportDottedModule(PyObject *name, PyObject *parts_tuple) {
   38772             : #if PY_MAJOR_VERSION < 3
   38773             :     PyObject *module, *from_list, *star = __pyx_n_s__3;
   38774             :     CYTHON_UNUSED_VAR(parts_tuple);
   38775             :     from_list = PyList_New(1);
   38776             :     if (unlikely(!from_list))
   38777             :         return NULL;
   38778             :     Py_INCREF(star);
   38779             :     PyList_SET_ITEM(from_list, 0, star);
   38780             :     module = __Pyx_Import(name, from_list, 0);
   38781             :     Py_DECREF(from_list);
   38782             :     return module;
   38783             : #else
   38784           0 :     PyObject *imported_module;
   38785           0 :     PyObject *module = __Pyx_Import(name, NULL, 0);
   38786           0 :     if (!parts_tuple || unlikely(!module))
   38787             :         return module;
   38788           0 :     imported_module = __Pyx__ImportDottedModule_Lookup(name);
   38789           0 :     if (likely(imported_module)) {
   38790           0 :         Py_DECREF(module);
   38791           0 :         return imported_module;
   38792             :     }
   38793           0 :     PyErr_Clear();
   38794           0 :     return __Pyx_ImportDottedModule_WalkParts(module, name, parts_tuple);
   38795             : #endif
   38796             : }
   38797           3 : static PyObject *__Pyx_ImportDottedModule(PyObject *name, PyObject *parts_tuple) {
   38798             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030400B1
   38799           3 :     PyObject *module = __Pyx__ImportDottedModule_Lookup(name);
   38800           3 :     if (likely(module)) {
   38801           3 :         PyObject *spec = __Pyx_PyObject_GetAttrStrNoError(module, __pyx_n_s_spec);
   38802           3 :         if (likely(spec)) {
   38803           3 :             PyObject *unsafe = __Pyx_PyObject_GetAttrStrNoError(spec, __pyx_n_s_initializing);
   38804           3 :             if (likely(!unsafe || !__Pyx_PyObject_IsTrue(unsafe))) {
   38805           3 :                 Py_DECREF(spec);
   38806             :                 spec = NULL;
   38807             :             }
   38808           3 :             Py_XDECREF(unsafe);
   38809             :         }
   38810           3 :         if (likely(!spec)) {
   38811           3 :             PyErr_Clear();
   38812           3 :             return module;
   38813             :         }
   38814           0 :         Py_DECREF(spec);
   38815           0 :         Py_DECREF(module);
   38816           0 :     } else if (PyErr_Occurred()) {
   38817           0 :         PyErr_Clear();
   38818             :     }
   38819             : #endif
   38820           0 :     return __Pyx__ImportDottedModule(name, parts_tuple);
   38821             : }
   38822             : 
   38823             : /* FastTypeChecks */
   38824             : #if CYTHON_COMPILING_IN_CPYTHON
   38825             : static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
   38826           0 :     while (a) {
   38827           0 :         a = __Pyx_PyType_GetSlot(a, tp_base, PyTypeObject*);
   38828           0 :         if (a == b)
   38829             :             return 1;
   38830             :     }
   38831           0 :     return b == &PyBaseObject_Type;
   38832             : }
   38833        1079 : static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
   38834        1079 :     PyObject *mro;
   38835        1079 :     if (a == b) return 1;
   38836           0 :     mro = a->tp_mro;
   38837           0 :     if (likely(mro)) {
   38838           0 :         Py_ssize_t i, n;
   38839           0 :         n = PyTuple_GET_SIZE(mro);
   38840           0 :         for (i = 0; i < n; i++) {
   38841           0 :             if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
   38842             :                 return 1;
   38843             :         }
   38844             :         return 0;
   38845             :     }
   38846        1079 :     return __Pyx_InBases(a, b);
   38847             : }
   38848        1018 : static CYTHON_INLINE int __Pyx_IsAnySubtype2(PyTypeObject *cls, PyTypeObject *a, PyTypeObject *b) {
   38849        1018 :     PyObject *mro;
   38850        1018 :     if (cls == a || cls == b) return 1;
   38851         482 :     mro = cls->tp_mro;
   38852         482 :     if (likely(mro)) {
   38853         482 :         Py_ssize_t i, n;
   38854         482 :         n = PyTuple_GET_SIZE(mro);
   38855        1089 :         for (i = 0; i < n; i++) {
   38856         964 :             PyObject *base = PyTuple_GET_ITEM(mro, i);
   38857         964 :             if (base == (PyObject *)a || base == (PyObject *)b)
   38858             :                 return 1;
   38859             :         }
   38860             :         return 0;
   38861             :     }
   38862           0 :     return __Pyx_InBases(cls, a) || __Pyx_InBases(cls, b);
   38863             : }
   38864             : #if PY_MAJOR_VERSION == 2
   38865             : static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
   38866             :     PyObject *exception, *value, *tb;
   38867             :     int res;
   38868             :     __Pyx_PyThreadState_declare
   38869             :     __Pyx_PyThreadState_assign
   38870             :     __Pyx_ErrFetch(&exception, &value, &tb);
   38871             :     res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
   38872             :     if (unlikely(res == -1)) {
   38873             :         PyErr_WriteUnraisable(err);
   38874             :         res = 0;
   38875             :     }
   38876             :     if (!res) {
   38877             :         res = PyObject_IsSubclass(err, exc_type2);
   38878             :         if (unlikely(res == -1)) {
   38879             :             PyErr_WriteUnraisable(err);
   38880             :             res = 0;
   38881             :         }
   38882             :     }
   38883             :     __Pyx_ErrRestore(exception, value, tb);
   38884             :     return res;
   38885             : }
   38886             : #else
   38887           0 : static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
   38888           0 :     if (exc_type1) {
   38889           0 :         return __Pyx_IsAnySubtype2((PyTypeObject*)err, (PyTypeObject*)exc_type1, (PyTypeObject*)exc_type2);
   38890             :     } else {
   38891           0 :         return __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
   38892             :     }
   38893             : }
   38894             : #endif
   38895           0 : static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
   38896           0 :     Py_ssize_t i, n;
   38897           0 :     assert(PyExceptionClass_Check(exc_type));
   38898           0 :     n = PyTuple_GET_SIZE(tuple);
   38899             : #if PY_MAJOR_VERSION >= 3
   38900           0 :     for (i=0; i<n; i++) {
   38901           0 :         if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
   38902             :     }
   38903             : #endif
   38904           0 :     for (i=0; i<n; i++) {
   38905           0 :         PyObject *t = PyTuple_GET_ITEM(tuple, i);
   38906             :         #if PY_MAJOR_VERSION < 3
   38907             :         if (likely(exc_type == t)) return 1;
   38908             :         #endif
   38909           0 :         if (likely(PyExceptionClass_Check(t))) {
   38910           0 :             if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t)) return 1;
   38911             :         } else {
   38912           0 :         }
   38913             :     }
   38914             :     return 0;
   38915             : }
   38916           0 : static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
   38917           0 :     if (likely(err == exc_type)) return 1;
   38918           0 :     if (likely(PyExceptionClass_Check(err))) {
   38919           0 :         if (likely(PyExceptionClass_Check(exc_type))) {
   38920           0 :             return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
   38921           0 :         } else if (likely(PyTuple_Check(exc_type))) {
   38922           0 :             return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
   38923             :         } else {
   38924           0 :         }
   38925             :     }
   38926           0 :     return PyErr_GivenExceptionMatches(err, exc_type);
   38927             : }
   38928           0 : static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
   38929           0 :     assert(PyExceptionClass_Check(exc_type1));
   38930           0 :     assert(PyExceptionClass_Check(exc_type2));
   38931           0 :     if (likely(err == exc_type1 || err == exc_type2)) return 1;
   38932           0 :     if (likely(PyExceptionClass_Check(err))) {
   38933           0 :         return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
   38934             :     }
   38935           0 :     return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
   38936             : }
   38937             : #endif
   38938             : 
   38939             : /* PySequenceMultiply */
   38940           0 : static PyObject* __Pyx_PySequence_Multiply_Generic(PyObject *seq, Py_ssize_t mul) {
   38941           0 :     PyObject *result, *pymul = PyInt_FromSsize_t(mul);
   38942           0 :     if (unlikely(!pymul))
   38943             :         return NULL;
   38944           0 :     result = PyNumber_Multiply(seq, pymul);
   38945           0 :     Py_DECREF(pymul);
   38946             :     return result;
   38947             : }
   38948           0 : static CYTHON_INLINE PyObject* __Pyx_PySequence_Multiply(PyObject *seq, Py_ssize_t mul) {
   38949             : #if CYTHON_USE_TYPE_SLOTS
   38950           0 :     PyTypeObject *type = Py_TYPE(seq);
   38951           0 :     if (likely(type->tp_as_sequence && type->tp_as_sequence->sq_repeat)) {
   38952           0 :         return type->tp_as_sequence->sq_repeat(seq, mul);
   38953             :     } else
   38954             : #endif
   38955             :     {
   38956           0 :         return __Pyx_PySequence_Multiply_Generic(seq, mul);
   38957             :     }
   38958             : }
   38959             : 
   38960             : /* SetItemInt */
   38961           0 : static int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v) {
   38962           0 :     int r;
   38963           0 :     if (unlikely(!j)) return -1;
   38964           0 :     r = PyObject_SetItem(o, j, v);
   38965           0 :     Py_DECREF(j);
   38966             :     return r;
   38967             : }
   38968         476 : static CYTHON_INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v, int is_list,
   38969             :                                                CYTHON_NCP_UNUSED int wraparound, CYTHON_NCP_UNUSED int boundscheck) {
   38970             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
   38971         476 :     if (is_list || PyList_CheckExact(o)) {
   38972         476 :         Py_ssize_t n = (!wraparound) ? i : ((likely(i >= 0)) ? i : i + PyList_GET_SIZE(o));
   38973         476 :         if ((!boundscheck) || likely(__Pyx_is_valid_index(n, PyList_GET_SIZE(o)))) {
   38974         476 :             PyObject* old = PyList_GET_ITEM(o, n);
   38975         476 :             Py_INCREF(v);
   38976         476 :             PyList_SET_ITEM(o, n, v);
   38977         476 :             Py_DECREF(old);
   38978         476 :             return 1;
   38979             :         }
   38980             :     } else {
   38981           0 :         PyMappingMethods *mm = Py_TYPE(o)->tp_as_mapping;
   38982           0 :         PySequenceMethods *sm = Py_TYPE(o)->tp_as_sequence;
   38983           0 :         if (mm && mm->mp_ass_subscript) {
   38984           0 :             int r;
   38985           0 :             PyObject *key = PyInt_FromSsize_t(i);
   38986           0 :             if (unlikely(!key)) return -1;
   38987           0 :             r = mm->mp_ass_subscript(o, key, v);
   38988           0 :             Py_DECREF(key);
   38989           0 :             return r;
   38990             :         }
   38991           0 :         if (likely(sm && sm->sq_ass_item)) {
   38992           0 :             if (wraparound && unlikely(i < 0) && likely(sm->sq_length)) {
   38993           0 :                 Py_ssize_t l = sm->sq_length(o);
   38994           0 :                 if (likely(l >= 0)) {
   38995           0 :                     i += l;
   38996             :                 } else {
   38997           0 :                     if (!PyErr_ExceptionMatches(PyExc_OverflowError))
   38998             :                         return -1;
   38999           0 :                     PyErr_Clear();
   39000             :                 }
   39001             :             }
   39002           0 :             return sm->sq_ass_item(o, i, v);
   39003             :         }
   39004             :     }
   39005             : #else
   39006             :     if (is_list || !PyMapping_Check(o))
   39007             :     {
   39008             :         return PySequence_SetItem(o, i, v);
   39009             :     }
   39010             : #endif
   39011           0 :     return __Pyx_SetItemInt_Generic(o, PyInt_FromSsize_t(i), v);
   39012             : }
   39013             : 
   39014             : /* RaiseUnboundLocalError */
   39015           0 : static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname) {
   39016           0 :     PyErr_Format(PyExc_UnboundLocalError, "local variable '%s' referenced before assignment", varname);
   39017             : }
   39018             : 
   39019             : /* DivInt[long] */
   39020           0 : static CYTHON_INLINE long __Pyx_div_long(long a, long b) {
   39021           0 :     long q = a / b;
   39022           0 :     long r = a - q*b;
   39023           0 :     q -= ((r != 0) & ((r ^ b) < 0));
   39024           0 :     return q;
   39025             : }
   39026             : 
   39027             : /* ImportFrom */
   39028           0 : static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) {
   39029           0 :     PyObject* value = __Pyx_PyObject_GetAttrStr(module, name);
   39030           0 :     if (unlikely(!value) && PyErr_ExceptionMatches(PyExc_AttributeError)) {
   39031           0 :         const char* module_name_str = 0;
   39032           0 :         PyObject* module_name = 0;
   39033           0 :         PyObject* module_dot = 0;
   39034           0 :         PyObject* full_name = 0;
   39035           0 :         PyErr_Clear();
   39036           0 :         module_name_str = PyModule_GetName(module);
   39037           0 :         if (unlikely(!module_name_str)) { goto modbad; }
   39038           0 :         module_name = PyUnicode_FromString(module_name_str);
   39039           0 :         if (unlikely(!module_name)) { goto modbad; }
   39040           0 :         module_dot = PyUnicode_Concat(module_name, __pyx_kp_u__2);
   39041           0 :         if (unlikely(!module_dot)) { goto modbad; }
   39042           0 :         full_name = PyUnicode_Concat(module_dot, name);
   39043           0 :         if (unlikely(!full_name)) { goto modbad; }
   39044             :         #if PY_VERSION_HEX < 0x030700A1 || (CYTHON_COMPILING_IN_PYPY && PYPY_VERSION_NUM  < 0x07030400)
   39045             :         {
   39046             :             PyObject *modules = PyImport_GetModuleDict();
   39047             :             if (unlikely(!modules))
   39048             :                 goto modbad;
   39049             :             value = PyObject_GetItem(modules, full_name);
   39050             :         }
   39051             :         #else
   39052           0 :         value = PyImport_GetModule(full_name);
   39053             :         #endif
   39054           0 :       modbad:
   39055           0 :         Py_XDECREF(full_name);
   39056           0 :         Py_XDECREF(module_dot);
   39057           0 :         Py_XDECREF(module_name);
   39058             :     }
   39059           0 :     if (unlikely(!value)) {
   39060           0 :         PyErr_Format(PyExc_ImportError,
   39061             :         #if PY_MAJOR_VERSION < 3
   39062             :             "cannot import name %.230s", PyString_AS_STRING(name));
   39063             :         #else
   39064             :             "cannot import name %S", name);
   39065             :         #endif
   39066             :     }
   39067           0 :     return value;
   39068             : }
   39069             : 
   39070             : /* HasAttr */
   39071           0 : static CYTHON_INLINE int __Pyx_HasAttr(PyObject *o, PyObject *n) {
   39072           0 :     PyObject *r;
   39073           0 :     if (unlikely(!__Pyx_PyBaseString_Check(n))) {
   39074           0 :         PyErr_SetString(PyExc_TypeError,
   39075             :                         "hasattr(): attribute name must be string");
   39076           0 :         return -1;
   39077             :     }
   39078           0 :     r = __Pyx_GetAttr(o, n);
   39079           0 :     if (!r) {
   39080           0 :         PyErr_Clear();
   39081           0 :         return 0;
   39082             :     } else {
   39083           0 :         Py_DECREF(r);
   39084           0 :         return 1;
   39085             :     }
   39086             : }
   39087             : 
   39088             : /* DictGetItem */
   39089             : #if PY_MAJOR_VERSION >= 3 && !CYTHON_COMPILING_IN_PYPY
   39090         357 : static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key) {
   39091         357 :     PyObject *value;
   39092         357 :     value = PyDict_GetItemWithError(d, key);
   39093         357 :     if (unlikely(!value)) {
   39094           0 :         if (!PyErr_Occurred()) {
   39095           0 :             if (unlikely(PyTuple_Check(key))) {
   39096           0 :                 PyObject* args = PyTuple_Pack(1, key);
   39097           0 :                 if (likely(args)) {
   39098           0 :                     PyErr_SetObject(PyExc_KeyError, args);
   39099           0 :                     Py_DECREF(args);
   39100             :                 }
   39101             :             } else {
   39102           0 :                 PyErr_SetObject(PyExc_KeyError, key);
   39103             :             }
   39104             :         }
   39105           0 :         return NULL;
   39106             :     }
   39107         357 :     Py_INCREF(value);
   39108             :     return value;
   39109             : }
   39110             : #endif
   39111             : 
   39112             : /* UnicodeAsUCS4 */
   39113         357 : static CYTHON_INLINE Py_UCS4 __Pyx_PyUnicode_AsPy_UCS4(PyObject* x) {
   39114         357 :    Py_ssize_t length;
   39115             :    #if CYTHON_PEP393_ENABLED
   39116         357 :    length = PyUnicode_GET_LENGTH(x);
   39117         357 :    if (likely(length == 1)) {
   39118         357 :        return PyUnicode_READ_CHAR(x, 0);
   39119             :    }
   39120             :    #else
   39121             :    length = PyUnicode_GET_SIZE(x);
   39122             :    if (likely(length == 1)) {
   39123             :        return PyUnicode_AS_UNICODE(x)[0];
   39124             :    }
   39125             :    #if Py_UNICODE_SIZE == 2
   39126             :    else if (PyUnicode_GET_SIZE(x) == 2) {
   39127             :        Py_UCS4 high_val = PyUnicode_AS_UNICODE(x)[0];
   39128             :        if (high_val >= 0xD800 && high_val <= 0xDBFF) {
   39129             :            Py_UCS4 low_val = PyUnicode_AS_UNICODE(x)[1];
   39130             :            if (low_val >= 0xDC00 && low_val <= 0xDFFF) {
   39131             :                return 0x10000 + (((high_val & ((1<<10)-1)) << 10) | (low_val & ((1<<10)-1)));
   39132             :            }
   39133             :        }
   39134             :    }
   39135             :    #endif
   39136             :    #endif
   39137           0 :    PyErr_Format(PyExc_ValueError,
   39138             :                 "only single character unicode strings can be converted to Py_UCS4, "
   39139             :                 "got length %" CYTHON_FORMAT_SSIZE_T "d", length);
   39140           0 :    return (Py_UCS4)-1;
   39141             : }
   39142             : 
   39143             : /* object_ord */
   39144           0 : static long __Pyx__PyObject_Ord(PyObject* c) {
   39145           0 :     Py_ssize_t size;
   39146           0 :     if (PyBytes_Check(c)) {
   39147           0 :         size = PyBytes_GET_SIZE(c);
   39148           0 :         if (likely(size == 1)) {
   39149           0 :             return (unsigned char) PyBytes_AS_STRING(c)[0];
   39150             :         }
   39151             : #if PY_MAJOR_VERSION < 3
   39152             :     } else if (PyUnicode_Check(c)) {
   39153             :         return (long)__Pyx_PyUnicode_AsPy_UCS4(c);
   39154             : #endif
   39155             : #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
   39156           0 :     } else if (PyByteArray_Check(c)) {
   39157           0 :         size = PyByteArray_GET_SIZE(c);
   39158           0 :         if (likely(size == 1)) {
   39159           0 :             return (unsigned char) PyByteArray_AS_STRING(c)[0];
   39160             :         }
   39161             : #endif
   39162             :     } else {
   39163           0 :         __Pyx_TypeName c_type_name = __Pyx_PyType_GetName(Py_TYPE(c));
   39164           0 :         PyErr_Format(PyExc_TypeError,
   39165             :             "ord() expected string of length 1, but " __Pyx_FMT_TYPENAME " found",
   39166             :             c_type_name);
   39167           0 :         __Pyx_DECREF_TypeName(c_type_name);
   39168           0 :         return (long)(Py_UCS4)-1;
   39169             :     }
   39170           0 :     PyErr_Format(PyExc_TypeError,
   39171             :         "ord() expected a character, but string of length %zd found", size);
   39172           0 :     return (long)(Py_UCS4)-1;
   39173             : }
   39174             : 
   39175             : /* memoryview_get_from_buffer */
   39176             : #if !CYTHON_COMPILING_IN_LIMITED_API || CYTHON_LIMITED_API >= 0x030b0000
   39177             : #else
   39178             : static Py_ssize_t __Pyx_PyMemoryView_Get_itemsize(PyObject *obj) {
   39179             :     Py_ssize_t result;
   39180             :     PyObject *attr = PyObject_GetAttr(obj, __pyx_n_s_itemsize);
   39181             :     if (!attr) {
   39182             :         goto bad;
   39183             :     }
   39184             :     result = PyLong_AsSsize_t(attr);
   39185             :     Py_DECREF(attr);
   39186             :     return result;
   39187             :     bad:
   39188             :     Py_XDECREF(attr);
   39189             :     return -1;
   39190             : }
   39191             : #endif
   39192             : 
   39193             : /* memoryview_get_from_buffer */
   39194             : #if !CYTHON_COMPILING_IN_LIMITED_API || CYTHON_LIMITED_API >= 0x030b0000
   39195             : #else
   39196             : static int __Pyx_PyMemoryView_Get_ndim(PyObject *obj) {
   39197             :     int result;
   39198             :     PyObject *attr = PyObject_GetAttr(obj, __pyx_n_s_ndim);
   39199             :     if (!attr) {
   39200             :         goto bad;
   39201             :     }
   39202             :     result = PyLong_AsLong(attr);
   39203             :     Py_DECREF(attr);
   39204             :     return result;
   39205             :     bad:
   39206             :     Py_XDECREF(attr);
   39207             :     return -1;
   39208             : }
   39209             : #endif
   39210             : 
   39211             : /* IterFinish */
   39212           0 : static CYTHON_INLINE int __Pyx_IterFinish(void) {
   39213           0 :     PyObject* exc_type;
   39214           0 :     __Pyx_PyThreadState_declare
   39215           0 :     __Pyx_PyThreadState_assign
   39216           0 :     exc_type = __Pyx_PyErr_CurrentExceptionType();
   39217           0 :     if (unlikely(exc_type)) {
   39218           0 :         if (unlikely(!__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration)))
   39219             :             return -1;
   39220           0 :         __Pyx_PyErr_Clear();
   39221           0 :         return 0;
   39222             :     }
   39223             :     return 0;
   39224             : }
   39225             : 
   39226             : /* PyObjectCallNoArg */
   39227             : static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) {
   39228             :     PyObject *arg[2] = {NULL, NULL};
   39229             :     return __Pyx_PyObject_FastCall(func, arg + 1, 0 | __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET);
   39230             : }
   39231             : 
   39232             : /* PyObjectGetMethod */
   39233             : static int __Pyx_PyObject_GetMethod(PyObject *obj, PyObject *name, PyObject **method) {
   39234             :     PyObject *attr;
   39235             : #if CYTHON_UNPACK_METHODS && CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_PYTYPE_LOOKUP
   39236             :     __Pyx_TypeName type_name;
   39237             :     PyTypeObject *tp = Py_TYPE(obj);
   39238             :     PyObject *descr;
   39239             :     descrgetfunc f = NULL;
   39240             :     PyObject **dictptr, *dict;
   39241             :     int meth_found = 0;
   39242             :     assert (*method == NULL);
   39243             :     if (unlikely(tp->tp_getattro != PyObject_GenericGetAttr)) {
   39244             :         attr = __Pyx_PyObject_GetAttrStr(obj, name);
   39245             :         goto try_unpack;
   39246             :     }
   39247             :     if (unlikely(tp->tp_dict == NULL) && unlikely(PyType_Ready(tp) < 0)) {
   39248             :         return 0;
   39249             :     }
   39250             :     descr = _PyType_Lookup(tp, name);
   39251             :     if (likely(descr != NULL)) {
   39252             :         Py_INCREF(descr);
   39253             : #if defined(Py_TPFLAGS_METHOD_DESCRIPTOR) && Py_TPFLAGS_METHOD_DESCRIPTOR
   39254             :         if (__Pyx_PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_METHOD_DESCRIPTOR))
   39255             : #elif PY_MAJOR_VERSION >= 3
   39256             :         #ifdef __Pyx_CyFunction_USED
   39257             :         if (likely(PyFunction_Check(descr) || __Pyx_IS_TYPE(descr, &PyMethodDescr_Type) || __Pyx_CyFunction_Check(descr)))
   39258             :         #else
   39259             :         if (likely(PyFunction_Check(descr) || __Pyx_IS_TYPE(descr, &PyMethodDescr_Type)))
   39260             :         #endif
   39261             : #else
   39262             :         #ifdef __Pyx_CyFunction_USED
   39263             :         if (likely(PyFunction_Check(descr) || __Pyx_CyFunction_Check(descr)))
   39264             :         #else
   39265             :         if (likely(PyFunction_Check(descr)))
   39266             :         #endif
   39267             : #endif
   39268             :         {
   39269             :             meth_found = 1;
   39270             :         } else {
   39271             :             f = Py_TYPE(descr)->tp_descr_get;
   39272             :             if (f != NULL && PyDescr_IsData(descr)) {
   39273             :                 attr = f(descr, obj, (PyObject *)Py_TYPE(obj));
   39274             :                 Py_DECREF(descr);
   39275             :                 goto try_unpack;
   39276             :             }
   39277             :         }
   39278             :     }
   39279             :     dictptr = _PyObject_GetDictPtr(obj);
   39280             :     if (dictptr != NULL && (dict = *dictptr) != NULL) {
   39281             :         Py_INCREF(dict);
   39282             :         attr = __Pyx_PyDict_GetItemStr(dict, name);
   39283             :         if (attr != NULL) {
   39284             :             Py_INCREF(attr);
   39285             :             Py_DECREF(dict);
   39286             :             Py_XDECREF(descr);
   39287             :             goto try_unpack;
   39288             :         }
   39289             :         Py_DECREF(dict);
   39290             :     }
   39291             :     if (meth_found) {
   39292             :         *method = descr;
   39293             :         return 1;
   39294             :     }
   39295             :     if (f != NULL) {
   39296             :         attr = f(descr, obj, (PyObject *)Py_TYPE(obj));
   39297             :         Py_DECREF(descr);
   39298             :         goto try_unpack;
   39299             :     }
   39300             :     if (likely(descr != NULL)) {
   39301             :         *method = descr;
   39302             :         return 0;
   39303             :     }
   39304             :     type_name = __Pyx_PyType_GetName(tp);
   39305             :     PyErr_Format(PyExc_AttributeError,
   39306             : #if PY_MAJOR_VERSION >= 3
   39307             :                  "'" __Pyx_FMT_TYPENAME "' object has no attribute '%U'",
   39308             :                  type_name, name);
   39309             : #else
   39310             :                  "'" __Pyx_FMT_TYPENAME "' object has no attribute '%.400s'",
   39311             :                  type_name, PyString_AS_STRING(name));
   39312             : #endif
   39313             :     __Pyx_DECREF_TypeName(type_name);
   39314             :     return 0;
   39315             : #else
   39316             :     attr = __Pyx_PyObject_GetAttrStr(obj, name);
   39317             :     goto try_unpack;
   39318             : #endif
   39319             : try_unpack:
   39320             : #if CYTHON_UNPACK_METHODS
   39321             :     if (likely(attr) && PyMethod_Check(attr) && likely(PyMethod_GET_SELF(attr) == obj)) {
   39322             :         PyObject *function = PyMethod_GET_FUNCTION(attr);
   39323             :         Py_INCREF(function);
   39324             :         Py_DECREF(attr);
   39325             :         *method = function;
   39326             :         return 1;
   39327             :     }
   39328             : #endif
   39329             :     *method = attr;
   39330             :     return 0;
   39331             : }
   39332             : 
   39333             : /* PyObjectCallMethod0 */
   39334             : static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name) {
   39335             :     PyObject *method = NULL, *result = NULL;
   39336             :     int is_method = __Pyx_PyObject_GetMethod(obj, method_name, &method);
   39337             :     if (likely(is_method)) {
   39338             :         result = __Pyx_PyObject_CallOneArg(method, obj);
   39339             :         Py_DECREF(method);
   39340             :         return result;
   39341             :     }
   39342             :     if (unlikely(!method)) goto bad;
   39343             :     result = __Pyx_PyObject_CallNoArg(method);
   39344             :     Py_DECREF(method);
   39345             : bad:
   39346             :     return result;
   39347             : }
   39348             : 
   39349             : /* UnpackItemEndCheck */
   39350           0 : static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) {
   39351           0 :     if (unlikely(retval)) {
   39352           0 :         Py_DECREF(retval);
   39353           0 :         __Pyx_RaiseTooManyValuesError(expected);
   39354           0 :         return -1;
   39355             :     }
   39356           0 :     return __Pyx_IterFinish();
   39357             : }
   39358             : 
   39359             : /* UnpackTupleError */
   39360           0 : static void __Pyx_UnpackTupleError(PyObject *t, Py_ssize_t index) {
   39361           0 :     if (t == Py_None) {
   39362           0 :       __Pyx_RaiseNoneNotIterableError();
   39363           0 :     } else if (PyTuple_GET_SIZE(t) < index) {
   39364           0 :       __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(t));
   39365             :     } else {
   39366           0 :       __Pyx_RaiseTooManyValuesError(index);
   39367             :     }
   39368           0 : }
   39369             : 
   39370             : /* UnpackTuple2 */
   39371           0 : static CYTHON_INLINE int __Pyx_unpack_tuple2_exact(
   39372             :         PyObject* tuple, PyObject** pvalue1, PyObject** pvalue2, int decref_tuple) {
   39373           0 :     PyObject *value1 = NULL, *value2 = NULL;
   39374             : #if CYTHON_COMPILING_IN_PYPY
   39375             :     value1 = PySequence_ITEM(tuple, 0);  if (unlikely(!value1)) goto bad;
   39376             :     value2 = PySequence_ITEM(tuple, 1);  if (unlikely(!value2)) goto bad;
   39377             : #else
   39378           0 :     value1 = PyTuple_GET_ITEM(tuple, 0);  Py_INCREF(value1);
   39379           0 :     value2 = PyTuple_GET_ITEM(tuple, 1);  Py_INCREF(value2);
   39380             : #endif
   39381           0 :     if (decref_tuple) {
   39382           0 :         Py_DECREF(tuple);
   39383             :     }
   39384           0 :     *pvalue1 = value1;
   39385           0 :     *pvalue2 = value2;
   39386           0 :     return 0;
   39387             : #if CYTHON_COMPILING_IN_PYPY
   39388             : bad:
   39389             :     Py_XDECREF(value1);
   39390             :     Py_XDECREF(value2);
   39391             :     if (decref_tuple) { Py_XDECREF(tuple); }
   39392             :     return -1;
   39393             : #endif
   39394             : }
   39395           0 : static int __Pyx_unpack_tuple2_generic(PyObject* tuple, PyObject** pvalue1, PyObject** pvalue2,
   39396             :                                        int has_known_size, int decref_tuple) {
   39397           0 :     Py_ssize_t index;
   39398           0 :     PyObject *value1 = NULL, *value2 = NULL, *iter = NULL;
   39399           0 :     iternextfunc iternext;
   39400           0 :     iter = PyObject_GetIter(tuple);
   39401           0 :     if (unlikely(!iter)) goto bad;
   39402           0 :     if (decref_tuple) { Py_DECREF(tuple); tuple = NULL; }
   39403           0 :     iternext = __Pyx_PyObject_GetIterNextFunc(iter);
   39404           0 :     value1 = iternext(iter); if (unlikely(!value1)) { index = 0; goto unpacking_failed; }
   39405           0 :     value2 = iternext(iter); if (unlikely(!value2)) { index = 1; goto unpacking_failed; }
   39406           0 :     if (!has_known_size && unlikely(__Pyx_IternextUnpackEndCheck(iternext(iter), 2))) goto bad;
   39407           0 :     Py_DECREF(iter);
   39408           0 :     *pvalue1 = value1;
   39409           0 :     *pvalue2 = value2;
   39410           0 :     return 0;
   39411           0 : unpacking_failed:
   39412           0 :     if (!has_known_size && __Pyx_IterFinish() == 0)
   39413           0 :         __Pyx_RaiseNeedMoreValuesError(index);
   39414           0 : bad:
   39415           0 :     Py_XDECREF(iter);
   39416           0 :     Py_XDECREF(value1);
   39417           0 :     Py_XDECREF(value2);
   39418           0 :     if (decref_tuple) { Py_XDECREF(tuple); }
   39419             :     return -1;
   39420             : }
   39421             : 
   39422             : /* dict_iter */
   39423             : #if CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
   39424             : #include <string.h>
   39425             : #endif
   39426           3 : static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* iterable, int is_dict, PyObject* method_name,
   39427             :                                                    Py_ssize_t* p_orig_length, int* p_source_is_dict) {
   39428           3 :     is_dict = is_dict || likely(PyDict_CheckExact(iterable));
   39429           3 :     *p_source_is_dict = is_dict;
   39430           3 :     if (is_dict) {
   39431             : #if !CYTHON_COMPILING_IN_PYPY
   39432           3 :         *p_orig_length = PyDict_Size(iterable);
   39433           3 :         Py_INCREF(iterable);
   39434           3 :         return iterable;
   39435             : #elif PY_MAJOR_VERSION >= 3
   39436             :         static PyObject *py_items = NULL, *py_keys = NULL, *py_values = NULL;
   39437             :         PyObject **pp = NULL;
   39438             :         if (method_name) {
   39439             :             const char *name = PyUnicode_AsUTF8(method_name);
   39440             :             if (strcmp(name, "iteritems") == 0) pp = &py_items;
   39441             :             else if (strcmp(name, "iterkeys") == 0) pp = &py_keys;
   39442             :             else if (strcmp(name, "itervalues") == 0) pp = &py_values;
   39443             :             if (pp) {
   39444             :                 if (!*pp) {
   39445             :                     *pp = PyUnicode_FromString(name + 4);
   39446             :                     if (!*pp)
   39447             :                         return NULL;
   39448             :                 }
   39449             :                 method_name = *pp;
   39450             :             }
   39451             :         }
   39452             : #endif
   39453             :     }
   39454             :     *p_orig_length = 0;
   39455             :     if (method_name) {
   39456             :         PyObject* iter;
   39457             :         iterable = __Pyx_PyObject_CallMethod0(iterable, method_name);
   39458             :         if (!iterable)
   39459             :             return NULL;
   39460             : #if !CYTHON_COMPILING_IN_PYPY
   39461             :         if (PyTuple_CheckExact(iterable) || PyList_CheckExact(iterable))
   39462             :             return iterable;
   39463             : #endif
   39464             :         iter = PyObject_GetIter(iterable);
   39465             :         Py_DECREF(iterable);
   39466             :         return iter;
   39467             :     }
   39468             :     return PyObject_GetIter(iterable);
   39469             : }
   39470          33 : static CYTHON_INLINE int __Pyx_dict_iter_next(
   39471             :         PyObject* iter_obj, CYTHON_NCP_UNUSED Py_ssize_t orig_length, CYTHON_NCP_UNUSED Py_ssize_t* ppos,
   39472             :         PyObject** pkey, PyObject** pvalue, PyObject** pitem, int source_is_dict) {
   39473          33 :     PyObject* next_item;
   39474             : #if !CYTHON_COMPILING_IN_PYPY
   39475          33 :     if (source_is_dict) {
   39476          33 :         PyObject *key, *value;
   39477          33 :         if (unlikely(orig_length != PyDict_Size(iter_obj))) {
   39478           0 :             PyErr_SetString(PyExc_RuntimeError, "dictionary changed size during iteration");
   39479           0 :             return -1;
   39480             :         }
   39481          33 :         if (unlikely(!PyDict_Next(iter_obj, ppos, &key, &value))) {
   39482             :             return 0;
   39483             :         }
   39484          30 :         if (pitem) {
   39485           0 :             PyObject* tuple = PyTuple_New(2);
   39486           0 :             if (unlikely(!tuple)) {
   39487             :                 return -1;
   39488             :             }
   39489           0 :             Py_INCREF(key);
   39490           0 :             Py_INCREF(value);
   39491           0 :             PyTuple_SET_ITEM(tuple, 0, key);
   39492           0 :             PyTuple_SET_ITEM(tuple, 1, value);
   39493           0 :             *pitem = tuple;
   39494             :         } else {
   39495          30 :             if (pkey) {
   39496          30 :                 Py_INCREF(key);
   39497          30 :                 *pkey = key;
   39498             :             }
   39499          30 :             if (pvalue) {
   39500           0 :                 Py_INCREF(value);
   39501           0 :                 *pvalue = value;
   39502             :             }
   39503             :         }
   39504          30 :         return 1;
   39505           0 :     } else if (PyTuple_CheckExact(iter_obj)) {
   39506           0 :         Py_ssize_t pos = *ppos;
   39507           0 :         if (unlikely(pos >= PyTuple_GET_SIZE(iter_obj))) return 0;
   39508           0 :         *ppos = pos + 1;
   39509           0 :         next_item = PyTuple_GET_ITEM(iter_obj, pos);
   39510           0 :         Py_INCREF(next_item);
   39511           0 :     } else if (PyList_CheckExact(iter_obj)) {
   39512           0 :         Py_ssize_t pos = *ppos;
   39513           0 :         if (unlikely(pos >= PyList_GET_SIZE(iter_obj))) return 0;
   39514           0 :         *ppos = pos + 1;
   39515           0 :         next_item = PyList_GET_ITEM(iter_obj, pos);
   39516           0 :         Py_INCREF(next_item);
   39517             :     } else
   39518             : #endif
   39519             :     {
   39520           0 :         next_item = PyIter_Next(iter_obj);
   39521           0 :         if (unlikely(!next_item)) {
   39522           0 :             return __Pyx_IterFinish();
   39523             :         }
   39524             :     }
   39525           0 :     if (pitem) {
   39526           0 :         *pitem = next_item;
   39527           0 :     } else if (pkey && pvalue) {
   39528           0 :         if (__Pyx_unpack_tuple2(next_item, pkey, pvalue, source_is_dict, source_is_dict, 1))
   39529           0 :             return -1;
   39530           0 :     } else if (pkey) {
   39531           0 :         *pkey = next_item;
   39532             :     } else {
   39533           0 :         *pvalue = next_item;
   39534             :     }
   39535             :     return 1;
   39536             : }
   39537             : 
   39538             : /* UnpackUnboundCMethod */
   39539           0 : static PyObject *__Pyx_SelflessCall(PyObject *method, PyObject *args, PyObject *kwargs) {
   39540           0 :     PyObject *result;
   39541           0 :     PyObject *selfless_args = PyTuple_GetSlice(args, 1, PyTuple_Size(args));
   39542           0 :     if (unlikely(!selfless_args)) return NULL;
   39543           0 :     result = PyObject_Call(method, selfless_args, kwargs);
   39544           0 :     Py_DECREF(selfless_args);
   39545             :     return result;
   39546             : }
   39547             : static PyMethodDef __Pyx_UnboundCMethod_Def = {
   39548             :      "CythonUnboundCMethod",
   39549             :      __PYX_REINTERPRET_FUNCION(PyCFunction, __Pyx_SelflessCall),
   39550             :      METH_VARARGS | METH_KEYWORDS,
   39551             :      NULL
   39552             : };
   39553           0 : static int __Pyx_TryUnpackUnboundCMethod(__Pyx_CachedCFunction* target) {
   39554           0 :     PyObject *method;
   39555           0 :     method = __Pyx_PyObject_GetAttrStr(target->type, *target->method_name);
   39556           0 :     if (unlikely(!method))
   39557             :         return -1;
   39558           0 :     target->method = method;
   39559             : #if CYTHON_COMPILING_IN_CPYTHON
   39560             :     #if PY_MAJOR_VERSION >= 3
   39561           0 :     if (likely(__Pyx_TypeCheck(method, &PyMethodDescr_Type)))
   39562             :     #else
   39563             :     if (likely(!__Pyx_CyOrPyCFunction_Check(method)))
   39564             :     #endif
   39565             :     {
   39566           0 :         PyMethodDescrObject *descr = (PyMethodDescrObject*) method;
   39567           0 :         target->func = descr->d_method->ml_meth;
   39568           0 :         target->flag = descr->d_method->ml_flags & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_STACKLESS);
   39569             :     } else
   39570             : #endif
   39571             : #if CYTHON_COMPILING_IN_PYPY
   39572             : #else
   39573           0 :     if (PyCFunction_Check(method))
   39574             : #endif
   39575             :     {
   39576           0 :         PyObject *self;
   39577           0 :         int self_found;
   39578             : #if CYTHON_COMPILING_IN_LIMITED_API || CYTHON_COMPILING_IN_PYPY
   39579             :         self = PyObject_GetAttrString(method, "__self__");
   39580             :         if (!self) {
   39581             :             PyErr_Clear();
   39582             :         }
   39583             : #else
   39584           0 :         self = PyCFunction_GET_SELF(method);
   39585             : #endif
   39586           0 :         self_found = (self && self != Py_None);
   39587             : #if CYTHON_COMPILING_IN_LIMITED_API || CYTHON_COMPILING_IN_PYPY
   39588             :         Py_XDECREF(self);
   39589             : #endif
   39590           0 :         if (self_found) {
   39591           0 :             PyObject *unbound_method = PyCFunction_New(&__Pyx_UnboundCMethod_Def, method);
   39592           0 :             if (unlikely(!unbound_method)) return -1;
   39593           0 :             Py_DECREF(method);
   39594           0 :             target->method = unbound_method;
   39595             :         }
   39596             :     }
   39597             :     return 0;
   39598             : }
   39599             : 
   39600             : /* CallUnboundCMethod0 */
   39601           0 : static PyObject* __Pyx__CallUnboundCMethod0(__Pyx_CachedCFunction* cfunc, PyObject* self) {
   39602           0 :     PyObject *args, *result = NULL;
   39603           0 :     if (unlikely(!cfunc->method) && unlikely(__Pyx_TryUnpackUnboundCMethod(cfunc) < 0)) return NULL;
   39604             : #if CYTHON_ASSUME_SAFE_MACROS
   39605           0 :     args = PyTuple_New(1);
   39606           0 :     if (unlikely(!args)) goto bad;
   39607           0 :     Py_INCREF(self);
   39608           0 :     PyTuple_SET_ITEM(args, 0, self);
   39609             : #else
   39610             :     args = PyTuple_Pack(1, self);
   39611             :     if (unlikely(!args)) goto bad;
   39612             : #endif
   39613           0 :     result = __Pyx_PyObject_Call(cfunc->method, args, NULL);
   39614           0 :     Py_DECREF(args);
   39615             : bad:
   39616             :     return result;
   39617             : }
   39618             : 
   39619             : /* py_dict_values */
   39620           0 : static CYTHON_INLINE PyObject* __Pyx_PyDict_Values(PyObject* d) {
   39621           0 :     if (PY_MAJOR_VERSION >= 3)
   39622           0 :         return __Pyx_CallUnboundCMethod0(&__pyx_umethod_PyDict_Type_values, d);
   39623             :     else
   39624             :         return PyDict_Values(d);
   39625             : }
   39626             : 
   39627             : /* CallUnboundCMethod1 */
   39628             : #if CYTHON_COMPILING_IN_CPYTHON
   39629             : static CYTHON_INLINE PyObject* __Pyx_CallUnboundCMethod1(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg) {
   39630             :     if (likely(cfunc->func)) {
   39631             :         int flag = cfunc->flag;
   39632             :         if (flag == METH_O) {
   39633             :             return (*(cfunc->func))(self, arg);
   39634             :         } else if ((PY_VERSION_HEX >= 0x030600B1) && flag == METH_FASTCALL) {
   39635             :             #if PY_VERSION_HEX >= 0x030700A0
   39636             :                 return (*(__Pyx_PyCFunctionFast)(void*)(PyCFunction)cfunc->func)(self, &arg, 1);
   39637             :             #else
   39638             :                 return (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)cfunc->func)(self, &arg, 1, NULL);
   39639             :             #endif
   39640             :         } else if ((PY_VERSION_HEX >= 0x030700A0) && flag == (METH_FASTCALL | METH_KEYWORDS)) {
   39641             :             return (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)cfunc->func)(self, &arg, 1, NULL);
   39642             :         }
   39643             :     }
   39644             :     return __Pyx__CallUnboundCMethod1(cfunc, self, arg);
   39645             : }
   39646             : #endif
   39647             : static PyObject* __Pyx__CallUnboundCMethod1(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg){
   39648             :     PyObject *args, *result = NULL;
   39649             :     if (unlikely(!cfunc->func && !cfunc->method) && unlikely(__Pyx_TryUnpackUnboundCMethod(cfunc) < 0)) return NULL;
   39650             : #if CYTHON_COMPILING_IN_CPYTHON
   39651             :     if (cfunc->func && (cfunc->flag & METH_VARARGS)) {
   39652             :         args = PyTuple_New(1);
   39653             :         if (unlikely(!args)) goto bad;
   39654             :         Py_INCREF(arg);
   39655             :         PyTuple_SET_ITEM(args, 0, arg);
   39656             :         if (cfunc->flag & METH_KEYWORDS)
   39657             :             result = (*(PyCFunctionWithKeywords)(void*)(PyCFunction)cfunc->func)(self, args, NULL);
   39658             :         else
   39659             :             result = (*cfunc->func)(self, args);
   39660             :     } else {
   39661             :         args = PyTuple_New(2);
   39662             :         if (unlikely(!args)) goto bad;
   39663             :         Py_INCREF(self);
   39664             :         PyTuple_SET_ITEM(args, 0, self);
   39665             :         Py_INCREF(arg);
   39666             :         PyTuple_SET_ITEM(args, 1, arg);
   39667             :         result = __Pyx_PyObject_Call(cfunc->method, args, NULL);
   39668             :     }
   39669             : #else
   39670             :     args = PyTuple_Pack(2, self, arg);
   39671             :     if (unlikely(!args)) goto bad;
   39672             :     result = __Pyx_PyObject_Call(cfunc->method, args, NULL);
   39673             : #endif
   39674             : bad:
   39675             :     Py_XDECREF(args);
   39676             :     return result;
   39677             : }
   39678             : 
   39679             : /* CallUnboundCMethod2 */
   39680             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030600B1
   39681             : static CYTHON_INLINE PyObject *__Pyx_CallUnboundCMethod2(__Pyx_CachedCFunction *cfunc, PyObject *self, PyObject *arg1, PyObject *arg2) {
   39682             :     if (likely(cfunc->func)) {
   39683             :         PyObject *args[2] = {arg1, arg2};
   39684             :         if (cfunc->flag == METH_FASTCALL) {
   39685             :             #if PY_VERSION_HEX >= 0x030700A0
   39686             :             return (*(__Pyx_PyCFunctionFast)(void*)(PyCFunction)cfunc->func)(self, args, 2);
   39687             :             #else
   39688             :             return (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)cfunc->func)(self, args, 2, NULL);
   39689             :             #endif
   39690             :         }
   39691             :         #if PY_VERSION_HEX >= 0x030700A0
   39692             :         if (cfunc->flag == (METH_FASTCALL | METH_KEYWORDS))
   39693             :             return (*(__Pyx_PyCFunctionFastWithKeywords)(void*)(PyCFunction)cfunc->func)(self, args, 2, NULL);
   39694             :         #endif
   39695             :     }
   39696             :     return __Pyx__CallUnboundCMethod2(cfunc, self, arg1, arg2);
   39697             : }
   39698             : #endif
   39699             : static PyObject* __Pyx__CallUnboundCMethod2(__Pyx_CachedCFunction* cfunc, PyObject* self, PyObject* arg1, PyObject* arg2){
   39700             :     PyObject *args, *result = NULL;
   39701             :     if (unlikely(!cfunc->func && !cfunc->method) && unlikely(__Pyx_TryUnpackUnboundCMethod(cfunc) < 0)) return NULL;
   39702             : #if CYTHON_COMPILING_IN_CPYTHON
   39703             :     if (cfunc->func && (cfunc->flag & METH_VARARGS)) {
   39704             :         args = PyTuple_New(2);
   39705             :         if (unlikely(!args)) goto bad;
   39706             :         Py_INCREF(arg1);
   39707             :         PyTuple_SET_ITEM(args, 0, arg1);
   39708             :         Py_INCREF(arg2);
   39709             :         PyTuple_SET_ITEM(args, 1, arg2);
   39710             :         if (cfunc->flag & METH_KEYWORDS)
   39711             :             result = (*(PyCFunctionWithKeywords)(void*)(PyCFunction)cfunc->func)(self, args, NULL);
   39712             :         else
   39713             :             result = (*cfunc->func)(self, args);
   39714             :     } else {
   39715             :         args = PyTuple_New(3);
   39716             :         if (unlikely(!args)) goto bad;
   39717             :         Py_INCREF(self);
   39718             :         PyTuple_SET_ITEM(args, 0, self);
   39719             :         Py_INCREF(arg1);
   39720             :         PyTuple_SET_ITEM(args, 1, arg1);
   39721             :         Py_INCREF(arg2);
   39722             :         PyTuple_SET_ITEM(args, 2, arg2);
   39723             :         result = __Pyx_PyObject_Call(cfunc->method, args, NULL);
   39724             :     }
   39725             : #else
   39726             :     args = PyTuple_Pack(3, self, arg1, arg2);
   39727             :     if (unlikely(!args)) goto bad;
   39728             :     result = __Pyx_PyObject_Call(cfunc->method, args, NULL);
   39729             : #endif
   39730             : bad:
   39731             :     Py_XDECREF(args);
   39732             :     return result;
   39733             : }
   39734             : 
   39735             : /* dict_getitem_default */
   39736         357 : static PyObject* __Pyx_PyDict_GetItemDefault(PyObject* d, PyObject* key, PyObject* default_value) {
   39737         357 :     PyObject* value;
   39738             : #if PY_MAJOR_VERSION >= 3 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07020000)
   39739         357 :     value = PyDict_GetItemWithError(d, key);
   39740         357 :     if (unlikely(!value)) {
   39741           0 :         if (unlikely(PyErr_Occurred()))
   39742             :             return NULL;
   39743             :         value = default_value;
   39744             :     }
   39745         357 :     Py_INCREF(value);
   39746             :     if ((1));
   39747             : #else
   39748             :     if (PyString_CheckExact(key) || PyUnicode_CheckExact(key) || PyInt_CheckExact(key)) {
   39749             :         value = PyDict_GetItem(d, key);
   39750             :         if (unlikely(!value)) {
   39751             :             value = default_value;
   39752             :         }
   39753             :         Py_INCREF(value);
   39754             :     }
   39755             : #endif
   39756             :     else {
   39757             :         if (default_value == Py_None)
   39758             :             value = __Pyx_CallUnboundCMethod1(&__pyx_umethod_PyDict_Type_get, d, key);
   39759             :         else
   39760             :             value = __Pyx_CallUnboundCMethod2(&__pyx_umethod_PyDict_Type_get, d, key, default_value);
   39761             :     }
   39762             :     return value;
   39763             : }
   39764             : 
   39765             : /* IsLittleEndian */
   39766           0 : static CYTHON_INLINE int __Pyx_Is_Little_Endian(void)
   39767             : {
   39768           0 :   union {
   39769             :     uint32_t u32;
   39770             :     uint8_t u8[4];
   39771             :   } S;
   39772           0 :   S.u32 = 0x01020304;
   39773           0 :   return S.u8[0] == 4;
   39774             : }
   39775             : 
   39776             : /* BufferFormatCheck */
   39777         357 : static void __Pyx_BufFmt_Init(__Pyx_BufFmt_Context* ctx,
   39778             :                               __Pyx_BufFmt_StackElem* stack,
   39779             :                               __Pyx_TypeInfo* type) {
   39780         357 :   stack[0].field = &ctx->root;
   39781         357 :   stack[0].parent_offset = 0;
   39782         357 :   ctx->root.type = type;
   39783         357 :   ctx->root.name = "buffer dtype";
   39784         357 :   ctx->root.offset = 0;
   39785         357 :   ctx->head = stack;
   39786         357 :   ctx->head->field = &ctx->root;
   39787         357 :   ctx->fmt_offset = 0;
   39788         357 :   ctx->head->parent_offset = 0;
   39789         357 :   ctx->new_packmode = '@';
   39790         357 :   ctx->enc_packmode = '@';
   39791         357 :   ctx->new_count = 1;
   39792         357 :   ctx->enc_count = 0;
   39793         357 :   ctx->enc_type = 0;
   39794         357 :   ctx->is_complex = 0;
   39795         357 :   ctx->is_valid_array = 0;
   39796         357 :   ctx->struct_alignment = 0;
   39797         357 :   while (type->typegroup == 'S') {
   39798           0 :     ++ctx->head;
   39799           0 :     ctx->head->field = type->fields;
   39800           0 :     ctx->head->parent_offset = 0;
   39801           0 :     type = type->fields->type;
   39802             :   }
   39803         357 : }
   39804           0 : static int __Pyx_BufFmt_ParseNumber(const char** ts) {
   39805           0 :     int count;
   39806           0 :     const char* t = *ts;
   39807           0 :     if (*t < '0' || *t > '9') {
   39808             :       return -1;
   39809             :     } else {
   39810           0 :         count = *t++ - '0';
   39811           0 :         while (*t >= '0' && *t <= '9') {
   39812           0 :             count *= 10;
   39813           0 :             count += *t++ - '0';
   39814             :         }
   39815             :     }
   39816           0 :     *ts = t;
   39817           0 :     return count;
   39818             : }
   39819           0 : static int __Pyx_BufFmt_ExpectNumber(const char **ts) {
   39820           0 :     int number = __Pyx_BufFmt_ParseNumber(ts);
   39821           0 :     if (number == -1)
   39822           0 :         PyErr_Format(PyExc_ValueError,\
   39823           0 :                      "Does not understand character buffer dtype format string ('%c')", **ts);
   39824           0 :     return number;
   39825             : }
   39826           0 : static void __Pyx_BufFmt_RaiseUnexpectedChar(char ch) {
   39827           0 :   PyErr_Format(PyExc_ValueError,
   39828             :                "Unexpected format string character: '%c'", ch);
   39829             : }
   39830           0 : static const char* __Pyx_BufFmt_DescribeTypeChar(char ch, int is_complex) {
   39831           0 :   switch (ch) {
   39832             :     case '?': return "'bool'";
   39833           0 :     case 'c': return "'char'";
   39834           0 :     case 'b': return "'signed char'";
   39835           0 :     case 'B': return "'unsigned char'";
   39836           0 :     case 'h': return "'short'";
   39837           0 :     case 'H': return "'unsigned short'";
   39838           0 :     case 'i': return "'int'";
   39839           0 :     case 'I': return "'unsigned int'";
   39840           0 :     case 'l': return "'long'";
   39841           0 :     case 'L': return "'unsigned long'";
   39842           0 :     case 'q': return "'long long'";
   39843           0 :     case 'Q': return "'unsigned long long'";
   39844           0 :     case 'f': return (is_complex ? "'complex float'" : "'float'");
   39845           0 :     case 'd': return (is_complex ? "'complex double'" : "'double'");
   39846           0 :     case 'g': return (is_complex ? "'complex long double'" : "'long double'");
   39847           0 :     case 'T': return "a struct";
   39848           0 :     case 'O': return "Python object";
   39849           0 :     case 'P': return "a pointer";
   39850           0 :     case 's': case 'p': return "a string";
   39851           0 :     case 0: return "end";
   39852           0 :     default: return "unparsable format string";
   39853             :   }
   39854             : }
   39855           0 : static size_t __Pyx_BufFmt_TypeCharToStandardSize(char ch, int is_complex) {
   39856           0 :   switch (ch) {
   39857             :     case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
   39858           0 :     case 'h': case 'H': return 2;
   39859             :     case 'i': case 'I': case 'l': case 'L': return 4;
   39860             :     case 'q': case 'Q': return 8;
   39861           0 :     case 'f': return (is_complex ? 8 : 4);
   39862           0 :     case 'd': return (is_complex ? 16 : 8);
   39863           0 :     case 'g': {
   39864           0 :       PyErr_SetString(PyExc_ValueError, "Python does not define a standard format string size for long double ('g')..");
   39865           0 :       return 0;
   39866             :     }
   39867             :     case 'O': case 'P': return sizeof(void*);
   39868           0 :     default:
   39869           0 :       __Pyx_BufFmt_RaiseUnexpectedChar(ch);
   39870           0 :       return 0;
   39871             :     }
   39872             : }
   39873         357 : static size_t __Pyx_BufFmt_TypeCharToNativeSize(char ch, int is_complex) {
   39874         357 :   switch (ch) {
   39875             :     case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
   39876          20 :     case 'h': case 'H': return sizeof(short);
   39877             :     case 'i': case 'I': return sizeof(int);
   39878             :     case 'l': case 'L': return sizeof(long);
   39879             :     #ifdef HAVE_LONG_LONG
   39880             :     case 'q': case 'Q': return sizeof(PY_LONG_LONG);
   39881             :     #endif
   39882          10 :     case 'f': return sizeof(float) * (is_complex ? 2 : 1);
   39883          76 :     case 'd': return sizeof(double) * (is_complex ? 2 : 1);
   39884           0 :     case 'g': return sizeof(long double) * (is_complex ? 2 : 1);
   39885             :     case 'O': case 'P': return sizeof(void*);
   39886           0 :     default: {
   39887           0 :       __Pyx_BufFmt_RaiseUnexpectedChar(ch);
   39888           0 :       return 0;
   39889             :     }
   39890             :   }
   39891             : }
   39892             : typedef struct { char c; short x; } __Pyx_st_short;
   39893             : typedef struct { char c; int x; } __Pyx_st_int;
   39894             : typedef struct { char c; long x; } __Pyx_st_long;
   39895             : typedef struct { char c; float x; } __Pyx_st_float;
   39896             : typedef struct { char c; double x; } __Pyx_st_double;
   39897             : typedef struct { char c; long double x; } __Pyx_st_longdouble;
   39898             : typedef struct { char c; void *x; } __Pyx_st_void_p;
   39899             : #ifdef HAVE_LONG_LONG
   39900             : typedef struct { char c; PY_LONG_LONG x; } __Pyx_st_longlong;
   39901             : #endif
   39902         357 : static size_t __Pyx_BufFmt_TypeCharToAlignment(char ch, int is_complex) {
   39903         357 :   CYTHON_UNUSED_VAR(is_complex);
   39904         357 :   switch (ch) {
   39905             :     case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
   39906          20 :     case 'h': case 'H': return sizeof(__Pyx_st_short) - sizeof(short);
   39907             :     case 'i': case 'I': return sizeof(__Pyx_st_int) - sizeof(int);
   39908             :     case 'l': case 'L': return sizeof(__Pyx_st_long) - sizeof(long);
   39909             : #ifdef HAVE_LONG_LONG
   39910             :     case 'q': case 'Q': return sizeof(__Pyx_st_longlong) - sizeof(PY_LONG_LONG);
   39911             : #endif
   39912             :     case 'f': return sizeof(__Pyx_st_float) - sizeof(float);
   39913             :     case 'd': return sizeof(__Pyx_st_double) - sizeof(double);
   39914           0 :     case 'g': return sizeof(__Pyx_st_longdouble) - sizeof(long double);
   39915             :     case 'P': case 'O': return sizeof(__Pyx_st_void_p) - sizeof(void*);
   39916           0 :     default:
   39917           0 :       __Pyx_BufFmt_RaiseUnexpectedChar(ch);
   39918           0 :       return 0;
   39919             :     }
   39920             : }
   39921             : /* These are for computing the padding at the end of the struct to align
   39922             :    on the first member of the struct. This will probably the same as above,
   39923             :    but we don't have any guarantees.
   39924             :  */
   39925             : typedef struct { short x; char c; } __Pyx_pad_short;
   39926             : typedef struct { int x; char c; } __Pyx_pad_int;
   39927             : typedef struct { long x; char c; } __Pyx_pad_long;
   39928             : typedef struct { float x; char c; } __Pyx_pad_float;
   39929             : typedef struct { double x; char c; } __Pyx_pad_double;
   39930             : typedef struct { long double x; char c; } __Pyx_pad_longdouble;
   39931             : typedef struct { void *x; char c; } __Pyx_pad_void_p;
   39932             : #ifdef HAVE_LONG_LONG
   39933             : typedef struct { PY_LONG_LONG x; char c; } __Pyx_pad_longlong;
   39934             : #endif
   39935         357 : static size_t __Pyx_BufFmt_TypeCharToPadding(char ch, int is_complex) {
   39936         357 :   CYTHON_UNUSED_VAR(is_complex);
   39937         357 :   switch (ch) {
   39938             :     case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
   39939          20 :     case 'h': case 'H': return sizeof(__Pyx_pad_short) - sizeof(short);
   39940             :     case 'i': case 'I': return sizeof(__Pyx_pad_int) - sizeof(int);
   39941             :     case 'l': case 'L': return sizeof(__Pyx_pad_long) - sizeof(long);
   39942             : #ifdef HAVE_LONG_LONG
   39943             :     case 'q': case 'Q': return sizeof(__Pyx_pad_longlong) - sizeof(PY_LONG_LONG);
   39944             : #endif
   39945             :     case 'f': return sizeof(__Pyx_pad_float) - sizeof(float);
   39946             :     case 'd': return sizeof(__Pyx_pad_double) - sizeof(double);
   39947           0 :     case 'g': return sizeof(__Pyx_pad_longdouble) - sizeof(long double);
   39948             :     case 'P': case 'O': return sizeof(__Pyx_pad_void_p) - sizeof(void*);
   39949           0 :     default:
   39950           0 :       __Pyx_BufFmt_RaiseUnexpectedChar(ch);
   39951           0 :       return 0;
   39952             :     }
   39953             : }
   39954         357 : static char __Pyx_BufFmt_TypeCharToGroup(char ch, int is_complex) {
   39955         357 :   switch (ch) {
   39956             :     case 'c':
   39957             :         return 'H';
   39958         223 :     case 'b': case 'h': case 'i':
   39959             :     case 'l': case 'q': case 's': case 'p':
   39960         223 :         return 'I';
   39961          48 :     case '?': case 'B': case 'H': case 'I': case 'L': case 'Q':
   39962          48 :         return 'U';
   39963          86 :     case 'f': case 'd': case 'g':
   39964          86 :         return (is_complex ? 'C' : 'R');
   39965           0 :     case 'O':
   39966           0 :         return 'O';
   39967           0 :     case 'P':
   39968           0 :         return 'P';
   39969           0 :     default: {
   39970           0 :       __Pyx_BufFmt_RaiseUnexpectedChar(ch);
   39971           0 :       return 0;
   39972             :     }
   39973             :   }
   39974             : }
   39975           0 : static void __Pyx_BufFmt_RaiseExpected(__Pyx_BufFmt_Context* ctx) {
   39976           0 :   if (ctx->head == NULL || ctx->head->field == &ctx->root) {
   39977           0 :     const char* expected;
   39978           0 :     const char* quote;
   39979           0 :     if (ctx->head == NULL) {
   39980             :       expected = "end";
   39981             :       quote = "";
   39982             :     } else {
   39983           0 :       expected = ctx->head->field->type->name;
   39984           0 :       quote = "'";
   39985             :     }
   39986           0 :     PyErr_Format(PyExc_ValueError,
   39987             :                  "Buffer dtype mismatch, expected %s%s%s but got %s",
   39988             :                  quote, expected, quote,
   39989           0 :                  __Pyx_BufFmt_DescribeTypeChar(ctx->enc_type, ctx->is_complex));
   39990             :   } else {
   39991           0 :     __Pyx_StructField* field = ctx->head->field;
   39992           0 :     __Pyx_StructField* parent = (ctx->head - 1)->field;
   39993           0 :     PyErr_Format(PyExc_ValueError,
   39994             :                  "Buffer dtype mismatch, expected '%s' but got %s in '%s.%s'",
   39995           0 :                  field->type->name, __Pyx_BufFmt_DescribeTypeChar(ctx->enc_type, ctx->is_complex),
   39996           0 :                  parent->type->name, field->name);
   39997             :   }
   39998           0 : }
   39999         714 : static int __Pyx_BufFmt_ProcessTypeChunk(__Pyx_BufFmt_Context* ctx) {
   40000         714 :   char group;
   40001         714 :   size_t size, offset, arraysize = 1;
   40002         714 :   if (ctx->enc_type == 0) return 0;
   40003         357 :   if (ctx->head->field->type->arraysize[0]) {
   40004           0 :     int i, ndim = 0;
   40005           0 :     if (ctx->enc_type == 's' || ctx->enc_type == 'p') {
   40006           0 :         ctx->is_valid_array = ctx->head->field->type->ndim == 1;
   40007           0 :         ndim = 1;
   40008           0 :         if (ctx->enc_count != ctx->head->field->type->arraysize[0]) {
   40009           0 :             PyErr_Format(PyExc_ValueError,
   40010             :                          "Expected a dimension of size %zu, got %zu",
   40011             :                          ctx->head->field->type->arraysize[0], ctx->enc_count);
   40012           0 :             return -1;
   40013             :         }
   40014             :     }
   40015           0 :     if (!ctx->is_valid_array) {
   40016           0 :       PyErr_Format(PyExc_ValueError, "Expected %d dimensions, got %d",
   40017             :                    ctx->head->field->type->ndim, ndim);
   40018           0 :       return -1;
   40019             :     }
   40020           0 :     for (i = 0; i < ctx->head->field->type->ndim; i++) {
   40021           0 :       arraysize *= ctx->head->field->type->arraysize[i];
   40022             :     }
   40023           0 :     ctx->is_valid_array = 0;
   40024           0 :     ctx->enc_count = 1;
   40025             :   }
   40026         357 :   group = __Pyx_BufFmt_TypeCharToGroup(ctx->enc_type, ctx->is_complex);
   40027         357 :   do {
   40028         357 :     __Pyx_StructField* field = ctx->head->field;
   40029         357 :     __Pyx_TypeInfo* type = field->type;
   40030         357 :     if (ctx->enc_packmode == '@' || ctx->enc_packmode == '^') {
   40031         357 :       size = __Pyx_BufFmt_TypeCharToNativeSize(ctx->enc_type, ctx->is_complex);
   40032             :     } else {
   40033           0 :       size = __Pyx_BufFmt_TypeCharToStandardSize(ctx->enc_type, ctx->is_complex);
   40034             :     }
   40035         357 :     if (ctx->enc_packmode == '@') {
   40036         357 :       size_t align_at = __Pyx_BufFmt_TypeCharToAlignment(ctx->enc_type, ctx->is_complex);
   40037         357 :       size_t align_mod_offset;
   40038         357 :       if (align_at == 0) return -1;
   40039         357 :       align_mod_offset = ctx->fmt_offset % align_at;
   40040         357 :       if (align_mod_offset > 0) ctx->fmt_offset += align_at - align_mod_offset;
   40041         357 :       if (ctx->struct_alignment == 0)
   40042         357 :           ctx->struct_alignment = __Pyx_BufFmt_TypeCharToPadding(ctx->enc_type,
   40043             :                                                                  ctx->is_complex);
   40044             :     }
   40045         357 :     if (type->size != size || type->typegroup != group) {
   40046           0 :       if (type->typegroup == 'C' && type->fields != NULL) {
   40047           0 :         size_t parent_offset = ctx->head->parent_offset + field->offset;
   40048           0 :         ++ctx->head;
   40049           0 :         ctx->head->field = type->fields;
   40050           0 :         ctx->head->parent_offset = parent_offset;
   40051           0 :         continue;
   40052             :       }
   40053           0 :       if ((type->typegroup == 'H' || group == 'H') && type->size == size) {
   40054             :       } else {
   40055           0 :           __Pyx_BufFmt_RaiseExpected(ctx);
   40056           0 :           return -1;
   40057             :       }
   40058             :     }
   40059         357 :     offset = ctx->head->parent_offset + field->offset;
   40060         357 :     if (ctx->fmt_offset != offset) {
   40061           0 :       PyErr_Format(PyExc_ValueError,
   40062             :                    "Buffer dtype mismatch; next field is at offset %" CYTHON_FORMAT_SSIZE_T "d but %" CYTHON_FORMAT_SSIZE_T "d expected",
   40063             :                    (Py_ssize_t)ctx->fmt_offset, (Py_ssize_t)offset);
   40064           0 :       return -1;
   40065             :     }
   40066         357 :     ctx->fmt_offset += size;
   40067         357 :     if (arraysize)
   40068         357 :       ctx->fmt_offset += (arraysize - 1) * size;
   40069         357 :     --ctx->enc_count;
   40070         357 :     while (1) {
   40071         357 :       if (field == &ctx->root) {
   40072         357 :         ctx->head = NULL;
   40073         357 :         if (ctx->enc_count != 0) {
   40074           0 :           __Pyx_BufFmt_RaiseExpected(ctx);
   40075           0 :           return -1;
   40076             :         }
   40077             :         break;
   40078             :       }
   40079           0 :       ctx->head->field = ++field;
   40080           0 :       if (field->type == NULL) {
   40081           0 :         --ctx->head;
   40082           0 :         field = ctx->head->field;
   40083           0 :         continue;
   40084           0 :       } else if (field->type->typegroup == 'S') {
   40085           0 :         size_t parent_offset = ctx->head->parent_offset + field->offset;
   40086           0 :         if (field->type->fields->type == NULL) continue;
   40087           0 :         field = field->type->fields;
   40088           0 :         ++ctx->head;
   40089           0 :         ctx->head->field = field;
   40090           0 :         ctx->head->parent_offset = parent_offset;
   40091           0 :         break;
   40092             :       } else {
   40093             :         break;
   40094             :       }
   40095             :     }
   40096         357 :   } while (ctx->enc_count);
   40097         357 :   ctx->enc_type = 0;
   40098         357 :   ctx->is_complex = 0;
   40099         357 :   return 0;
   40100             : }
   40101             : static int
   40102           0 : __pyx_buffmt_parse_array(__Pyx_BufFmt_Context* ctx, const char** tsp)
   40103             : {
   40104           0 :     const char *ts = *tsp;
   40105           0 :     int i = 0, number, ndim;
   40106           0 :     ++ts;
   40107           0 :     if (ctx->new_count != 1) {
   40108           0 :         PyErr_SetString(PyExc_ValueError,
   40109             :                         "Cannot handle repeated arrays in format string");
   40110           0 :         return -1;
   40111             :     }
   40112           0 :     if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return -1;
   40113           0 :     ndim = ctx->head->field->type->ndim;
   40114           0 :     while (*ts && *ts != ')') {
   40115           0 :         switch (*ts) {
   40116           0 :             case ' ': case '\f': case '\r': case '\n': case '\t': case '\v':  continue;
   40117           0 :             default:  break;
   40118             :         }
   40119           0 :         number = __Pyx_BufFmt_ExpectNumber(&ts);
   40120           0 :         if (number == -1) return -1;
   40121           0 :         if (i < ndim && (size_t) number != ctx->head->field->type->arraysize[i]) {
   40122           0 :             PyErr_Format(PyExc_ValueError,
   40123             :                         "Expected a dimension of size %zu, got %d",
   40124             :                         ctx->head->field->type->arraysize[i], number);
   40125           0 :             return -1;
   40126             :         }
   40127           0 :         if (*ts != ',' && *ts != ')') {
   40128           0 :             PyErr_Format(PyExc_ValueError,
   40129             :                                 "Expected a comma in format string, got '%c'", *ts);
   40130           0 :             return -1;
   40131             :         }
   40132           0 :         if (*ts == ',') ts++;
   40133           0 :         i++;
   40134             :     }
   40135           0 :     if (i != ndim) {
   40136           0 :         PyErr_Format(PyExc_ValueError, "Expected %d dimension(s), got %d",
   40137           0 :                             ctx->head->field->type->ndim, i);
   40138           0 :         return -1;
   40139             :     }
   40140           0 :     if (!*ts) {
   40141           0 :         PyErr_SetString(PyExc_ValueError,
   40142             :                         "Unexpected end of format string, expected ')'");
   40143           0 :         return -1;
   40144             :     }
   40145           0 :     ctx->is_valid_array = 1;
   40146           0 :     ctx->new_count = 1;
   40147           0 :     *tsp = ++ts;
   40148           0 :     return 0;
   40149             : }
   40150         357 : static const char* __Pyx_BufFmt_CheckString(__Pyx_BufFmt_Context* ctx, const char* ts) {
   40151         357 :   int got_Z = 0;
   40152         714 :   while (1) {
   40153         714 :     switch(*ts) {
   40154         357 :       case 0:
   40155         357 :         if (ctx->enc_type != 0 && ctx->head == NULL) {
   40156           0 :           __Pyx_BufFmt_RaiseExpected(ctx);
   40157           0 :           return NULL;
   40158             :         }
   40159         357 :         if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
   40160         357 :         if (ctx->head != NULL) {
   40161           0 :           __Pyx_BufFmt_RaiseExpected(ctx);
   40162           0 :           return NULL;
   40163             :         }
   40164             :         return ts;
   40165           0 :       case ' ':
   40166             :       case '\r':
   40167             :       case '\n':
   40168           0 :         ++ts;
   40169           0 :         break;
   40170             :       case '<':
   40171           0 :         if (!__Pyx_Is_Little_Endian()) {
   40172             :           PyErr_SetString(PyExc_ValueError, "Little-endian buffer not supported on big-endian compiler");
   40173             :           return NULL;
   40174             :         }
   40175           0 :         ctx->new_packmode = '=';
   40176           0 :         ++ts;
   40177           0 :         break;
   40178             :       case '>':
   40179             :       case '!':
   40180           0 :         if (__Pyx_Is_Little_Endian()) {
   40181           0 :           PyErr_SetString(PyExc_ValueError, "Big-endian buffer not supported on little-endian compiler");
   40182           0 :           return NULL;
   40183             :         }
   40184             :         ctx->new_packmode = '=';
   40185             :         ++ts;
   40186             :         break;
   40187           0 :       case '=':
   40188             :       case '@':
   40189             :       case '^':
   40190           0 :         ctx->new_packmode = *ts++;
   40191           0 :         break;
   40192           0 :       case 'T':
   40193             :         {
   40194           0 :           const char* ts_after_sub;
   40195           0 :           size_t i, struct_count = ctx->new_count;
   40196           0 :           size_t struct_alignment = ctx->struct_alignment;
   40197           0 :           ctx->new_count = 1;
   40198           0 :           ++ts;
   40199           0 :           if (*ts != '{') {
   40200           0 :             PyErr_SetString(PyExc_ValueError, "Buffer acquisition: Expected '{' after 'T'");
   40201           0 :             return NULL;
   40202             :           }
   40203           0 :           if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
   40204           0 :           ctx->enc_type = 0;
   40205           0 :           ctx->enc_count = 0;
   40206           0 :           ctx->struct_alignment = 0;
   40207           0 :           ++ts;
   40208           0 :           ts_after_sub = ts;
   40209           0 :           for (i = 0; i != struct_count; ++i) {
   40210           0 :             ts_after_sub = __Pyx_BufFmt_CheckString(ctx, ts);
   40211           0 :             if (!ts_after_sub) return NULL;
   40212             :           }
   40213           0 :           ts = ts_after_sub;
   40214           0 :           if (struct_alignment) ctx->struct_alignment = struct_alignment;
   40215             :         }
   40216             :         break;
   40217           0 :       case '}':
   40218             :         {
   40219           0 :           size_t alignment = ctx->struct_alignment;
   40220           0 :           ++ts;
   40221           0 :           if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
   40222           0 :           ctx->enc_type = 0;
   40223           0 :           if (alignment && ctx->fmt_offset % alignment) {
   40224           0 :             ctx->fmt_offset += alignment - (ctx->fmt_offset % alignment);
   40225             :           }
   40226             :         }
   40227             :         return ts;
   40228           0 :       case 'x':
   40229           0 :         if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
   40230           0 :         ctx->fmt_offset += ctx->new_count;
   40231           0 :         ctx->new_count = 1;
   40232           0 :         ctx->enc_count = 0;
   40233           0 :         ctx->enc_type = 0;
   40234           0 :         ctx->enc_packmode = ctx->new_packmode;
   40235           0 :         ++ts;
   40236           0 :         break;
   40237           0 :       case 'Z':
   40238           0 :         got_Z = 1;
   40239           0 :         ++ts;
   40240           0 :         if (*ts != 'f' && *ts != 'd' && *ts != 'g') {
   40241           0 :           __Pyx_BufFmt_RaiseUnexpectedChar('Z');
   40242           0 :           return NULL;
   40243             :         }
   40244         357 :         CYTHON_FALLTHROUGH;
   40245             :       case '?': case 'c': case 'b': case 'B': case 'h': case 'H': case 'i': case 'I':
   40246             :       case 'l': case 'L': case 'q': case 'Q':
   40247             :       case 'f': case 'd': case 'g':
   40248             :       case 'O': case 'p':
   40249         357 :         if ((ctx->enc_type == *ts) && (got_Z == ctx->is_complex) &&
   40250           0 :             (ctx->enc_packmode == ctx->new_packmode) && (!ctx->is_valid_array)) {
   40251           0 :           ctx->enc_count += ctx->new_count;
   40252           0 :           ctx->new_count = 1;
   40253           0 :           got_Z = 0;
   40254           0 :           ++ts;
   40255           0 :           break;
   40256             :         }
   40257         357 :         CYTHON_FALLTHROUGH;
   40258             :       case 's':
   40259         357 :         if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
   40260         357 :         ctx->enc_count = ctx->new_count;
   40261         357 :         ctx->enc_packmode = ctx->new_packmode;
   40262         357 :         ctx->enc_type = *ts;
   40263         357 :         ctx->is_complex = got_Z;
   40264         357 :         ++ts;
   40265         357 :         ctx->new_count = 1;
   40266         357 :         got_Z = 0;
   40267         357 :         break;
   40268           0 :       case ':':
   40269           0 :         ++ts;
   40270           0 :         while(*ts != ':') ++ts;
   40271           0 :         ++ts;
   40272           0 :         break;
   40273           0 :       case '(':
   40274           0 :         if (__pyx_buffmt_parse_array(ctx, &ts) < 0) return NULL;
   40275             :         break;
   40276           0 :       default:
   40277             :         {
   40278           0 :           int number = __Pyx_BufFmt_ExpectNumber(&ts);
   40279           0 :           if (number == -1) return NULL;
   40280           0 :           ctx->new_count = (size_t)number;
   40281             :         }
   40282             :     }
   40283             :   }
   40284             : }
   40285             : 
   40286             : /* BufferGetAndValidate */
   40287         357 :   static CYTHON_INLINE void __Pyx_SafeReleaseBuffer(Py_buffer* info) {
   40288         357 :   if (unlikely(info->buf == NULL)) return;
   40289         357 :   if (info->suboffsets == __Pyx_minusones) info->suboffsets = NULL;
   40290         357 :   __Pyx_ReleaseBuffer(info);
   40291             : }
   40292           0 : static void __Pyx_ZeroBuffer(Py_buffer* buf) {
   40293           0 :   buf->buf = NULL;
   40294           0 :   buf->obj = NULL;
   40295           0 :   buf->strides = __Pyx_zeros;
   40296           0 :   buf->shape = __Pyx_zeros;
   40297           0 :   buf->suboffsets = __Pyx_minusones;
   40298             : }
   40299         357 : static int __Pyx__GetBufferAndValidate(
   40300             :         Py_buffer* buf, PyObject* obj,  __Pyx_TypeInfo* dtype, int flags,
   40301             :         int nd, int cast, __Pyx_BufFmt_StackElem* stack)
   40302             : {
   40303         357 :   buf->buf = NULL;
   40304         357 :   if (unlikely(__Pyx_GetBuffer(obj, buf, flags) == -1)) {
   40305           0 :     __Pyx_ZeroBuffer(buf);
   40306           0 :     return -1;
   40307             :   }
   40308         357 :   if (unlikely(buf->ndim != nd)) {
   40309           0 :     PyErr_Format(PyExc_ValueError,
   40310             :                  "Buffer has wrong number of dimensions (expected %d, got %d)",
   40311             :                  nd, buf->ndim);
   40312           0 :     goto fail;
   40313             :   }
   40314         357 :   if (!cast) {
   40315         357 :     __Pyx_BufFmt_Context ctx;
   40316         357 :     __Pyx_BufFmt_Init(&ctx, stack, dtype);
   40317         357 :     if (!__Pyx_BufFmt_CheckString(&ctx, buf->format)) goto fail;
   40318             :   }
   40319         357 :   if (unlikely((size_t)buf->itemsize != dtype->size)) {
   40320           0 :     PyErr_Format(PyExc_ValueError,
   40321             :       "Item size of buffer (%" CYTHON_FORMAT_SSIZE_T "d byte%s) does not match size of '%s' (%" CYTHON_FORMAT_SSIZE_T "d byte%s)",
   40322             :       buf->itemsize, (buf->itemsize > 1) ? "s" : "",
   40323             :       dtype->name, (Py_ssize_t)dtype->size, (dtype->size > 1) ? "s" : "");
   40324           0 :     goto fail;
   40325             :   }
   40326         357 :   if (buf->suboffsets == NULL) buf->suboffsets = __Pyx_minusones;
   40327             :   return 0;
   40328           0 : fail:;
   40329           0 :   __Pyx_SafeReleaseBuffer(buf);
   40330           0 :   return -1;
   40331             : }
   40332             : 
   40333             : /* DivInt[npy_intp] */
   40334         119 :   static CYTHON_INLINE npy_intp __Pyx_div_npy_intp(npy_intp a, npy_intp b) {
   40335         119 :     npy_intp q = a / b;
   40336         119 :     npy_intp r = a - q*b;
   40337         119 :     q -= ((r != 0) & ((r ^ b) < 0));
   40338         119 :     return q;
   40339             : }
   40340             : 
   40341             : /* PyIntCompare */
   40342         119 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_NeObjC(PyObject *op1, PyObject *op2, long intval, long inplace) {
   40343         119 :     CYTHON_MAYBE_UNUSED_VAR(intval);
   40344         119 :     CYTHON_UNUSED_VAR(inplace);
   40345         119 :     if (op1 == op2) {
   40346             :         Py_RETURN_FALSE;
   40347             :     }
   40348             :     #if PY_MAJOR_VERSION < 3
   40349             :     if (likely(PyInt_CheckExact(op1))) {
   40350             :         const long b = intval;
   40351             :         long a = PyInt_AS_LONG(op1);
   40352             :         if (a != b) Py_RETURN_TRUE; else Py_RETURN_FALSE;
   40353             :     }
   40354             :     #endif
   40355             :     #if CYTHON_USE_PYLONG_INTERNALS
   40356         119 :     if (likely(PyLong_CheckExact(op1))) {
   40357           0 :         int unequal;
   40358           0 :         unsigned long uintval;
   40359           0 :         Py_ssize_t size = __Pyx_PyLong_DigitCount(op1);
   40360           0 :         const digit* digits = __Pyx_PyLong_Digits(op1);
   40361           0 :         if (intval == 0) {
   40362           0 :             if (__Pyx_PyLong_IsZero(op1) != 1) Py_RETURN_TRUE; else Py_RETURN_FALSE;
   40363           0 :         } else if (intval < 0) {
   40364           0 :             if (__Pyx_PyLong_IsNonNeg(op1))
   40365             :                 Py_RETURN_TRUE;
   40366           0 :             intval = -intval;
   40367             :         } else {
   40368           0 :             if (__Pyx_PyLong_IsNeg(op1))
   40369             :                 Py_RETURN_TRUE;
   40370             :         }
   40371           0 :         uintval = (unsigned long) intval;
   40372             : #if PyLong_SHIFT * 4 < SIZEOF_LONG*8
   40373             :         if (uintval >> (PyLong_SHIFT * 4)) {
   40374             :             unequal = (size != 5) || (digits[0] != (uintval & (unsigned long) PyLong_MASK))
   40375             :                  | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[4] != ((uintval >> (4 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK));
   40376             :         } else
   40377             : #endif
   40378             : #if PyLong_SHIFT * 3 < SIZEOF_LONG*8
   40379             :         if (uintval >> (PyLong_SHIFT * 3)) {
   40380             :             unequal = (size != 4) || (digits[0] != (uintval & (unsigned long) PyLong_MASK))
   40381             :                  | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK));
   40382             :         } else
   40383             : #endif
   40384             : #if PyLong_SHIFT * 2 < SIZEOF_LONG*8
   40385           0 :         if (uintval >> (PyLong_SHIFT * 2)) {
   40386           0 :             unequal = (size != 3) || (digits[0] != (uintval & (unsigned long) PyLong_MASK))
   40387           0 :                  | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK));
   40388             :         } else
   40389             : #endif
   40390             : #if PyLong_SHIFT * 1 < SIZEOF_LONG*8
   40391           0 :         if (uintval >> (PyLong_SHIFT * 1)) {
   40392           0 :             unequal = (size != 2) || (digits[0] != (uintval & (unsigned long) PyLong_MASK))
   40393           0 :                  | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (unsigned long) PyLong_MASK));
   40394             :         } else
   40395             : #endif
   40396           0 :             unequal = (size != 1) || (((unsigned long) digits[0]) != (uintval & (unsigned long) PyLong_MASK));
   40397           0 :         if (unequal != 0) Py_RETURN_TRUE; else Py_RETURN_FALSE;
   40398             :     }
   40399             :     #endif
   40400         119 :     if (PyFloat_CheckExact(op1)) {
   40401           0 :         const long b = intval;
   40402             : #if CYTHON_COMPILING_IN_LIMITED_API
   40403             :         double a = __pyx_PyFloat_AsDouble(op1);
   40404             : #else
   40405           0 :         double a = PyFloat_AS_DOUBLE(op1);
   40406             : #endif
   40407           0 :         if ((double)a != (double)b) Py_RETURN_TRUE; else Py_RETURN_FALSE;
   40408             :     }
   40409         119 :     return (
   40410         119 :         PyObject_RichCompare(op1, op2, Py_NE));
   40411             : }
   40412             : 
   40413             : /* PyObject_GenericGetAttrNoDict */
   40414             :   #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
   40415             : static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) {
   40416             :     __Pyx_TypeName type_name = __Pyx_PyType_GetName(tp);
   40417             :     PyErr_Format(PyExc_AttributeError,
   40418             : #if PY_MAJOR_VERSION >= 3
   40419             :                  "'" __Pyx_FMT_TYPENAME "' object has no attribute '%U'",
   40420             :                  type_name, attr_name);
   40421             : #else
   40422             :                  "'" __Pyx_FMT_TYPENAME "' object has no attribute '%.400s'",
   40423             :                  type_name, PyString_AS_STRING(attr_name));
   40424             : #endif
   40425             :     __Pyx_DECREF_TypeName(type_name);
   40426             :     return NULL;
   40427             : }
   40428             : static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) {
   40429             :     PyObject *descr;
   40430             :     PyTypeObject *tp = Py_TYPE(obj);
   40431             :     if (unlikely(!PyString_Check(attr_name))) {
   40432             :         return PyObject_GenericGetAttr(obj, attr_name);
   40433             :     }
   40434             :     assert(!tp->tp_dictoffset);
   40435             :     descr = _PyType_Lookup(tp, attr_name);
   40436             :     if (unlikely(!descr)) {
   40437             :         return __Pyx_RaiseGenericGetAttributeError(tp, attr_name);
   40438             :     }
   40439             :     Py_INCREF(descr);
   40440             :     #if PY_MAJOR_VERSION < 3
   40441             :     if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS)))
   40442             :     #endif
   40443             :     {
   40444             :         descrgetfunc f = Py_TYPE(descr)->tp_descr_get;
   40445             :         if (unlikely(f)) {
   40446             :             PyObject *res = f(descr, obj, (PyObject *)tp);
   40447             :             Py_DECREF(descr);
   40448             :             return res;
   40449             :         }
   40450             :     }
   40451             :     return descr;
   40452             : }
   40453             : #endif
   40454             : 
   40455             : /* PyObject_GenericGetAttr */
   40456             :   #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
   40457             : static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) {
   40458             :     if (unlikely(Py_TYPE(obj)->tp_dictoffset)) {
   40459             :         return PyObject_GenericGetAttr(obj, attr_name);
   40460             :     }
   40461             :     return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name);
   40462             : }
   40463             : #endif
   40464             : 
   40465             : /* FixUpExtensionType */
   40466             :   #if CYTHON_USE_TYPE_SPECS
   40467             : static int __Pyx_fix_up_extension_type_from_spec(PyType_Spec *spec, PyTypeObject *type) {
   40468             : #if PY_VERSION_HEX > 0x030900B1 || CYTHON_COMPILING_IN_LIMITED_API
   40469             :     CYTHON_UNUSED_VAR(spec);
   40470             :     CYTHON_UNUSED_VAR(type);
   40471             : #else
   40472             :     const PyType_Slot *slot = spec->slots;
   40473             :     while (slot && slot->slot && slot->slot != Py_tp_members)
   40474             :         slot++;
   40475             :     if (slot && slot->slot == Py_tp_members) {
   40476             :         int changed = 0;
   40477             : #if !(PY_VERSION_HEX <= 0x030900b1 && CYTHON_COMPILING_IN_CPYTHON)
   40478             :         const
   40479             : #endif
   40480             :             PyMemberDef *memb = (PyMemberDef*) slot->pfunc;
   40481             :         while (memb && memb->name) {
   40482             :             if (memb->name[0] == '_' && memb->name[1] == '_') {
   40483             : #if PY_VERSION_HEX < 0x030900b1
   40484             :                 if (strcmp(memb->name, "__weaklistoffset__") == 0) {
   40485             :                     assert(memb->type == T_PYSSIZET);
   40486             :                     assert(memb->flags == READONLY);
   40487             :                     type->tp_weaklistoffset = memb->offset;
   40488             :                     changed = 1;
   40489             :                 }
   40490             :                 else if (strcmp(memb->name, "__dictoffset__") == 0) {
   40491             :                     assert(memb->type == T_PYSSIZET);
   40492             :                     assert(memb->flags == READONLY);
   40493             :                     type->tp_dictoffset = memb->offset;
   40494             :                     changed = 1;
   40495             :                 }
   40496             : #if CYTHON_METH_FASTCALL
   40497             :                 else if (strcmp(memb->name, "__vectorcalloffset__") == 0) {
   40498             :                     assert(memb->type == T_PYSSIZET);
   40499             :                     assert(memb->flags == READONLY);
   40500             : #if PY_VERSION_HEX >= 0x030800b4
   40501             :                     type->tp_vectorcall_offset = memb->offset;
   40502             : #else
   40503             :                     type->tp_print = (printfunc) memb->offset;
   40504             : #endif
   40505             :                     changed = 1;
   40506             :                 }
   40507             : #endif
   40508             : #else
   40509             :                 if ((0));
   40510             : #endif
   40511             : #if PY_VERSION_HEX <= 0x030900b1 && CYTHON_COMPILING_IN_CPYTHON
   40512             :                 else if (strcmp(memb->name, "__module__") == 0) {
   40513             :                     PyObject *descr;
   40514             :                     assert(memb->type == T_OBJECT);
   40515             :                     assert(memb->flags == 0 || memb->flags == READONLY);
   40516             :                     descr = PyDescr_NewMember(type, memb);
   40517             :                     if (unlikely(!descr))
   40518             :                         return -1;
   40519             :                     if (unlikely(PyDict_SetItem(type->tp_dict, PyDescr_NAME(descr), descr) < 0)) {
   40520             :                         Py_DECREF(descr);
   40521             :                         return -1;
   40522             :                     }
   40523             :                     Py_DECREF(descr);
   40524             :                     changed = 1;
   40525             :                 }
   40526             : #endif
   40527             :             }
   40528             :             memb++;
   40529             :         }
   40530             :         if (changed)
   40531             :             PyType_Modified(type);
   40532             :     }
   40533             : #endif
   40534             :     return 0;
   40535             : }
   40536             : #endif
   40537             : 
   40538             : /* ValidateBasesTuple */
   40539             :   #if CYTHON_COMPILING_IN_CPYTHON || CYTHON_COMPILING_IN_LIMITED_API || CYTHON_USE_TYPE_SPECS
   40540           0 : static int __Pyx_validate_bases_tuple(const char *type_name, Py_ssize_t dictoffset, PyObject *bases) {
   40541           0 :     Py_ssize_t i, n;
   40542             : #if CYTHON_ASSUME_SAFE_MACROS
   40543           0 :     n = PyTuple_GET_SIZE(bases);
   40544             : #else
   40545             :     n = PyTuple_Size(bases);
   40546             :     if (n < 0) return -1;
   40547             : #endif
   40548           0 :     for (i = 1; i < n; i++)
   40549             :     {
   40550             : #if CYTHON_AVOID_BORROWED_REFS
   40551             :         PyObject *b0 = PySequence_GetItem(bases, i);
   40552             :         if (!b0) return -1;
   40553             : #elif CYTHON_ASSUME_SAFE_MACROS
   40554           0 :         PyObject *b0 = PyTuple_GET_ITEM(bases, i);
   40555             : #else
   40556             :         PyObject *b0 = PyTuple_GetItem(bases, i);
   40557             :         if (!b0) return -1;
   40558             : #endif
   40559           0 :         PyTypeObject *b;
   40560             : #if PY_MAJOR_VERSION < 3
   40561             :         if (PyClass_Check(b0))
   40562             :         {
   40563             :             PyErr_Format(PyExc_TypeError, "base class '%.200s' is an old-style class",
   40564             :                          PyString_AS_STRING(((PyClassObject*)b0)->cl_name));
   40565             : #if CYTHON_AVOID_BORROWED_REFS
   40566             :             Py_DECREF(b0);
   40567             : #endif
   40568             :             return -1;
   40569             :         }
   40570             : #endif
   40571           0 :         b = (PyTypeObject*) b0;
   40572           0 :         if (!__Pyx_PyType_HasFeature(b, Py_TPFLAGS_HEAPTYPE))
   40573             :         {
   40574           0 :             __Pyx_TypeName b_name = __Pyx_PyType_GetName(b);
   40575           0 :             PyErr_Format(PyExc_TypeError,
   40576             :                 "base class '" __Pyx_FMT_TYPENAME "' is not a heap type", b_name);
   40577           0 :             __Pyx_DECREF_TypeName(b_name);
   40578             : #if CYTHON_AVOID_BORROWED_REFS
   40579             :             Py_DECREF(b0);
   40580             : #endif
   40581           0 :             return -1;
   40582             :         }
   40583           0 :         if (dictoffset == 0)
   40584             :         {
   40585           0 :             Py_ssize_t b_dictoffset = 0;
   40586             : #if CYTHON_USE_TYPE_SLOTS || CYTHON_COMPILING_IN_PYPY
   40587           0 :             b_dictoffset = b->tp_dictoffset;
   40588             : #else
   40589             :             PyObject *py_b_dictoffset = PyObject_GetAttrString((PyObject*)b, "__dictoffset__");
   40590             :             if (!py_b_dictoffset) goto dictoffset_return;
   40591             :             b_dictoffset = PyLong_AsSsize_t(py_b_dictoffset);
   40592             :             Py_DECREF(py_b_dictoffset);
   40593             :             if (b_dictoffset == -1 && PyErr_Occurred()) goto dictoffset_return;
   40594             : #endif
   40595           0 :             if (b_dictoffset) {
   40596             :                 {
   40597           0 :                     __Pyx_TypeName b_name = __Pyx_PyType_GetName(b);
   40598           0 :                     PyErr_Format(PyExc_TypeError,
   40599             :                         "extension type '%.200s' has no __dict__ slot, "
   40600             :                         "but base type '" __Pyx_FMT_TYPENAME "' has: "
   40601             :                         "either add 'cdef dict __dict__' to the extension type "
   40602             :                         "or add '__slots__ = [...]' to the base type",
   40603             :                         type_name, b_name);
   40604           0 :                     __Pyx_DECREF_TypeName(b_name);
   40605             :                 }
   40606             : #if !(CYTHON_USE_TYPE_SLOTS || CYTHON_COMPILING_IN_PYPY)
   40607             :               dictoffset_return:
   40608             : #endif
   40609             : #if CYTHON_AVOID_BORROWED_REFS
   40610             :                 Py_DECREF(b0);
   40611             : #endif
   40612           0 :                 return -1;
   40613             :             }
   40614             :         }
   40615             : #if CYTHON_AVOID_BORROWED_REFS
   40616             :         Py_DECREF(b0);
   40617             : #endif
   40618             :     }
   40619             :     return 0;
   40620             : }
   40621             : #endif
   40622             : 
   40623             : /* PyType_Ready */
   40624          12 :   static int __Pyx_PyType_Ready(PyTypeObject *t) {
   40625             : #if CYTHON_USE_TYPE_SPECS || !(CYTHON_COMPILING_IN_CPYTHON || CYTHON_COMPILING_IN_LIMITED_API) || defined(PYSTON_MAJOR_VERSION)
   40626             :     (void)__Pyx_PyObject_CallMethod0;
   40627             : #if CYTHON_USE_TYPE_SPECS
   40628             :     (void)__Pyx_validate_bases_tuple;
   40629             : #endif
   40630             :     return PyType_Ready(t);
   40631             : #else
   40632          12 :     int r;
   40633          12 :     PyObject *bases = __Pyx_PyType_GetSlot(t, tp_bases, PyObject*);
   40634          12 :     if (bases && unlikely(__Pyx_validate_bases_tuple(t->tp_name, t->tp_dictoffset, bases) == -1))
   40635             :         return -1;
   40636             : #if PY_VERSION_HEX >= 0x03050000 && !defined(PYSTON_MAJOR_VERSION)
   40637             :     {
   40638          12 :         int gc_was_enabled;
   40639             :     #if PY_VERSION_HEX >= 0x030A00b1
   40640          12 :         gc_was_enabled = PyGC_Disable();
   40641          12 :         (void)__Pyx_PyObject_CallMethod0;
   40642             :     #else
   40643             :         PyObject *ret, *py_status;
   40644             :         PyObject *gc = NULL;
   40645             :         #if PY_VERSION_HEX >= 0x030700a1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM+0 >= 0x07030400)
   40646             :         gc = PyImport_GetModule(__pyx_kp_u_gc);
   40647             :         #endif
   40648             :         if (unlikely(!gc)) gc = PyImport_Import(__pyx_kp_u_gc);
   40649             :         if (unlikely(!gc)) return -1;
   40650             :         py_status = __Pyx_PyObject_CallMethod0(gc, __pyx_kp_u_isenabled);
   40651             :         if (unlikely(!py_status)) {
   40652             :             Py_DECREF(gc);
   40653             :             return -1;
   40654             :         }
   40655             :         gc_was_enabled = __Pyx_PyObject_IsTrue(py_status);
   40656             :         Py_DECREF(py_status);
   40657             :         if (gc_was_enabled > 0) {
   40658             :             ret = __Pyx_PyObject_CallMethod0(gc, __pyx_kp_u_disable);
   40659             :             if (unlikely(!ret)) {
   40660             :                 Py_DECREF(gc);
   40661             :                 return -1;
   40662             :             }
   40663             :             Py_DECREF(ret);
   40664             :         } else if (unlikely(gc_was_enabled == -1)) {
   40665             :             Py_DECREF(gc);
   40666             :             return -1;
   40667             :         }
   40668             :     #endif
   40669          12 :         t->tp_flags |= Py_TPFLAGS_HEAPTYPE;
   40670             : #if PY_VERSION_HEX >= 0x030A0000
   40671          12 :         t->tp_flags |= Py_TPFLAGS_IMMUTABLETYPE;
   40672             : #endif
   40673             : #else
   40674             :         (void)__Pyx_PyObject_CallMethod0;
   40675             : #endif
   40676          12 :     r = PyType_Ready(t);
   40677             : #if PY_VERSION_HEX >= 0x03050000 && !defined(PYSTON_MAJOR_VERSION)
   40678          12 :         t->tp_flags &= ~Py_TPFLAGS_HEAPTYPE;
   40679             :     #if PY_VERSION_HEX >= 0x030A00b1
   40680          12 :         if (gc_was_enabled)
   40681          12 :             PyGC_Enable();
   40682             :     #else
   40683             :         if (gc_was_enabled) {
   40684             :             PyObject *tp, *v, *tb;
   40685             :             PyErr_Fetch(&tp, &v, &tb);
   40686             :             ret = __Pyx_PyObject_CallMethod0(gc, __pyx_kp_u_enable);
   40687             :             if (likely(ret || r == -1)) {
   40688             :                 Py_XDECREF(ret);
   40689             :                 PyErr_Restore(tp, v, tb);
   40690             :             } else {
   40691             :                 Py_XDECREF(tp);
   40692             :                 Py_XDECREF(v);
   40693             :                 Py_XDECREF(tb);
   40694             :                 r = -1;
   40695             :             }
   40696             :         }
   40697             :         Py_DECREF(gc);
   40698             :     #endif
   40699             :     }
   40700             : #endif
   40701             :     return r;
   40702             : #endif
   40703             : }
   40704             : 
   40705             : /* SetVTable */
   40706           9 :   static int __Pyx_SetVtable(PyTypeObject *type, void *vtable) {
   40707           9 :     PyObject *ob = PyCapsule_New(vtable, 0, 0);
   40708           9 :     if (unlikely(!ob))
   40709           0 :         goto bad;
   40710             : #if CYTHON_COMPILING_IN_LIMITED_API
   40711             :     if (unlikely(PyObject_SetAttr((PyObject *) type, __pyx_n_s_pyx_vtable, ob) < 0))
   40712             : #else
   40713           9 :     if (unlikely(PyDict_SetItem(type->tp_dict, __pyx_n_s_pyx_vtable, ob) < 0))
   40714             : #endif
   40715           0 :         goto bad;
   40716           9 :     Py_DECREF(ob);
   40717             :     return 0;
   40718           0 : bad:
   40719           0 :     Py_XDECREF(ob);
   40720           0 :     return -1;
   40721             : }
   40722             : 
   40723             : /* GetVTable */
   40724           0 :   static void* __Pyx_GetVtable(PyTypeObject *type) {
   40725           0 :     void* ptr;
   40726             : #if CYTHON_COMPILING_IN_LIMITED_API
   40727             :     PyObject *ob = PyObject_GetAttr((PyObject *)type, __pyx_n_s_pyx_vtable);
   40728             : #else
   40729           0 :     PyObject *ob = PyObject_GetItem(type->tp_dict, __pyx_n_s_pyx_vtable);
   40730             : #endif
   40731           0 :     if (!ob)
   40732           0 :         goto bad;
   40733           0 :     ptr = PyCapsule_GetPointer(ob, 0);
   40734           0 :     if (!ptr && !PyErr_Occurred())
   40735           0 :         PyErr_SetString(PyExc_RuntimeError, "invalid vtable found for imported type");
   40736           0 :     Py_DECREF(ob);
   40737             :     return ptr;
   40738           0 : bad:
   40739           0 :     Py_XDECREF(ob);
   40740           0 :     return NULL;
   40741             : }
   40742             : 
   40743             : /* MergeVTables */
   40744             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   40745           9 : static int __Pyx_MergeVtables(PyTypeObject *type) {
   40746           9 :     int i;
   40747           9 :     void** base_vtables;
   40748           9 :     __Pyx_TypeName tp_base_name;
   40749           9 :     __Pyx_TypeName base_name;
   40750           9 :     void* unknown = (void*)-1;
   40751           9 :     PyObject* bases = type->tp_bases;
   40752           9 :     int base_depth = 0;
   40753             :     {
   40754           9 :         PyTypeObject* base = type->tp_base;
   40755          21 :         while (base) {
   40756          12 :             base_depth += 1;
   40757          12 :             base = base->tp_base;
   40758             :         }
   40759             :     }
   40760           9 :     base_vtables = (void**) malloc(sizeof(void*) * (size_t)(base_depth + 1));
   40761           9 :     base_vtables[0] = unknown;
   40762           9 :     for (i = 1; i < PyTuple_GET_SIZE(bases); i++) {
   40763           0 :         void* base_vtable = __Pyx_GetVtable(((PyTypeObject*)PyTuple_GET_ITEM(bases, i)));
   40764           0 :         if (base_vtable != NULL) {
   40765           0 :             int j;
   40766           0 :             PyTypeObject* base = type->tp_base;
   40767           0 :             for (j = 0; j < base_depth; j++) {
   40768           0 :                 if (base_vtables[j] == unknown) {
   40769           0 :                     base_vtables[j] = __Pyx_GetVtable(base);
   40770           0 :                     base_vtables[j + 1] = unknown;
   40771             :                 }
   40772           0 :                 if (base_vtables[j] == base_vtable) {
   40773             :                     break;
   40774           0 :                 } else if (base_vtables[j] == NULL) {
   40775           0 :                     goto bad;
   40776             :                 }
   40777           0 :                 base = base->tp_base;
   40778             :             }
   40779             :         }
   40780             :     }
   40781           9 :     PyErr_Clear();
   40782           9 :     free(base_vtables);
   40783           9 :     return 0;
   40784           0 : bad:
   40785           0 :     tp_base_name = __Pyx_PyType_GetName(type->tp_base);
   40786           0 :     base_name = __Pyx_PyType_GetName((PyTypeObject*)PyTuple_GET_ITEM(bases, i));
   40787           0 :     PyErr_Format(PyExc_TypeError,
   40788             :         "multiple bases have vtable conflict: '" __Pyx_FMT_TYPENAME "' and '" __Pyx_FMT_TYPENAME "'", tp_base_name, base_name);
   40789           0 :     __Pyx_DECREF_TypeName(tp_base_name);
   40790           0 :     __Pyx_DECREF_TypeName(base_name);
   40791           0 :     free(base_vtables);
   40792           0 :     return -1;
   40793             : }
   40794             : #endif
   40795             : 
   40796             : /* SetupReduce */
   40797             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   40798           6 : static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) {
   40799           6 :   int ret;
   40800           6 :   PyObject *name_attr;
   40801           6 :   name_attr = __Pyx_PyObject_GetAttrStrNoError(meth, __pyx_n_s_name_2);
   40802           6 :   if (likely(name_attr)) {
   40803           6 :       ret = PyObject_RichCompareBool(name_attr, name, Py_EQ);
   40804             :   } else {
   40805             :       ret = -1;
   40806             :   }
   40807           6 :   if (unlikely(ret < 0)) {
   40808           0 :       PyErr_Clear();
   40809           0 :       ret = 0;
   40810             :   }
   40811           6 :   Py_XDECREF(name_attr);
   40812           6 :   return ret;
   40813             : }
   40814          12 : static int __Pyx_setup_reduce(PyObject* type_obj) {
   40815          12 :     int ret = 0;
   40816          12 :     PyObject *object_reduce = NULL;
   40817          12 :     PyObject *object_getstate = NULL;
   40818          12 :     PyObject *object_reduce_ex = NULL;
   40819          12 :     PyObject *reduce = NULL;
   40820          12 :     PyObject *reduce_ex = NULL;
   40821          12 :     PyObject *reduce_cython = NULL;
   40822          12 :     PyObject *setstate = NULL;
   40823          12 :     PyObject *setstate_cython = NULL;
   40824          12 :     PyObject *getstate = NULL;
   40825             : #if CYTHON_USE_PYTYPE_LOOKUP
   40826          12 :     getstate = _PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate);
   40827             : #else
   40828             :     getstate = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_getstate);
   40829             :     if (!getstate && PyErr_Occurred()) {
   40830             :         goto __PYX_BAD;
   40831             :     }
   40832             : #endif
   40833          12 :     if (getstate) {
   40834             : #if CYTHON_USE_PYTYPE_LOOKUP
   40835          12 :         object_getstate = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_getstate);
   40836             : #else
   40837             :         object_getstate = __Pyx_PyObject_GetAttrStrNoError((PyObject*)&PyBaseObject_Type, __pyx_n_s_getstate);
   40838             :         if (!object_getstate && PyErr_Occurred()) {
   40839             :             goto __PYX_BAD;
   40840             :         }
   40841             : #endif
   40842          12 :         if (object_getstate != getstate) {
   40843           0 :             goto __PYX_GOOD;
   40844             :         }
   40845             :     }
   40846             : #if CYTHON_USE_PYTYPE_LOOKUP
   40847          12 :     object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD;
   40848             : #else
   40849             :     object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD;
   40850             : #endif
   40851          12 :     reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto __PYX_BAD;
   40852          12 :     if (reduce_ex == object_reduce_ex) {
   40853             : #if CYTHON_USE_PYTYPE_LOOKUP
   40854          12 :         object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD;
   40855             : #else
   40856             :         object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD;
   40857             : #endif
   40858          12 :         reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto __PYX_BAD;
   40859          12 :         if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) {
   40860          12 :             reduce_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_reduce_cython);
   40861          12 :             if (likely(reduce_cython)) {
   40862          12 :                 ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
   40863          12 :                 ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
   40864           0 :             } else if (reduce == object_reduce || PyErr_Occurred()) {
   40865           0 :                 goto __PYX_BAD;
   40866             :             }
   40867          12 :             setstate = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate);
   40868          12 :             if (!setstate) PyErr_Clear();
   40869          12 :             if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) {
   40870          12 :                 setstate_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate_cython);
   40871          12 :                 if (likely(setstate_cython)) {
   40872          12 :                     ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
   40873          12 :                     ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
   40874           0 :                 } else if (!setstate || PyErr_Occurred()) {
   40875           0 :                     goto __PYX_BAD;
   40876             :                 }
   40877             :             }
   40878          12 :             PyType_Modified((PyTypeObject*)type_obj);
   40879             :         }
   40880             :     }
   40881          12 :     goto __PYX_GOOD;
   40882           0 : __PYX_BAD:
   40883           0 :     if (!PyErr_Occurred()) {
   40884           0 :         __Pyx_TypeName type_obj_name =
   40885             :             __Pyx_PyType_GetName((PyTypeObject*)type_obj);
   40886           0 :         PyErr_Format(PyExc_RuntimeError,
   40887             :             "Unable to initialize pickling for " __Pyx_FMT_TYPENAME, type_obj_name);
   40888             :         __Pyx_DECREF_TypeName(type_obj_name);
   40889             :     }
   40890             :     ret = -1;
   40891          12 : __PYX_GOOD:
   40892             : #if !CYTHON_USE_PYTYPE_LOOKUP
   40893             :     Py_XDECREF(object_reduce);
   40894             :     Py_XDECREF(object_reduce_ex);
   40895             :     Py_XDECREF(object_getstate);
   40896             :     Py_XDECREF(getstate);
   40897             : #endif
   40898          12 :     Py_XDECREF(reduce);
   40899          12 :     Py_XDECREF(reduce_ex);
   40900          12 :     Py_XDECREF(reduce_cython);
   40901          12 :     Py_XDECREF(setstate);
   40902          12 :     Py_XDECREF(setstate_cython);
   40903          12 :     return ret;
   40904             : }
   40905             : #endif
   40906             : 
   40907             : /* TypeImport */
   40908             :   #ifndef __PYX_HAVE_RT_ImportType_3_0_11
   40909             : #define __PYX_HAVE_RT_ImportType_3_0_11
   40910          48 : static PyTypeObject *__Pyx_ImportType_3_0_11(PyObject *module, const char *module_name, const char *class_name,
   40911             :     size_t size, size_t alignment, enum __Pyx_ImportType_CheckSize_3_0_11 check_size)
   40912             : {
   40913          48 :     PyObject *result = 0;
   40914          48 :     char warning[200];
   40915          48 :     Py_ssize_t basicsize;
   40916          48 :     Py_ssize_t itemsize;
   40917             : #if CYTHON_COMPILING_IN_LIMITED_API
   40918             :     PyObject *py_basicsize;
   40919             :     PyObject *py_itemsize;
   40920             : #endif
   40921          48 :     result = PyObject_GetAttrString(module, class_name);
   40922          48 :     if (!result)
   40923           0 :         goto bad;
   40924          48 :     if (!PyType_Check(result)) {
   40925           0 :         PyErr_Format(PyExc_TypeError,
   40926             :             "%.200s.%.200s is not a type object",
   40927             :             module_name, class_name);
   40928           0 :         goto bad;
   40929             :     }
   40930             : #if !CYTHON_COMPILING_IN_LIMITED_API
   40931          48 :     basicsize = ((PyTypeObject *)result)->tp_basicsize;
   40932          48 :     itemsize = ((PyTypeObject *)result)->tp_itemsize;
   40933             : #else
   40934             :     py_basicsize = PyObject_GetAttrString(result, "__basicsize__");
   40935             :     if (!py_basicsize)
   40936             :         goto bad;
   40937             :     basicsize = PyLong_AsSsize_t(py_basicsize);
   40938             :     Py_DECREF(py_basicsize);
   40939             :     py_basicsize = 0;
   40940             :     if (basicsize == (Py_ssize_t)-1 && PyErr_Occurred())
   40941             :         goto bad;
   40942             :     py_itemsize = PyObject_GetAttrString(result, "__itemsize__");
   40943             :     if (!py_itemsize)
   40944             :         goto bad;
   40945             :     itemsize = PyLong_AsSsize_t(py_itemsize);
   40946             :     Py_DECREF(py_itemsize);
   40947             :     py_itemsize = 0;
   40948             :     if (itemsize == (Py_ssize_t)-1 && PyErr_Occurred())
   40949             :         goto bad;
   40950             : #endif
   40951          48 :     if (itemsize) {
   40952           3 :         if (size % alignment) {
   40953           0 :             alignment = size % alignment;
   40954             :         }
   40955           3 :         if (itemsize < (Py_ssize_t)alignment)
   40956             :             itemsize = (Py_ssize_t)alignment;
   40957             :     }
   40958          48 :     if ((size_t)(basicsize + itemsize) < size) {
   40959           0 :         PyErr_Format(PyExc_ValueError,
   40960             :             "%.200s.%.200s size changed, may indicate binary incompatibility. "
   40961             :             "Expected %zd from C header, got %zd from PyObject",
   40962             :             module_name, class_name, size, basicsize+itemsize);
   40963           0 :         goto bad;
   40964             :     }
   40965          48 :     if (check_size == __Pyx_ImportType_CheckSize_Error_3_0_11 &&
   40966           0 :             ((size_t)basicsize > size || (size_t)(basicsize + itemsize) < size)) {
   40967           0 :         PyErr_Format(PyExc_ValueError,
   40968             :             "%.200s.%.200s size changed, may indicate binary incompatibility. "
   40969             :             "Expected %zd from C header, got %zd-%zd from PyObject",
   40970             :             module_name, class_name, size, basicsize, basicsize+itemsize);
   40971           0 :         goto bad;
   40972             :     }
   40973          48 :     else if (check_size == __Pyx_ImportType_CheckSize_Warn_3_0_11 && (size_t)basicsize > size) {
   40974           0 :         PyOS_snprintf(warning, sizeof(warning),
   40975             :             "%s.%s size changed, may indicate binary incompatibility. "
   40976             :             "Expected %zd from C header, got %zd from PyObject",
   40977             :             module_name, class_name, size, basicsize);
   40978           0 :         if (PyErr_WarnEx(NULL, warning, 0) < 0) goto bad;
   40979             :     }
   40980             :     return (PyTypeObject *)result;
   40981           0 : bad:
   40982           0 :     Py_XDECREF(result);
   40983           0 :     return NULL;
   40984             : }
   40985             : #endif
   40986             : 
   40987             : /* Py3UpdateBases */
   40988             :   static PyObject*
   40989           3 : __Pyx_PEP560_update_bases(PyObject *bases)
   40990             : {
   40991           3 :     Py_ssize_t i, j, size_bases;
   40992           3 :     PyObject *base, *meth, *new_base, *result, *new_bases = NULL;
   40993           3 :     size_bases = PyTuple_GET_SIZE(bases);
   40994           6 :     for (i = 0; i < size_bases; i++) {
   40995           3 :         base  = PyTuple_GET_ITEM(bases, i);
   40996           3 :         if (PyType_Check(base)) {
   40997           3 :             if (new_bases) {
   40998           0 :                 if (PyList_Append(new_bases, base) < 0) {
   40999           0 :                     goto error;
   41000             :                 }
   41001             :             }
   41002           3 :             continue;
   41003             :         }
   41004           0 :         meth = __Pyx_PyObject_GetAttrStrNoError(base, __pyx_n_s_mro_entries);
   41005           0 :         if (!meth && PyErr_Occurred()) {
   41006           0 :             goto error;
   41007             :         }
   41008           0 :         if (!meth) {
   41009           0 :             if (new_bases) {
   41010           0 :                 if (PyList_Append(new_bases, base) < 0) {
   41011           0 :                     goto error;
   41012             :                 }
   41013             :             }
   41014           0 :             continue;
   41015             :         }
   41016           0 :         new_base = __Pyx_PyObject_CallOneArg(meth, bases);
   41017           0 :         Py_DECREF(meth);
   41018           0 :         if (!new_base) {
   41019           0 :             goto error;
   41020             :         }
   41021           0 :         if (!PyTuple_Check(new_base)) {
   41022           0 :             PyErr_SetString(PyExc_TypeError,
   41023             :                             "__mro_entries__ must return a tuple");
   41024           0 :             Py_DECREF(new_base);
   41025           0 :             goto error;
   41026             :         }
   41027           0 :         if (!new_bases) {
   41028           0 :             if (!(new_bases = PyList_New(i))) {
   41029           0 :                 goto error;
   41030             :             }
   41031           0 :             for (j = 0; j < i; j++) {
   41032           0 :                 base = PyTuple_GET_ITEM(bases, j);
   41033           0 :                 PyList_SET_ITEM(new_bases, j, base);
   41034           0 :                 Py_INCREF(base);
   41035             :             }
   41036             :         }
   41037           0 :         j = PyList_GET_SIZE(new_bases);
   41038           0 :         if (PyList_SetSlice(new_bases, j, j, new_base) < 0) {
   41039           0 :             goto error;
   41040             :         }
   41041           3 :         Py_DECREF(new_base);
   41042             :     }
   41043           3 :     if (!new_bases) {
   41044           3 :         Py_INCREF(bases);
   41045           3 :         return bases;
   41046             :     }
   41047           0 :     result = PyList_AsTuple(new_bases);
   41048           0 :     Py_DECREF(new_bases);
   41049             :     return result;
   41050           0 : error:
   41051           0 :     Py_XDECREF(new_bases);
   41052           0 :     return NULL;
   41053             : }
   41054             : 
   41055             : /* CalculateMetaclass */
   41056           3 :   static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases) {
   41057           3 :     Py_ssize_t i, nbases;
   41058             : #if CYTHON_ASSUME_SAFE_MACROS
   41059           3 :     nbases = PyTuple_GET_SIZE(bases);
   41060             : #else
   41061             :     nbases = PyTuple_Size(bases);
   41062             :     if (nbases < 0) return NULL;
   41063             : #endif
   41064           6 :     for (i=0; i < nbases; i++) {
   41065           3 :         PyTypeObject *tmptype;
   41066             : #if CYTHON_ASSUME_SAFE_MACROS
   41067           3 :         PyObject *tmp = PyTuple_GET_ITEM(bases, i);
   41068             : #else
   41069             :         PyObject *tmp = PyTuple_GetItem(bases, i);
   41070             :         if (!tmp) return NULL;
   41071             : #endif
   41072           3 :         tmptype = Py_TYPE(tmp);
   41073             : #if PY_MAJOR_VERSION < 3
   41074             :         if (tmptype == &PyClass_Type)
   41075             :             continue;
   41076             : #endif
   41077           3 :         if (!metaclass) {
   41078           3 :             metaclass = tmptype;
   41079           3 :             continue;
   41080             :         }
   41081           0 :         if (PyType_IsSubtype(metaclass, tmptype))
   41082           0 :             continue;
   41083           0 :         if (PyType_IsSubtype(tmptype, metaclass)) {
   41084           0 :             metaclass = tmptype;
   41085           0 :             continue;
   41086             :         }
   41087           0 :         PyErr_SetString(PyExc_TypeError,
   41088             :                         "metaclass conflict: "
   41089             :                         "the metaclass of a derived class "
   41090             :                         "must be a (non-strict) subclass "
   41091             :                         "of the metaclasses of all its bases");
   41092           0 :         return NULL;
   41093             :     }
   41094           3 :     if (!metaclass) {
   41095             : #if PY_MAJOR_VERSION < 3
   41096             :         metaclass = &PyClass_Type;
   41097             : #else
   41098           0 :         metaclass = &PyType_Type;
   41099             : #endif
   41100             :     }
   41101           3 :     Py_INCREF((PyObject*) metaclass);
   41102             :     return (PyObject*) metaclass;
   41103             : }
   41104             : 
   41105             : /* PyObjectCall2Args */
   41106             :   static CYTHON_INLINE PyObject* __Pyx_PyObject_Call2Args(PyObject* function, PyObject* arg1, PyObject* arg2) {
   41107             :     PyObject *args[3] = {NULL, arg1, arg2};
   41108             :     return __Pyx_PyObject_FastCall(function, args+1, 2 | __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET);
   41109             : }
   41110             : 
   41111             : /* PyObjectLookupSpecial */
   41112             :   #if CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS
   41113             : static CYTHON_INLINE PyObject* __Pyx__PyObject_LookupSpecial(PyObject* obj, PyObject* attr_name, int with_error) {
   41114             :     PyObject *res;
   41115             :     PyTypeObject *tp = Py_TYPE(obj);
   41116             : #if PY_MAJOR_VERSION < 3
   41117             :     if (unlikely(PyInstance_Check(obj)))
   41118             :         return with_error ? __Pyx_PyObject_GetAttrStr(obj, attr_name) : __Pyx_PyObject_GetAttrStrNoError(obj, attr_name);
   41119             : #endif
   41120             :     res = _PyType_Lookup(tp, attr_name);
   41121             :     if (likely(res)) {
   41122             :         descrgetfunc f = Py_TYPE(res)->tp_descr_get;
   41123             :         if (!f) {
   41124             :             Py_INCREF(res);
   41125             :         } else {
   41126             :             res = f(res, obj, (PyObject *)tp);
   41127             :         }
   41128             :     } else if (with_error) {
   41129             :         PyErr_SetObject(PyExc_AttributeError, attr_name);
   41130             :     }
   41131             :     return res;
   41132             : }
   41133             : #endif
   41134             : 
   41135             : /* Py3ClassCreate */
   41136           3 :   static PyObject *__Pyx_Py3MetaclassPrepare(PyObject *metaclass, PyObject *bases, PyObject *name,
   41137             :                                            PyObject *qualname, PyObject *mkw, PyObject *modname, PyObject *doc) {
   41138           3 :     PyObject *ns;
   41139           3 :     if (metaclass) {
   41140           3 :         PyObject *prep = __Pyx_PyObject_GetAttrStrNoError(metaclass, __pyx_n_s_prepare);
   41141           3 :         if (prep) {
   41142           3 :             PyObject *pargs[3] = {NULL, name, bases};
   41143           3 :             ns = __Pyx_PyObject_FastCallDict(prep, pargs+1, 2 | __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET, mkw);
   41144           6 :             Py_DECREF(prep);
   41145             :         } else {
   41146           0 :             if (unlikely(PyErr_Occurred()))
   41147             :                 return NULL;
   41148           0 :             ns = PyDict_New();
   41149             :         }
   41150             :     } else {
   41151           0 :         ns = PyDict_New();
   41152             :     }
   41153           3 :     if (unlikely(!ns))
   41154             :         return NULL;
   41155           3 :     if (unlikely(PyObject_SetItem(ns, __pyx_n_s_module, modname) < 0)) goto bad;
   41156             : #if PY_VERSION_HEX >= 0x03030000
   41157           3 :     if (unlikely(PyObject_SetItem(ns, __pyx_n_s_qualname, qualname) < 0)) goto bad;
   41158             : #else
   41159             :     CYTHON_MAYBE_UNUSED_VAR(qualname);
   41160             : #endif
   41161           3 :     if (unlikely(doc && PyObject_SetItem(ns, __pyx_n_s_doc, doc) < 0)) goto bad;
   41162             :     return ns;
   41163           0 : bad:
   41164           0 :     Py_DECREF(ns);
   41165             :     return NULL;
   41166             : }
   41167             : #if PY_VERSION_HEX < 0x030600A4 && CYTHON_PEP487_INIT_SUBCLASS
   41168             : static int __Pyx_SetNamesPEP487(PyObject *type_obj) {
   41169             :     PyTypeObject *type = (PyTypeObject*) type_obj;
   41170             :     PyObject *names_to_set, *key, *value, *set_name, *tmp;
   41171             :     Py_ssize_t i = 0;
   41172             : #if CYTHON_USE_TYPE_SLOTS
   41173             :     names_to_set = PyDict_Copy(type->tp_dict);
   41174             : #else
   41175             :     {
   41176             :         PyObject *d = PyObject_GetAttr(type_obj, __pyx_n_s_dict);
   41177             :         names_to_set = NULL;
   41178             :         if (likely(d)) {
   41179             :             PyObject *names_to_set = PyDict_New();
   41180             :             int ret = likely(names_to_set) ? PyDict_Update(names_to_set, d) : -1;
   41181             :             Py_DECREF(d);
   41182             :             if (unlikely(ret < 0))
   41183             :                 Py_CLEAR(names_to_set);
   41184             :         }
   41185             :     }
   41186             : #endif
   41187             :     if (unlikely(names_to_set == NULL))
   41188             :         goto bad;
   41189             :     while (PyDict_Next(names_to_set, &i, &key, &value)) {
   41190             :         set_name = __Pyx_PyObject_LookupSpecialNoError(value, __pyx_n_s_set_name);
   41191             :         if (unlikely(set_name != NULL)) {
   41192             :             tmp = __Pyx_PyObject_Call2Args(set_name, type_obj, key);
   41193             :             Py_DECREF(set_name);
   41194             :             if (unlikely(tmp == NULL)) {
   41195             :                 __Pyx_TypeName value_type_name =
   41196             :                     __Pyx_PyType_GetName(Py_TYPE(value));
   41197             :                 __Pyx_TypeName type_name = __Pyx_PyType_GetName(type);
   41198             :                 PyErr_Format(PyExc_RuntimeError,
   41199             : #if PY_MAJOR_VERSION >= 3
   41200             :                     "Error calling __set_name__ on '" __Pyx_FMT_TYPENAME "' instance %R " "in '" __Pyx_FMT_TYPENAME "'",
   41201             :                     value_type_name, key, type_name);
   41202             : #else
   41203             :                     "Error calling __set_name__ on '" __Pyx_FMT_TYPENAME "' instance %.100s in '" __Pyx_FMT_TYPENAME "'",
   41204             :                     value_type_name,
   41205             :                     PyString_Check(key) ? PyString_AS_STRING(key) : "?",
   41206             :                     type_name);
   41207             : #endif
   41208             :                 goto bad;
   41209             :             } else {
   41210             :                 Py_DECREF(tmp);
   41211             :             }
   41212             :         }
   41213             :         else if (unlikely(PyErr_Occurred())) {
   41214             :             goto bad;
   41215             :         }
   41216             :     }
   41217             :     Py_DECREF(names_to_set);
   41218             :     return 0;
   41219             : bad:
   41220             :     Py_XDECREF(names_to_set);
   41221             :     return -1;
   41222             : }
   41223             : static PyObject *__Pyx_InitSubclassPEP487(PyObject *type_obj, PyObject *mkw) {
   41224             : #if CYTHON_USE_TYPE_SLOTS && CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   41225             :     PyTypeObject *type = (PyTypeObject*) type_obj;
   41226             :     PyObject *mro = type->tp_mro;
   41227             :     Py_ssize_t i, nbases;
   41228             :     if (unlikely(!mro)) goto done;
   41229             :     (void) &__Pyx_GetBuiltinName;
   41230             :     Py_INCREF(mro);
   41231             :     nbases = PyTuple_GET_SIZE(mro);
   41232             :     assert(PyTuple_GET_ITEM(mro, 0) == type_obj);
   41233             :     for (i = 1; i < nbases-1; i++) {
   41234             :         PyObject *base, *dict, *meth;
   41235             :         base = PyTuple_GET_ITEM(mro, i);
   41236             :         dict = ((PyTypeObject *)base)->tp_dict;
   41237             :         meth = __Pyx_PyDict_GetItemStrWithError(dict, __pyx_n_s_init_subclass);
   41238             :         if (unlikely(meth)) {
   41239             :             descrgetfunc f = Py_TYPE(meth)->tp_descr_get;
   41240             :             PyObject *res;
   41241             :             Py_INCREF(meth);
   41242             :             if (likely(f)) {
   41243             :                 res = f(meth, NULL, type_obj);
   41244             :                 Py_DECREF(meth);
   41245             :                 if (unlikely(!res)) goto bad;
   41246             :                 meth = res;
   41247             :             }
   41248             :             res = __Pyx_PyObject_FastCallDict(meth, NULL, 0, mkw);
   41249             :             Py_DECREF(meth);
   41250             :             if (unlikely(!res)) goto bad;
   41251             :             Py_DECREF(res);
   41252             :             goto done;
   41253             :         } else if (unlikely(PyErr_Occurred())) {
   41254             :             goto bad;
   41255             :         }
   41256             :     }
   41257             : done:
   41258             :     Py_XDECREF(mro);
   41259             :     return type_obj;
   41260             : bad:
   41261             :     Py_XDECREF(mro);
   41262             :     Py_DECREF(type_obj);
   41263             :     return NULL;
   41264             : #else
   41265             :     PyObject *super_type, *super, *func, *res;
   41266             : #if CYTHON_COMPILING_IN_PYPY && !defined(PySuper_Type)
   41267             :     super_type = __Pyx_GetBuiltinName(__pyx_n_s_super);
   41268             : #else
   41269             :     super_type = (PyObject*) &PySuper_Type;
   41270             :     (void) &__Pyx_GetBuiltinName;
   41271             : #endif
   41272             :     super = likely(super_type) ? __Pyx_PyObject_Call2Args(super_type, type_obj, type_obj) : NULL;
   41273             : #if CYTHON_COMPILING_IN_PYPY && !defined(PySuper_Type)
   41274             :     Py_XDECREF(super_type);
   41275             : #endif
   41276             :     if (unlikely(!super)) {
   41277             :         Py_CLEAR(type_obj);
   41278             :         goto done;
   41279             :     }
   41280             :     func = __Pyx_PyObject_GetAttrStrNoError(super, __pyx_n_s_init_subclass);
   41281             :     Py_DECREF(super);
   41282             :     if (likely(!func)) {
   41283             :         if (unlikely(PyErr_Occurred()))
   41284             :             Py_CLEAR(type_obj);
   41285             :         goto done;
   41286             :     }
   41287             :     res = __Pyx_PyObject_FastCallDict(func, NULL, 0, mkw);
   41288             :     Py_DECREF(func);
   41289             :     if (unlikely(!res))
   41290             :         Py_CLEAR(type_obj);
   41291             :     Py_XDECREF(res);
   41292             : done:
   41293             :     return type_obj;
   41294             : #endif
   41295             : }
   41296             : #endif
   41297           3 : static PyObject *__Pyx_Py3ClassCreate(PyObject *metaclass, PyObject *name, PyObject *bases,
   41298             :                                       PyObject *dict, PyObject *mkw,
   41299             :                                       int calculate_metaclass, int allow_py2_metaclass) {
   41300           3 :     PyObject *result;
   41301           3 :     PyObject *owned_metaclass = NULL;
   41302           3 :     PyObject *margs[4] = {NULL, name, bases, dict};
   41303           3 :     if (allow_py2_metaclass) {
   41304           0 :         owned_metaclass = PyObject_GetItem(dict, __pyx_n_s_metaclass);
   41305           0 :         if (owned_metaclass) {
   41306             :             metaclass = owned_metaclass;
   41307           0 :         } else if (likely(PyErr_ExceptionMatches(PyExc_KeyError))) {
   41308           0 :             PyErr_Clear();
   41309             :         } else {
   41310             :             return NULL;
   41311             :         }
   41312             :     }
   41313           3 :     if (calculate_metaclass && (!metaclass || PyType_Check(metaclass))) {
   41314           0 :         metaclass = __Pyx_CalculateMetaclass((PyTypeObject*) metaclass, bases);
   41315           0 :         Py_XDECREF(owned_metaclass);
   41316           0 :         if (unlikely(!metaclass))
   41317             :             return NULL;
   41318             :         owned_metaclass = metaclass;
   41319             :     }
   41320           3 :     result = __Pyx_PyObject_FastCallDict(metaclass, margs+1, 3 | __Pyx_PY_VECTORCALL_ARGUMENTS_OFFSET,
   41321             : #if PY_VERSION_HEX < 0x030600A4
   41322             :         (metaclass == (PyObject*)&PyType_Type) ? NULL : mkw
   41323             : #else
   41324             :         mkw
   41325             : #endif
   41326             :     );
   41327           3 :     Py_XDECREF(owned_metaclass);
   41328             : #if PY_VERSION_HEX < 0x030600A4 && CYTHON_PEP487_INIT_SUBCLASS
   41329             :     if (likely(result) && likely(PyType_Check(result))) {
   41330             :         if (unlikely(__Pyx_SetNamesPEP487(result) < 0)) {
   41331             :             Py_CLEAR(result);
   41332             :         } else {
   41333             :             result = __Pyx_InitSubclassPEP487(result, mkw);
   41334             :         }
   41335             :     }
   41336             : #else
   41337           3 :     (void) &__Pyx_GetBuiltinName;
   41338             : #endif
   41339           3 :     return result;
   41340             : }
   41341             : 
   41342             : /* FetchSharedCythonModule */
   41343           6 :   static PyObject *__Pyx_FetchSharedCythonABIModule(void) {
   41344           6 :     return __Pyx_PyImport_AddModuleRef((char*) __PYX_ABI_MODULE_NAME);
   41345             : }
   41346             : 
   41347             : /* FetchCommonType */
   41348           6 :   static int __Pyx_VerifyCachedType(PyObject *cached_type,
   41349             :                                const char *name,
   41350             :                                Py_ssize_t basicsize,
   41351             :                                Py_ssize_t expected_basicsize) {
   41352           6 :     if (!PyType_Check(cached_type)) {
   41353           0 :         PyErr_Format(PyExc_TypeError,
   41354             :             "Shared Cython type %.200s is not a type object", name);
   41355           0 :         return -1;
   41356             :     }
   41357           6 :     if (basicsize != expected_basicsize) {
   41358           0 :         PyErr_Format(PyExc_TypeError,
   41359             :             "Shared Cython type %.200s has the wrong size, try recompiling",
   41360             :             name);
   41361           0 :         return -1;
   41362             :     }
   41363             :     return 0;
   41364             : }
   41365             : #if !CYTHON_USE_TYPE_SPECS
   41366           6 : static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type) {
   41367           6 :     PyObject* abi_module;
   41368           6 :     const char* object_name;
   41369           6 :     PyTypeObject *cached_type = NULL;
   41370           6 :     abi_module = __Pyx_FetchSharedCythonABIModule();
   41371           6 :     if (!abi_module) return NULL;
   41372           6 :     object_name = strrchr(type->tp_name, '.');
   41373           6 :     object_name = object_name ? object_name+1 : type->tp_name;
   41374           6 :     cached_type = (PyTypeObject*) PyObject_GetAttrString(abi_module, object_name);
   41375           6 :     if (cached_type) {
   41376           6 :         if (__Pyx_VerifyCachedType(
   41377             :               (PyObject *)cached_type,
   41378             :               object_name,
   41379             :               cached_type->tp_basicsize,
   41380             :               type->tp_basicsize) < 0) {
   41381           0 :             goto bad;
   41382             :         }
   41383           6 :         goto done;
   41384             :     }
   41385           0 :     if (!PyErr_ExceptionMatches(PyExc_AttributeError)) goto bad;
   41386           0 :     PyErr_Clear();
   41387           0 :     if (PyType_Ready(type) < 0) goto bad;
   41388           0 :     if (PyObject_SetAttrString(abi_module, object_name, (PyObject *)type) < 0)
   41389           0 :         goto bad;
   41390           0 :     Py_INCREF(type);
   41391             :     cached_type = type;
   41392           6 : done:
   41393           6 :     Py_DECREF(abi_module);
   41394             :     return cached_type;
   41395           0 : bad:
   41396           0 :     Py_XDECREF(cached_type);
   41397           0 :     cached_type = NULL;
   41398           0 :     goto done;
   41399             : }
   41400             : #else
   41401             : static PyTypeObject *__Pyx_FetchCommonTypeFromSpec(PyObject *module, PyType_Spec *spec, PyObject *bases) {
   41402             :     PyObject *abi_module, *cached_type = NULL;
   41403             :     const char* object_name = strrchr(spec->name, '.');
   41404             :     object_name = object_name ? object_name+1 : spec->name;
   41405             :     abi_module = __Pyx_FetchSharedCythonABIModule();
   41406             :     if (!abi_module) return NULL;
   41407             :     cached_type = PyObject_GetAttrString(abi_module, object_name);
   41408             :     if (cached_type) {
   41409             :         Py_ssize_t basicsize;
   41410             : #if CYTHON_COMPILING_IN_LIMITED_API
   41411             :         PyObject *py_basicsize;
   41412             :         py_basicsize = PyObject_GetAttrString(cached_type, "__basicsize__");
   41413             :         if (unlikely(!py_basicsize)) goto bad;
   41414             :         basicsize = PyLong_AsSsize_t(py_basicsize);
   41415             :         Py_DECREF(py_basicsize);
   41416             :         py_basicsize = 0;
   41417             :         if (unlikely(basicsize == (Py_ssize_t)-1) && PyErr_Occurred()) goto bad;
   41418             : #else
   41419             :         basicsize = likely(PyType_Check(cached_type)) ? ((PyTypeObject*) cached_type)->tp_basicsize : -1;
   41420             : #endif
   41421             :         if (__Pyx_VerifyCachedType(
   41422             :               cached_type,
   41423             :               object_name,
   41424             :               basicsize,
   41425             :               spec->basicsize) < 0) {
   41426             :             goto bad;
   41427             :         }
   41428             :         goto done;
   41429             :     }
   41430             :     if (!PyErr_ExceptionMatches(PyExc_AttributeError)) goto bad;
   41431             :     PyErr_Clear();
   41432             :     CYTHON_UNUSED_VAR(module);
   41433             :     cached_type = __Pyx_PyType_FromModuleAndSpec(abi_module, spec, bases);
   41434             :     if (unlikely(!cached_type)) goto bad;
   41435             :     if (unlikely(__Pyx_fix_up_extension_type_from_spec(spec, (PyTypeObject *) cached_type) < 0)) goto bad;
   41436             :     if (PyObject_SetAttrString(abi_module, object_name, cached_type) < 0) goto bad;
   41437             : done:
   41438             :     Py_DECREF(abi_module);
   41439             :     assert(cached_type == NULL || PyType_Check(cached_type));
   41440             :     return (PyTypeObject *) cached_type;
   41441             : bad:
   41442             :     Py_XDECREF(cached_type);
   41443             :     cached_type = NULL;
   41444             :     goto done;
   41445             : }
   41446             : #endif
   41447             : 
   41448             : /* PyVectorcallFastCallDict */
   41449             :   #if CYTHON_METH_FASTCALL
   41450           0 : static PyObject *__Pyx_PyVectorcall_FastCallDict_kw(PyObject *func, __pyx_vectorcallfunc vc, PyObject *const *args, size_t nargs, PyObject *kw)
   41451             : {
   41452           0 :     PyObject *res = NULL;
   41453           0 :     PyObject *kwnames;
   41454           0 :     PyObject **newargs;
   41455           0 :     PyObject **kwvalues;
   41456           0 :     Py_ssize_t i, pos;
   41457           0 :     size_t j;
   41458           0 :     PyObject *key, *value;
   41459           0 :     unsigned long keys_are_strings;
   41460           0 :     Py_ssize_t nkw = PyDict_GET_SIZE(kw);
   41461           0 :     newargs = (PyObject **)PyMem_Malloc((nargs + (size_t)nkw) * sizeof(args[0]));
   41462           0 :     if (unlikely(newargs == NULL)) {
   41463           0 :         PyErr_NoMemory();
   41464           0 :         return NULL;
   41465             :     }
   41466           0 :     for (j = 0; j < nargs; j++) newargs[j] = args[j];
   41467           0 :     kwnames = PyTuple_New(nkw);
   41468           0 :     if (unlikely(kwnames == NULL)) {
   41469           0 :         PyMem_Free(newargs);
   41470           0 :         return NULL;
   41471             :     }
   41472           0 :     kwvalues = newargs + nargs;
   41473           0 :     pos = i = 0;
   41474           0 :     keys_are_strings = Py_TPFLAGS_UNICODE_SUBCLASS;
   41475           0 :     while (PyDict_Next(kw, &pos, &key, &value)) {
   41476           0 :         keys_are_strings &= Py_TYPE(key)->tp_flags;
   41477           0 :         Py_INCREF(key);
   41478           0 :         Py_INCREF(value);
   41479           0 :         PyTuple_SET_ITEM(kwnames, i, key);
   41480           0 :         kwvalues[i] = value;
   41481           0 :         i++;
   41482             :     }
   41483           0 :     if (unlikely(!keys_are_strings)) {
   41484           0 :         PyErr_SetString(PyExc_TypeError, "keywords must be strings");
   41485           0 :         goto cleanup;
   41486             :     }
   41487           0 :     res = vc(func, newargs, nargs, kwnames);
   41488           0 : cleanup:
   41489           0 :     Py_DECREF(kwnames);
   41490           0 :     for (i = 0; i < nkw; i++)
   41491           0 :         Py_DECREF(kwvalues[i]);
   41492           0 :     PyMem_Free(newargs);
   41493           0 :     return res;
   41494             : }
   41495           0 : static CYTHON_INLINE PyObject *__Pyx_PyVectorcall_FastCallDict(PyObject *func, __pyx_vectorcallfunc vc, PyObject *const *args, size_t nargs, PyObject *kw)
   41496             : {
   41497           0 :     if (likely(kw == NULL) || PyDict_GET_SIZE(kw) == 0) {
   41498           0 :         return vc(func, args, nargs, NULL);
   41499             :     }
   41500           0 :     return __Pyx_PyVectorcall_FastCallDict_kw(func, vc, args, nargs, kw);
   41501             : }
   41502             : #endif
   41503             : 
   41504             : /* CythonFunctionShared */
   41505             :   #if CYTHON_COMPILING_IN_LIMITED_API
   41506             : static CYTHON_INLINE int __Pyx__IsSameCyOrCFunction(PyObject *func, void *cfunc) {
   41507             :     if (__Pyx_CyFunction_Check(func)) {
   41508             :         return PyCFunction_GetFunction(((__pyx_CyFunctionObject*)func)->func) == (PyCFunction) cfunc;
   41509             :     } else if (PyCFunction_Check(func)) {
   41510             :         return PyCFunction_GetFunction(func) == (PyCFunction) cfunc;
   41511             :     }
   41512             :     return 0;
   41513             : }
   41514             : #else
   41515             : static CYTHON_INLINE int __Pyx__IsSameCyOrCFunction(PyObject *func, void *cfunc) {
   41516             :     return __Pyx_CyOrPyCFunction_Check(func) && __Pyx_CyOrPyCFunction_GET_FUNCTION(func) == (PyCFunction) cfunc;
   41517             : }
   41518             : #endif
   41519           0 : static CYTHON_INLINE void __Pyx__CyFunction_SetClassObj(__pyx_CyFunctionObject* f, PyObject* classobj) {
   41520             : #if PY_VERSION_HEX < 0x030900B1 || CYTHON_COMPILING_IN_LIMITED_API
   41521             :     __Pyx_Py_XDECREF_SET(
   41522             :         __Pyx_CyFunction_GetClassObj(f),
   41523             :             ((classobj) ? __Pyx_NewRef(classobj) : NULL));
   41524             : #else
   41525           0 :     __Pyx_Py_XDECREF_SET(
   41526             :         ((PyCMethodObject *) (f))->mm_class,
   41527             :         (PyTypeObject*)((classobj) ? __Pyx_NewRef(classobj) : NULL));
   41528             : #endif
   41529           0 : }
   41530             : static PyObject *
   41531           0 : __Pyx_CyFunction_get_doc(__pyx_CyFunctionObject *op, void *closure)
   41532             : {
   41533           0 :     CYTHON_UNUSED_VAR(closure);
   41534           0 :     if (unlikely(op->func_doc == NULL)) {
   41535             : #if CYTHON_COMPILING_IN_LIMITED_API
   41536             :         op->func_doc = PyObject_GetAttrString(op->func, "__doc__");
   41537             :         if (unlikely(!op->func_doc)) return NULL;
   41538             : #else
   41539           0 :         if (((PyCFunctionObject*)op)->m_ml->ml_doc) {
   41540             : #if PY_MAJOR_VERSION >= 3
   41541           0 :             op->func_doc = PyUnicode_FromString(((PyCFunctionObject*)op)->m_ml->ml_doc);
   41542             : #else
   41543             :             op->func_doc = PyString_FromString(((PyCFunctionObject*)op)->m_ml->ml_doc);
   41544             : #endif
   41545           0 :             if (unlikely(op->func_doc == NULL))
   41546             :                 return NULL;
   41547             :         } else {
   41548           0 :             Py_INCREF(Py_None);
   41549           0 :             return Py_None;
   41550             :         }
   41551             : #endif
   41552             :     }
   41553           0 :     Py_INCREF(op->func_doc);
   41554             :     return op->func_doc;
   41555             : }
   41556             : static int
   41557           0 : __Pyx_CyFunction_set_doc(__pyx_CyFunctionObject *op, PyObject *value, void *context)
   41558             : {
   41559           0 :     CYTHON_UNUSED_VAR(context);
   41560           0 :     if (value == NULL) {
   41561           0 :         value = Py_None;
   41562             :     }
   41563           0 :     Py_INCREF(value);
   41564           0 :     __Pyx_Py_XDECREF_SET(op->func_doc, value);
   41565           0 :     return 0;
   41566             : }
   41567             : static PyObject *
   41568           0 : __Pyx_CyFunction_get_name(__pyx_CyFunctionObject *op, void *context)
   41569             : {
   41570           0 :     CYTHON_UNUSED_VAR(context);
   41571           0 :     if (unlikely(op->func_name == NULL)) {
   41572             : #if CYTHON_COMPILING_IN_LIMITED_API
   41573             :         op->func_name = PyObject_GetAttrString(op->func, "__name__");
   41574             : #elif PY_MAJOR_VERSION >= 3
   41575           0 :         op->func_name = PyUnicode_InternFromString(((PyCFunctionObject*)op)->m_ml->ml_name);
   41576             : #else
   41577             :         op->func_name = PyString_InternFromString(((PyCFunctionObject*)op)->m_ml->ml_name);
   41578             : #endif
   41579           0 :         if (unlikely(op->func_name == NULL))
   41580             :             return NULL;
   41581             :     }
   41582           0 :     Py_INCREF(op->func_name);
   41583             :     return op->func_name;
   41584             : }
   41585             : static int
   41586           0 : __Pyx_CyFunction_set_name(__pyx_CyFunctionObject *op, PyObject *value, void *context)
   41587             : {
   41588           0 :     CYTHON_UNUSED_VAR(context);
   41589             : #if PY_MAJOR_VERSION >= 3
   41590           0 :     if (unlikely(value == NULL || !PyUnicode_Check(value)))
   41591             : #else
   41592             :     if (unlikely(value == NULL || !PyString_Check(value)))
   41593             : #endif
   41594             :     {
   41595           0 :         PyErr_SetString(PyExc_TypeError,
   41596             :                         "__name__ must be set to a string object");
   41597           0 :         return -1;
   41598             :     }
   41599           0 :     Py_INCREF(value);
   41600           0 :     __Pyx_Py_XDECREF_SET(op->func_name, value);
   41601           0 :     return 0;
   41602             : }
   41603             : static PyObject *
   41604           0 : __Pyx_CyFunction_get_qualname(__pyx_CyFunctionObject *op, void *context)
   41605             : {
   41606           0 :     CYTHON_UNUSED_VAR(context);
   41607           0 :     Py_INCREF(op->func_qualname);
   41608           0 :     return op->func_qualname;
   41609             : }
   41610             : static int
   41611           0 : __Pyx_CyFunction_set_qualname(__pyx_CyFunctionObject *op, PyObject *value, void *context)
   41612             : {
   41613           0 :     CYTHON_UNUSED_VAR(context);
   41614             : #if PY_MAJOR_VERSION >= 3
   41615           0 :     if (unlikely(value == NULL || !PyUnicode_Check(value)))
   41616             : #else
   41617             :     if (unlikely(value == NULL || !PyString_Check(value)))
   41618             : #endif
   41619             :     {
   41620           0 :         PyErr_SetString(PyExc_TypeError,
   41621             :                         "__qualname__ must be set to a string object");
   41622           0 :         return -1;
   41623             :     }
   41624           0 :     Py_INCREF(value);
   41625           0 :     __Pyx_Py_XDECREF_SET(op->func_qualname, value);
   41626           0 :     return 0;
   41627             : }
   41628             : static PyObject *
   41629           0 : __Pyx_CyFunction_get_dict(__pyx_CyFunctionObject *op, void *context)
   41630             : {
   41631           0 :     CYTHON_UNUSED_VAR(context);
   41632           0 :     if (unlikely(op->func_dict == NULL)) {
   41633           0 :         op->func_dict = PyDict_New();
   41634           0 :         if (unlikely(op->func_dict == NULL))
   41635             :             return NULL;
   41636             :     }
   41637           0 :     Py_INCREF(op->func_dict);
   41638             :     return op->func_dict;
   41639             : }
   41640             : static int
   41641           0 : __Pyx_CyFunction_set_dict(__pyx_CyFunctionObject *op, PyObject *value, void *context)
   41642             : {
   41643           0 :     CYTHON_UNUSED_VAR(context);
   41644           0 :     if (unlikely(value == NULL)) {
   41645           0 :         PyErr_SetString(PyExc_TypeError,
   41646             :                "function's dictionary may not be deleted");
   41647           0 :         return -1;
   41648             :     }
   41649           0 :     if (unlikely(!PyDict_Check(value))) {
   41650           0 :         PyErr_SetString(PyExc_TypeError,
   41651             :                "setting function's dictionary to a non-dict");
   41652           0 :         return -1;
   41653             :     }
   41654           0 :     Py_INCREF(value);
   41655           0 :     __Pyx_Py_XDECREF_SET(op->func_dict, value);
   41656           0 :     return 0;
   41657             : }
   41658             : static PyObject *
   41659           0 : __Pyx_CyFunction_get_globals(__pyx_CyFunctionObject *op, void *context)
   41660             : {
   41661           0 :     CYTHON_UNUSED_VAR(context);
   41662           0 :     Py_INCREF(op->func_globals);
   41663           0 :     return op->func_globals;
   41664             : }
   41665             : static PyObject *
   41666           0 : __Pyx_CyFunction_get_closure(__pyx_CyFunctionObject *op, void *context)
   41667             : {
   41668           0 :     CYTHON_UNUSED_VAR(op);
   41669           0 :     CYTHON_UNUSED_VAR(context);
   41670           0 :     Py_INCREF(Py_None);
   41671           0 :     return Py_None;
   41672             : }
   41673             : static PyObject *
   41674           0 : __Pyx_CyFunction_get_code(__pyx_CyFunctionObject *op, void *context)
   41675             : {
   41676           0 :     PyObject* result = (op->func_code) ? op->func_code : Py_None;
   41677           0 :     CYTHON_UNUSED_VAR(context);
   41678           0 :     Py_INCREF(result);
   41679           0 :     return result;
   41680             : }
   41681             : static int
   41682           0 : __Pyx_CyFunction_init_defaults(__pyx_CyFunctionObject *op) {
   41683           0 :     int result = 0;
   41684           0 :     PyObject *res = op->defaults_getter((PyObject *) op);
   41685           0 :     if (unlikely(!res))
   41686             :         return -1;
   41687             :     #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   41688           0 :     op->defaults_tuple = PyTuple_GET_ITEM(res, 0);
   41689           0 :     Py_INCREF(op->defaults_tuple);
   41690           0 :     op->defaults_kwdict = PyTuple_GET_ITEM(res, 1);
   41691           0 :     Py_INCREF(op->defaults_kwdict);
   41692             :     #else
   41693             :     op->defaults_tuple = __Pyx_PySequence_ITEM(res, 0);
   41694             :     if (unlikely(!op->defaults_tuple)) result = -1;
   41695             :     else {
   41696             :         op->defaults_kwdict = __Pyx_PySequence_ITEM(res, 1);
   41697             :         if (unlikely(!op->defaults_kwdict)) result = -1;
   41698             :     }
   41699             :     #endif
   41700           0 :     Py_DECREF(res);
   41701             :     return result;
   41702             : }
   41703             : static int
   41704           0 : __Pyx_CyFunction_set_defaults(__pyx_CyFunctionObject *op, PyObject* value, void *context) {
   41705           0 :     CYTHON_UNUSED_VAR(context);
   41706           0 :     if (!value) {
   41707             :         value = Py_None;
   41708           0 :     } else if (unlikely(value != Py_None && !PyTuple_Check(value))) {
   41709           0 :         PyErr_SetString(PyExc_TypeError,
   41710             :                         "__defaults__ must be set to a tuple object");
   41711           0 :         return -1;
   41712             :     }
   41713           0 :     PyErr_WarnEx(PyExc_RuntimeWarning, "changes to cyfunction.__defaults__ will not "
   41714             :                  "currently affect the values used in function calls", 1);
   41715           0 :     Py_INCREF(value);
   41716           0 :     __Pyx_Py_XDECREF_SET(op->defaults_tuple, value);
   41717           0 :     return 0;
   41718             : }
   41719             : static PyObject *
   41720           0 : __Pyx_CyFunction_get_defaults(__pyx_CyFunctionObject *op, void *context) {
   41721           0 :     PyObject* result = op->defaults_tuple;
   41722           0 :     CYTHON_UNUSED_VAR(context);
   41723           0 :     if (unlikely(!result)) {
   41724           0 :         if (op->defaults_getter) {
   41725           0 :             if (unlikely(__Pyx_CyFunction_init_defaults(op) < 0)) return NULL;
   41726           0 :             result = op->defaults_tuple;
   41727             :         } else {
   41728             :             result = Py_None;
   41729             :         }
   41730             :     }
   41731           0 :     Py_INCREF(result);
   41732             :     return result;
   41733             : }
   41734             : static int
   41735           0 : __Pyx_CyFunction_set_kwdefaults(__pyx_CyFunctionObject *op, PyObject* value, void *context) {
   41736           0 :     CYTHON_UNUSED_VAR(context);
   41737           0 :     if (!value) {
   41738             :         value = Py_None;
   41739           0 :     } else if (unlikely(value != Py_None && !PyDict_Check(value))) {
   41740           0 :         PyErr_SetString(PyExc_TypeError,
   41741             :                         "__kwdefaults__ must be set to a dict object");
   41742           0 :         return -1;
   41743             :     }
   41744           0 :     PyErr_WarnEx(PyExc_RuntimeWarning, "changes to cyfunction.__kwdefaults__ will not "
   41745             :                  "currently affect the values used in function calls", 1);
   41746           0 :     Py_INCREF(value);
   41747           0 :     __Pyx_Py_XDECREF_SET(op->defaults_kwdict, value);
   41748           0 :     return 0;
   41749             : }
   41750             : static PyObject *
   41751           0 : __Pyx_CyFunction_get_kwdefaults(__pyx_CyFunctionObject *op, void *context) {
   41752           0 :     PyObject* result = op->defaults_kwdict;
   41753           0 :     CYTHON_UNUSED_VAR(context);
   41754           0 :     if (unlikely(!result)) {
   41755           0 :         if (op->defaults_getter) {
   41756           0 :             if (unlikely(__Pyx_CyFunction_init_defaults(op) < 0)) return NULL;
   41757           0 :             result = op->defaults_kwdict;
   41758             :         } else {
   41759             :             result = Py_None;
   41760             :         }
   41761             :     }
   41762           0 :     Py_INCREF(result);
   41763             :     return result;
   41764             : }
   41765             : static int
   41766           0 : __Pyx_CyFunction_set_annotations(__pyx_CyFunctionObject *op, PyObject* value, void *context) {
   41767           0 :     CYTHON_UNUSED_VAR(context);
   41768           0 :     if (!value || value == Py_None) {
   41769             :         value = NULL;
   41770           0 :     } else if (unlikely(!PyDict_Check(value))) {
   41771           0 :         PyErr_SetString(PyExc_TypeError,
   41772             :                         "__annotations__ must be set to a dict object");
   41773           0 :         return -1;
   41774             :     }
   41775           0 :     Py_XINCREF(value);
   41776           0 :     __Pyx_Py_XDECREF_SET(op->func_annotations, value);
   41777           0 :     return 0;
   41778             : }
   41779             : static PyObject *
   41780           0 : __Pyx_CyFunction_get_annotations(__pyx_CyFunctionObject *op, void *context) {
   41781           0 :     PyObject* result = op->func_annotations;
   41782           0 :     CYTHON_UNUSED_VAR(context);
   41783           0 :     if (unlikely(!result)) {
   41784           0 :         result = PyDict_New();
   41785           0 :         if (unlikely(!result)) return NULL;
   41786           0 :         op->func_annotations = result;
   41787             :     }
   41788           0 :     Py_INCREF(result);
   41789             :     return result;
   41790             : }
   41791             : static PyObject *
   41792           0 : __Pyx_CyFunction_get_is_coroutine(__pyx_CyFunctionObject *op, void *context) {
   41793           0 :     int is_coroutine;
   41794           0 :     CYTHON_UNUSED_VAR(context);
   41795           0 :     if (op->func_is_coroutine) {
   41796           0 :         return __Pyx_NewRef(op->func_is_coroutine);
   41797             :     }
   41798           0 :     is_coroutine = op->flags & __Pyx_CYFUNCTION_COROUTINE;
   41799             : #if PY_VERSION_HEX >= 0x03050000
   41800           0 :     if (is_coroutine) {
   41801           0 :         PyObject *module, *fromlist, *marker = __pyx_n_s_is_coroutine;
   41802           0 :         fromlist = PyList_New(1);
   41803           0 :         if (unlikely(!fromlist)) return NULL;
   41804           0 :         Py_INCREF(marker);
   41805             : #if CYTHON_ASSUME_SAFE_MACROS
   41806           0 :         PyList_SET_ITEM(fromlist, 0, marker);
   41807             : #else
   41808             :         if (unlikely(PyList_SetItem(fromlist, 0, marker) < 0)) {
   41809             :             Py_DECREF(marker);
   41810             :             Py_DECREF(fromlist);
   41811             :             return NULL;
   41812             :         }
   41813             : #endif
   41814           0 :         module = PyImport_ImportModuleLevelObject(__pyx_n_s_asyncio_coroutines, NULL, NULL, fromlist, 0);
   41815           0 :         Py_DECREF(fromlist);
   41816           0 :         if (unlikely(!module)) goto ignore;
   41817           0 :         op->func_is_coroutine = __Pyx_PyObject_GetAttrStr(module, marker);
   41818           0 :         Py_DECREF(module);
   41819           0 :         if (likely(op->func_is_coroutine)) {
   41820           0 :             return __Pyx_NewRef(op->func_is_coroutine);
   41821             :         }
   41822           0 : ignore:
   41823           0 :         PyErr_Clear();
   41824             :     }
   41825             : #endif
   41826           0 :     op->func_is_coroutine = __Pyx_PyBool_FromLong(is_coroutine);
   41827           0 :     return __Pyx_NewRef(op->func_is_coroutine);
   41828             : }
   41829             : #if CYTHON_COMPILING_IN_LIMITED_API
   41830             : static PyObject *
   41831             : __Pyx_CyFunction_get_module(__pyx_CyFunctionObject *op, void *context) {
   41832             :     CYTHON_UNUSED_VAR(context);
   41833             :     return PyObject_GetAttrString(op->func, "__module__");
   41834             : }
   41835             : static int
   41836             : __Pyx_CyFunction_set_module(__pyx_CyFunctionObject *op, PyObject* value, void *context) {
   41837             :     CYTHON_UNUSED_VAR(context);
   41838             :     return PyObject_SetAttrString(op->func, "__module__", value);
   41839             : }
   41840             : #endif
   41841             : static PyGetSetDef __pyx_CyFunction_getsets[] = {
   41842             :     {(char *) "func_doc", (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0},
   41843             :     {(char *) "__doc__",  (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0},
   41844             :     {(char *) "func_name", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0},
   41845             :     {(char *) "__name__", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0},
   41846             :     {(char *) "__qualname__", (getter)__Pyx_CyFunction_get_qualname, (setter)__Pyx_CyFunction_set_qualname, 0, 0},
   41847             :     {(char *) "func_dict", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0},
   41848             :     {(char *) "__dict__", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0},
   41849             :     {(char *) "func_globals", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0},
   41850             :     {(char *) "__globals__", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0},
   41851             :     {(char *) "func_closure", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0},
   41852             :     {(char *) "__closure__", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0},
   41853             :     {(char *) "func_code", (getter)__Pyx_CyFunction_get_code, 0, 0, 0},
   41854             :     {(char *) "__code__", (getter)__Pyx_CyFunction_get_code, 0, 0, 0},
   41855             :     {(char *) "func_defaults", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0},
   41856             :     {(char *) "__defaults__", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0},
   41857             :     {(char *) "__kwdefaults__", (getter)__Pyx_CyFunction_get_kwdefaults, (setter)__Pyx_CyFunction_set_kwdefaults, 0, 0},
   41858             :     {(char *) "__annotations__", (getter)__Pyx_CyFunction_get_annotations, (setter)__Pyx_CyFunction_set_annotations, 0, 0},
   41859             :     {(char *) "_is_coroutine", (getter)__Pyx_CyFunction_get_is_coroutine, 0, 0, 0},
   41860             : #if CYTHON_COMPILING_IN_LIMITED_API
   41861             :     {"__module__", (getter)__Pyx_CyFunction_get_module, (setter)__Pyx_CyFunction_set_module, 0, 0},
   41862             : #endif
   41863             :     {0, 0, 0, 0, 0}
   41864             : };
   41865             : static PyMemberDef __pyx_CyFunction_members[] = {
   41866             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41867             :     {(char *) "__module__", T_OBJECT, offsetof(PyCFunctionObject, m_module), 0, 0},
   41868             : #endif
   41869             : #if CYTHON_USE_TYPE_SPECS
   41870             :     {(char *) "__dictoffset__", T_PYSSIZET, offsetof(__pyx_CyFunctionObject, func_dict), READONLY, 0},
   41871             : #if CYTHON_METH_FASTCALL
   41872             : #if CYTHON_BACKPORT_VECTORCALL
   41873             :     {(char *) "__vectorcalloffset__", T_PYSSIZET, offsetof(__pyx_CyFunctionObject, func_vectorcall), READONLY, 0},
   41874             : #else
   41875             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41876             :     {(char *) "__vectorcalloffset__", T_PYSSIZET, offsetof(PyCFunctionObject, vectorcall), READONLY, 0},
   41877             : #endif
   41878             : #endif
   41879             : #endif
   41880             : #if PY_VERSION_HEX < 0x030500A0 || CYTHON_COMPILING_IN_LIMITED_API
   41881             :     {(char *) "__weaklistoffset__", T_PYSSIZET, offsetof(__pyx_CyFunctionObject, func_weakreflist), READONLY, 0},
   41882             : #else
   41883             :     {(char *) "__weaklistoffset__", T_PYSSIZET, offsetof(PyCFunctionObject, m_weakreflist), READONLY, 0},
   41884             : #endif
   41885             : #endif
   41886             :     {0, 0, 0,  0, 0}
   41887             : };
   41888             : static PyObject *
   41889           0 : __Pyx_CyFunction_reduce(__pyx_CyFunctionObject *m, PyObject *args)
   41890             : {
   41891           0 :     CYTHON_UNUSED_VAR(args);
   41892             : #if PY_MAJOR_VERSION >= 3
   41893           0 :     Py_INCREF(m->func_qualname);
   41894           0 :     return m->func_qualname;
   41895             : #else
   41896             :     return PyString_FromString(((PyCFunctionObject*)m)->m_ml->ml_name);
   41897             : #endif
   41898             : }
   41899             : static PyMethodDef __pyx_CyFunction_methods[] = {
   41900             :     {"__reduce__", (PyCFunction)__Pyx_CyFunction_reduce, METH_VARARGS, 0},
   41901             :     {0, 0, 0, 0}
   41902             : };
   41903             : #if PY_VERSION_HEX < 0x030500A0 || CYTHON_COMPILING_IN_LIMITED_API
   41904             : #define __Pyx_CyFunction_weakreflist(cyfunc) ((cyfunc)->func_weakreflist)
   41905             : #else
   41906             : #define __Pyx_CyFunction_weakreflist(cyfunc) (((PyCFunctionObject*)cyfunc)->m_weakreflist)
   41907             : #endif
   41908         102 : static PyObject *__Pyx_CyFunction_Init(__pyx_CyFunctionObject *op, PyMethodDef *ml, int flags, PyObject* qualname,
   41909             :                                        PyObject *closure, PyObject *module, PyObject* globals, PyObject* code) {
   41910             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41911         102 :     PyCFunctionObject *cf = (PyCFunctionObject*) op;
   41912             : #endif
   41913         102 :     if (unlikely(op == NULL))
   41914             :         return NULL;
   41915             : #if CYTHON_COMPILING_IN_LIMITED_API
   41916             :     op->func = PyCFunction_NewEx(ml, (PyObject*)op, module);
   41917             :     if (unlikely(!op->func)) return NULL;
   41918             : #endif
   41919         102 :     op->flags = flags;
   41920         102 :     __Pyx_CyFunction_weakreflist(op) = NULL;
   41921             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41922         102 :     cf->m_ml = ml;
   41923         102 :     cf->m_self = (PyObject *) op;
   41924             : #endif
   41925         102 :     Py_XINCREF(closure);
   41926         102 :     op->func_closure = closure;
   41927             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41928         102 :     Py_XINCREF(module);
   41929         102 :     cf->m_module = module;
   41930             : #endif
   41931         102 :     op->func_dict = NULL;
   41932         102 :     op->func_name = NULL;
   41933         102 :     Py_INCREF(qualname);
   41934         102 :     op->func_qualname = qualname;
   41935         102 :     op->func_doc = NULL;
   41936             : #if PY_VERSION_HEX < 0x030900B1 || CYTHON_COMPILING_IN_LIMITED_API
   41937             :     op->func_classobj = NULL;
   41938             : #else
   41939         102 :     ((PyCMethodObject*)op)->mm_class = NULL;
   41940             : #endif
   41941         102 :     op->func_globals = globals;
   41942         102 :     Py_INCREF(op->func_globals);
   41943         102 :     Py_XINCREF(code);
   41944         102 :     op->func_code = code;
   41945         102 :     op->defaults_pyobjects = 0;
   41946         102 :     op->defaults_size = 0;
   41947         102 :     op->defaults = NULL;
   41948         102 :     op->defaults_tuple = NULL;
   41949         102 :     op->defaults_kwdict = NULL;
   41950         102 :     op->defaults_getter = NULL;
   41951         102 :     op->func_annotations = NULL;
   41952         102 :     op->func_is_coroutine = NULL;
   41953             : #if CYTHON_METH_FASTCALL
   41954         102 :     switch (ml->ml_flags & (METH_VARARGS | METH_FASTCALL | METH_NOARGS | METH_O | METH_KEYWORDS | METH_METHOD)) {
   41955           0 :     case METH_NOARGS:
   41956           0 :         __Pyx_CyFunction_func_vectorcall(op) = __Pyx_CyFunction_Vectorcall_NOARGS;
   41957           0 :         break;
   41958           0 :     case METH_O:
   41959           0 :         __Pyx_CyFunction_func_vectorcall(op) = __Pyx_CyFunction_Vectorcall_O;
   41960           0 :         break;
   41961           0 :     case METH_METHOD | METH_FASTCALL | METH_KEYWORDS:
   41962           0 :         __Pyx_CyFunction_func_vectorcall(op) = __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS_METHOD;
   41963           0 :         break;
   41964           3 :     case METH_FASTCALL | METH_KEYWORDS:
   41965           3 :         __Pyx_CyFunction_func_vectorcall(op) = __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS;
   41966           3 :         break;
   41967          99 :     case METH_VARARGS | METH_KEYWORDS:
   41968          99 :         __Pyx_CyFunction_func_vectorcall(op) = NULL;
   41969          99 :         break;
   41970           0 :     default:
   41971           0 :         PyErr_SetString(PyExc_SystemError, "Bad call flags for CyFunction");
   41972           0 :         Py_DECREF(op);
   41973             :         return NULL;
   41974             :     }
   41975             : #endif
   41976             :     return (PyObject *) op;
   41977             : }
   41978             : static int
   41979           0 : __Pyx_CyFunction_clear(__pyx_CyFunctionObject *m)
   41980             : {
   41981           0 :     Py_CLEAR(m->func_closure);
   41982             : #if CYTHON_COMPILING_IN_LIMITED_API
   41983             :     Py_CLEAR(m->func);
   41984             : #else
   41985           0 :     Py_CLEAR(((PyCFunctionObject*)m)->m_module);
   41986             : #endif
   41987           0 :     Py_CLEAR(m->func_dict);
   41988           0 :     Py_CLEAR(m->func_name);
   41989           0 :     Py_CLEAR(m->func_qualname);
   41990           0 :     Py_CLEAR(m->func_doc);
   41991           0 :     Py_CLEAR(m->func_globals);
   41992           0 :     Py_CLEAR(m->func_code);
   41993             : #if !CYTHON_COMPILING_IN_LIMITED_API
   41994             : #if PY_VERSION_HEX < 0x030900B1
   41995             :     Py_CLEAR(__Pyx_CyFunction_GetClassObj(m));
   41996             : #else
   41997             :     {
   41998           0 :         PyObject *cls = (PyObject*) ((PyCMethodObject *) (m))->mm_class;
   41999           0 :         ((PyCMethodObject *) (m))->mm_class = NULL;
   42000           0 :         Py_XDECREF(cls);
   42001             :     }
   42002             : #endif
   42003             : #endif
   42004           0 :     Py_CLEAR(m->defaults_tuple);
   42005           0 :     Py_CLEAR(m->defaults_kwdict);
   42006           0 :     Py_CLEAR(m->func_annotations);
   42007           0 :     Py_CLEAR(m->func_is_coroutine);
   42008           0 :     if (m->defaults) {
   42009             :         PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m);
   42010             :         int i;
   42011           0 :         for (i = 0; i < m->defaults_pyobjects; i++)
   42012           0 :             Py_XDECREF(pydefaults[i]);
   42013           0 :         PyObject_Free(m->defaults);
   42014           0 :         m->defaults = NULL;
   42015             :     }
   42016           0 :     return 0;
   42017             : }
   42018           0 : static void __Pyx__CyFunction_dealloc(__pyx_CyFunctionObject *m)
   42019             : {
   42020           0 :     if (__Pyx_CyFunction_weakreflist(m) != NULL)
   42021           0 :         PyObject_ClearWeakRefs((PyObject *) m);
   42022           0 :     __Pyx_CyFunction_clear(m);
   42023           0 :     __Pyx_PyHeapTypeObject_GC_Del(m);
   42024           0 : }
   42025           0 : static void __Pyx_CyFunction_dealloc(__pyx_CyFunctionObject *m)
   42026             : {
   42027           0 :     PyObject_GC_UnTrack(m);
   42028           0 :     __Pyx__CyFunction_dealloc(m);
   42029           0 : }
   42030           0 : static int __Pyx_CyFunction_traverse(__pyx_CyFunctionObject *m, visitproc visit, void *arg)
   42031             : {
   42032           0 :     Py_VISIT(m->func_closure);
   42033             : #if CYTHON_COMPILING_IN_LIMITED_API
   42034             :     Py_VISIT(m->func);
   42035             : #else
   42036           0 :     Py_VISIT(((PyCFunctionObject*)m)->m_module);
   42037             : #endif
   42038           0 :     Py_VISIT(m->func_dict);
   42039           0 :     Py_VISIT(m->func_name);
   42040           0 :     Py_VISIT(m->func_qualname);
   42041           0 :     Py_VISIT(m->func_doc);
   42042           0 :     Py_VISIT(m->func_globals);
   42043           0 :     Py_VISIT(m->func_code);
   42044             : #if !CYTHON_COMPILING_IN_LIMITED_API
   42045           0 :     Py_VISIT(__Pyx_CyFunction_GetClassObj(m));
   42046             : #endif
   42047           0 :     Py_VISIT(m->defaults_tuple);
   42048           0 :     Py_VISIT(m->defaults_kwdict);
   42049           0 :     Py_VISIT(m->func_is_coroutine);
   42050           0 :     if (m->defaults) {
   42051             :         PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m);
   42052             :         int i;
   42053           0 :         for (i = 0; i < m->defaults_pyobjects; i++)
   42054           0 :             Py_VISIT(pydefaults[i]);
   42055             :     }
   42056             :     return 0;
   42057             : }
   42058             : static PyObject*
   42059           0 : __Pyx_CyFunction_repr(__pyx_CyFunctionObject *op)
   42060             : {
   42061             : #if PY_MAJOR_VERSION >= 3
   42062           0 :     return PyUnicode_FromFormat("<cyfunction %U at %p>",
   42063             :                                 op->func_qualname, (void *)op);
   42064             : #else
   42065             :     return PyString_FromFormat("<cyfunction %s at %p>",
   42066             :                                PyString_AsString(op->func_qualname), (void *)op);
   42067             : #endif
   42068             : }
   42069           0 : static PyObject * __Pyx_CyFunction_CallMethod(PyObject *func, PyObject *self, PyObject *arg, PyObject *kw) {
   42070             : #if CYTHON_COMPILING_IN_LIMITED_API
   42071             :     PyObject *f = ((__pyx_CyFunctionObject*)func)->func;
   42072             :     PyObject *py_name = NULL;
   42073             :     PyCFunction meth;
   42074             :     int flags;
   42075             :     meth = PyCFunction_GetFunction(f);
   42076             :     if (unlikely(!meth)) return NULL;
   42077             :     flags = PyCFunction_GetFlags(f);
   42078             :     if (unlikely(flags < 0)) return NULL;
   42079             : #else
   42080           0 :     PyCFunctionObject* f = (PyCFunctionObject*)func;
   42081           0 :     PyCFunction meth = f->m_ml->ml_meth;
   42082           0 :     int flags = f->m_ml->ml_flags;
   42083             : #endif
   42084           0 :     Py_ssize_t size;
   42085           0 :     switch (flags & (METH_VARARGS | METH_KEYWORDS | METH_NOARGS | METH_O)) {
   42086           0 :     case METH_VARARGS:
   42087           0 :         if (likely(kw == NULL || PyDict_Size(kw) == 0))
   42088           0 :             return (*meth)(self, arg);
   42089             :         break;
   42090           0 :     case METH_VARARGS | METH_KEYWORDS:
   42091           0 :         return (*(PyCFunctionWithKeywords)(void*)meth)(self, arg, kw);
   42092           0 :     case METH_NOARGS:
   42093           0 :         if (likely(kw == NULL || PyDict_Size(kw) == 0)) {
   42094             : #if CYTHON_ASSUME_SAFE_MACROS
   42095           0 :             size = PyTuple_GET_SIZE(arg);
   42096             : #else
   42097             :             size = PyTuple_Size(arg);
   42098             :             if (unlikely(size < 0)) return NULL;
   42099             : #endif
   42100           0 :             if (likely(size == 0))
   42101           0 :                 return (*meth)(self, NULL);
   42102             : #if CYTHON_COMPILING_IN_LIMITED_API
   42103             :             py_name = __Pyx_CyFunction_get_name((__pyx_CyFunctionObject*)func, NULL);
   42104             :             if (!py_name) return NULL;
   42105             :             PyErr_Format(PyExc_TypeError,
   42106             :                 "%.200S() takes no arguments (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42107             :                 py_name, size);
   42108             :             Py_DECREF(py_name);
   42109             : #else
   42110           0 :             PyErr_Format(PyExc_TypeError,
   42111             :                 "%.200s() takes no arguments (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42112           0 :                 f->m_ml->ml_name, size);
   42113             : #endif
   42114           0 :             return NULL;
   42115             :         }
   42116             :         break;
   42117           0 :     case METH_O:
   42118           0 :         if (likely(kw == NULL || PyDict_Size(kw) == 0)) {
   42119             : #if CYTHON_ASSUME_SAFE_MACROS
   42120           0 :             size = PyTuple_GET_SIZE(arg);
   42121             : #else
   42122             :             size = PyTuple_Size(arg);
   42123             :             if (unlikely(size < 0)) return NULL;
   42124             : #endif
   42125           0 :             if (likely(size == 1)) {
   42126           0 :                 PyObject *result, *arg0;
   42127             :                 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   42128           0 :                 arg0 = PyTuple_GET_ITEM(arg, 0);
   42129             :                 #else
   42130             :                 arg0 = __Pyx_PySequence_ITEM(arg, 0); if (unlikely(!arg0)) return NULL;
   42131             :                 #endif
   42132           0 :                 result = (*meth)(self, arg0);
   42133             :                 #if !(CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS)
   42134             :                 Py_DECREF(arg0);
   42135             :                 #endif
   42136           0 :                 return result;
   42137             :             }
   42138             : #if CYTHON_COMPILING_IN_LIMITED_API
   42139             :             py_name = __Pyx_CyFunction_get_name((__pyx_CyFunctionObject*)func, NULL);
   42140             :             if (!py_name) return NULL;
   42141             :             PyErr_Format(PyExc_TypeError,
   42142             :                 "%.200S() takes exactly one argument (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42143             :                 py_name, size);
   42144             :             Py_DECREF(py_name);
   42145             : #else
   42146           0 :             PyErr_Format(PyExc_TypeError,
   42147             :                 "%.200s() takes exactly one argument (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42148           0 :                 f->m_ml->ml_name, size);
   42149             : #endif
   42150           0 :             return NULL;
   42151             :         }
   42152             :         break;
   42153           0 :     default:
   42154           0 :         PyErr_SetString(PyExc_SystemError, "Bad call flags for CyFunction");
   42155           0 :         return NULL;
   42156             :     }
   42157             : #if CYTHON_COMPILING_IN_LIMITED_API
   42158             :     py_name = __Pyx_CyFunction_get_name((__pyx_CyFunctionObject*)func, NULL);
   42159             :     if (!py_name) return NULL;
   42160             :     PyErr_Format(PyExc_TypeError, "%.200S() takes no keyword arguments",
   42161             :                  py_name);
   42162             :     Py_DECREF(py_name);
   42163             : #else
   42164           0 :     PyErr_Format(PyExc_TypeError, "%.200s() takes no keyword arguments",
   42165           0 :                  f->m_ml->ml_name);
   42166             : #endif
   42167           0 :     return NULL;
   42168             : }
   42169           0 : static CYTHON_INLINE PyObject *__Pyx_CyFunction_Call(PyObject *func, PyObject *arg, PyObject *kw) {
   42170           0 :     PyObject *self, *result;
   42171             : #if CYTHON_COMPILING_IN_LIMITED_API
   42172             :     self = PyCFunction_GetSelf(((__pyx_CyFunctionObject*)func)->func);
   42173             :     if (unlikely(!self) && PyErr_Occurred()) return NULL;
   42174             : #else
   42175           0 :     self = ((PyCFunctionObject*)func)->m_self;
   42176             : #endif
   42177           0 :     result = __Pyx_CyFunction_CallMethod(func, self, arg, kw);
   42178           0 :     return result;
   42179             : }
   42180           0 : static PyObject *__Pyx_CyFunction_CallAsMethod(PyObject *func, PyObject *args, PyObject *kw) {
   42181           0 :     PyObject *result;
   42182           0 :     __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *) func;
   42183             : #if CYTHON_METH_FASTCALL
   42184           0 :      __pyx_vectorcallfunc vc = __Pyx_CyFunction_func_vectorcall(cyfunc);
   42185           0 :     if (vc) {
   42186             : #if CYTHON_ASSUME_SAFE_MACROS
   42187           0 :         return __Pyx_PyVectorcall_FastCallDict(func, vc, &PyTuple_GET_ITEM(args, 0), (size_t)PyTuple_GET_SIZE(args), kw);
   42188             : #else
   42189             :         (void) &__Pyx_PyVectorcall_FastCallDict;
   42190             :         return PyVectorcall_Call(func, args, kw);
   42191             : #endif
   42192             :     }
   42193             : #endif
   42194           0 :     if ((cyfunc->flags & __Pyx_CYFUNCTION_CCLASS) && !(cyfunc->flags & __Pyx_CYFUNCTION_STATICMETHOD)) {
   42195           0 :         Py_ssize_t argc;
   42196           0 :         PyObject *new_args;
   42197           0 :         PyObject *self;
   42198             : #if CYTHON_ASSUME_SAFE_MACROS
   42199           0 :         argc = PyTuple_GET_SIZE(args);
   42200             : #else
   42201             :         argc = PyTuple_Size(args);
   42202             :         if (unlikely(!argc) < 0) return NULL;
   42203             : #endif
   42204           0 :         new_args = PyTuple_GetSlice(args, 1, argc);
   42205           0 :         if (unlikely(!new_args))
   42206             :             return NULL;
   42207           0 :         self = PyTuple_GetItem(args, 0);
   42208           0 :         if (unlikely(!self)) {
   42209           0 :             Py_DECREF(new_args);
   42210             : #if PY_MAJOR_VERSION > 2
   42211           0 :             PyErr_Format(PyExc_TypeError,
   42212             :                          "unbound method %.200S() needs an argument",
   42213             :                          cyfunc->func_qualname);
   42214             : #else
   42215             :             PyErr_SetString(PyExc_TypeError,
   42216             :                             "unbound method needs an argument");
   42217             : #endif
   42218           0 :             return NULL;
   42219             :         }
   42220           0 :         result = __Pyx_CyFunction_CallMethod(func, self, new_args, kw);
   42221           0 :         Py_DECREF(new_args);
   42222             :     } else {
   42223           0 :         result = __Pyx_CyFunction_Call(func, args, kw);
   42224             :     }
   42225             :     return result;
   42226             : }
   42227             : #if CYTHON_METH_FASTCALL
   42228         119 : static CYTHON_INLINE int __Pyx_CyFunction_Vectorcall_CheckArgs(__pyx_CyFunctionObject *cyfunc, Py_ssize_t nargs, PyObject *kwnames)
   42229             : {
   42230         119 :     int ret = 0;
   42231         119 :     if ((cyfunc->flags & __Pyx_CYFUNCTION_CCLASS) && !(cyfunc->flags & __Pyx_CYFUNCTION_STATICMETHOD)) {
   42232           0 :         if (unlikely(nargs < 1)) {
   42233           0 :             PyErr_Format(PyExc_TypeError, "%.200s() needs an argument",
   42234           0 :                          ((PyCFunctionObject*)cyfunc)->m_ml->ml_name);
   42235           0 :             return -1;
   42236             :         }
   42237             :         ret = 1;
   42238             :     }
   42239         119 :     if (unlikely(kwnames) && unlikely(PyTuple_GET_SIZE(kwnames))) {
   42240           0 :         PyErr_Format(PyExc_TypeError,
   42241           0 :                      "%.200s() takes no keyword arguments", ((PyCFunctionObject*)cyfunc)->m_ml->ml_name);
   42242           0 :         return -1;
   42243             :     }
   42244             :     return ret;
   42245             : }
   42246           0 : static PyObject * __Pyx_CyFunction_Vectorcall_NOARGS(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames)
   42247             : {
   42248           0 :     __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *)func;
   42249           0 :     PyMethodDef* def = ((PyCFunctionObject*)cyfunc)->m_ml;
   42250             : #if CYTHON_BACKPORT_VECTORCALL
   42251             :     Py_ssize_t nargs = (Py_ssize_t)nargsf;
   42252             : #else
   42253           0 :     Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
   42254             : #endif
   42255           0 :     PyObject *self;
   42256           0 :     switch (__Pyx_CyFunction_Vectorcall_CheckArgs(cyfunc, nargs, kwnames)) {
   42257           0 :     case 1:
   42258           0 :         self = args[0];
   42259           0 :         args += 1;
   42260           0 :         nargs -= 1;
   42261           0 :         break;
   42262           0 :     case 0:
   42263           0 :         self = ((PyCFunctionObject*)cyfunc)->m_self;
   42264           0 :         break;
   42265             :     default:
   42266             :         return NULL;
   42267             :     }
   42268           0 :     if (unlikely(nargs != 0)) {
   42269           0 :         PyErr_Format(PyExc_TypeError,
   42270             :             "%.200s() takes no arguments (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42271             :             def->ml_name, nargs);
   42272           0 :         return NULL;
   42273             :     }
   42274           0 :     return def->ml_meth(self, NULL);
   42275             : }
   42276           0 : static PyObject * __Pyx_CyFunction_Vectorcall_O(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames)
   42277             : {
   42278           0 :     __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *)func;
   42279           0 :     PyMethodDef* def = ((PyCFunctionObject*)cyfunc)->m_ml;
   42280             : #if CYTHON_BACKPORT_VECTORCALL
   42281             :     Py_ssize_t nargs = (Py_ssize_t)nargsf;
   42282             : #else
   42283           0 :     Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
   42284             : #endif
   42285           0 :     PyObject *self;
   42286           0 :     switch (__Pyx_CyFunction_Vectorcall_CheckArgs(cyfunc, nargs, kwnames)) {
   42287           0 :     case 1:
   42288           0 :         self = args[0];
   42289           0 :         args += 1;
   42290           0 :         nargs -= 1;
   42291           0 :         break;
   42292           0 :     case 0:
   42293           0 :         self = ((PyCFunctionObject*)cyfunc)->m_self;
   42294           0 :         break;
   42295             :     default:
   42296             :         return NULL;
   42297             :     }
   42298           0 :     if (unlikely(nargs != 1)) {
   42299           0 :         PyErr_Format(PyExc_TypeError,
   42300             :             "%.200s() takes exactly one argument (%" CYTHON_FORMAT_SSIZE_T "d given)",
   42301             :             def->ml_name, nargs);
   42302           0 :         return NULL;
   42303             :     }
   42304           0 :     return def->ml_meth(self, args[0]);
   42305             : }
   42306         119 : static PyObject * __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames)
   42307             : {
   42308         119 :     __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *)func;
   42309         119 :     PyMethodDef* def = ((PyCFunctionObject*)cyfunc)->m_ml;
   42310             : #if CYTHON_BACKPORT_VECTORCALL
   42311             :     Py_ssize_t nargs = (Py_ssize_t)nargsf;
   42312             : #else
   42313         119 :     Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
   42314             : #endif
   42315         119 :     PyObject *self;
   42316         119 :     switch (__Pyx_CyFunction_Vectorcall_CheckArgs(cyfunc, nargs, NULL)) {
   42317           0 :     case 1:
   42318           0 :         self = args[0];
   42319           0 :         args += 1;
   42320           0 :         nargs -= 1;
   42321           0 :         break;
   42322         119 :     case 0:
   42323         119 :         self = ((PyCFunctionObject*)cyfunc)->m_self;
   42324         119 :         break;
   42325             :     default:
   42326             :         return NULL;
   42327             :     }
   42328         119 :     return ((__Pyx_PyCFunctionFastWithKeywords)(void(*)(void))def->ml_meth)(self, args, nargs, kwnames);
   42329             : }
   42330           0 : static PyObject * __Pyx_CyFunction_Vectorcall_FASTCALL_KEYWORDS_METHOD(PyObject *func, PyObject *const *args, size_t nargsf, PyObject *kwnames)
   42331             : {
   42332           0 :     __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *)func;
   42333           0 :     PyMethodDef* def = ((PyCFunctionObject*)cyfunc)->m_ml;
   42334           0 :     PyTypeObject *cls = (PyTypeObject *) __Pyx_CyFunction_GetClassObj(cyfunc);
   42335             : #if CYTHON_BACKPORT_VECTORCALL
   42336             :     Py_ssize_t nargs = (Py_ssize_t)nargsf;
   42337             : #else
   42338           0 :     Py_ssize_t nargs = PyVectorcall_NARGS(nargsf);
   42339             : #endif
   42340           0 :     PyObject *self;
   42341           0 :     switch (__Pyx_CyFunction_Vectorcall_CheckArgs(cyfunc, nargs, NULL)) {
   42342           0 :     case 1:
   42343           0 :         self = args[0];
   42344           0 :         args += 1;
   42345           0 :         nargs -= 1;
   42346           0 :         break;
   42347           0 :     case 0:
   42348           0 :         self = ((PyCFunctionObject*)cyfunc)->m_self;
   42349           0 :         break;
   42350             :     default:
   42351             :         return NULL;
   42352             :     }
   42353           0 :     return ((__Pyx_PyCMethod)(void(*)(void))def->ml_meth)(self, cls, args, (size_t)nargs, kwnames);
   42354             : }
   42355             : #endif
   42356             : #if CYTHON_USE_TYPE_SPECS
   42357             : static PyType_Slot __pyx_CyFunctionType_slots[] = {
   42358             :     {Py_tp_dealloc, (void *)__Pyx_CyFunction_dealloc},
   42359             :     {Py_tp_repr, (void *)__Pyx_CyFunction_repr},
   42360             :     {Py_tp_call, (void *)__Pyx_CyFunction_CallAsMethod},
   42361             :     {Py_tp_traverse, (void *)__Pyx_CyFunction_traverse},
   42362             :     {Py_tp_clear, (void *)__Pyx_CyFunction_clear},
   42363             :     {Py_tp_methods, (void *)__pyx_CyFunction_methods},
   42364             :     {Py_tp_members, (void *)__pyx_CyFunction_members},
   42365             :     {Py_tp_getset, (void *)__pyx_CyFunction_getsets},
   42366             :     {Py_tp_descr_get, (void *)__Pyx_PyMethod_New},
   42367             :     {0, 0},
   42368             : };
   42369             : static PyType_Spec __pyx_CyFunctionType_spec = {
   42370             :     __PYX_TYPE_MODULE_PREFIX "cython_function_or_method",
   42371             :     sizeof(__pyx_CyFunctionObject),
   42372             :     0,
   42373             : #ifdef Py_TPFLAGS_METHOD_DESCRIPTOR
   42374             :     Py_TPFLAGS_METHOD_DESCRIPTOR |
   42375             : #endif
   42376             : #if (defined(_Py_TPFLAGS_HAVE_VECTORCALL) && CYTHON_METH_FASTCALL)
   42377             :     _Py_TPFLAGS_HAVE_VECTORCALL |
   42378             : #endif
   42379             :     Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC | Py_TPFLAGS_BASETYPE,
   42380             :     __pyx_CyFunctionType_slots
   42381             : };
   42382             : #else
   42383             : static PyTypeObject __pyx_CyFunctionType_type = {
   42384             :     PyVarObject_HEAD_INIT(0, 0)
   42385             :     __PYX_TYPE_MODULE_PREFIX "cython_function_or_method",
   42386             :     sizeof(__pyx_CyFunctionObject),
   42387             :     0,
   42388             :     (destructor) __Pyx_CyFunction_dealloc,
   42389             : #if !CYTHON_METH_FASTCALL
   42390             :     0,
   42391             : #elif CYTHON_BACKPORT_VECTORCALL
   42392             :     (printfunc)offsetof(__pyx_CyFunctionObject, func_vectorcall),
   42393             : #else
   42394             :     offsetof(PyCFunctionObject, vectorcall),
   42395             : #endif
   42396             :     0,
   42397             :     0,
   42398             : #if PY_MAJOR_VERSION < 3
   42399             :     0,
   42400             : #else
   42401             :     0,
   42402             : #endif
   42403             :     (reprfunc) __Pyx_CyFunction_repr,
   42404             :     0,
   42405             :     0,
   42406             :     0,
   42407             :     0,
   42408             :     __Pyx_CyFunction_CallAsMethod,
   42409             :     0,
   42410             :     0,
   42411             :     0,
   42412             :     0,
   42413             : #ifdef Py_TPFLAGS_METHOD_DESCRIPTOR
   42414             :     Py_TPFLAGS_METHOD_DESCRIPTOR |
   42415             : #endif
   42416             : #if defined(_Py_TPFLAGS_HAVE_VECTORCALL) && CYTHON_METH_FASTCALL
   42417             :     _Py_TPFLAGS_HAVE_VECTORCALL |
   42418             : #endif
   42419             :     Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC | Py_TPFLAGS_BASETYPE,
   42420             :     0,
   42421             :     (traverseproc) __Pyx_CyFunction_traverse,
   42422             :     (inquiry) __Pyx_CyFunction_clear,
   42423             :     0,
   42424             : #if PY_VERSION_HEX < 0x030500A0
   42425             :     offsetof(__pyx_CyFunctionObject, func_weakreflist),
   42426             : #else
   42427             :     offsetof(PyCFunctionObject, m_weakreflist),
   42428             : #endif
   42429             :     0,
   42430             :     0,
   42431             :     __pyx_CyFunction_methods,
   42432             :     __pyx_CyFunction_members,
   42433             :     __pyx_CyFunction_getsets,
   42434             :     0,
   42435             :     0,
   42436             :     __Pyx_PyMethod_New,
   42437             :     0,
   42438             :     offsetof(__pyx_CyFunctionObject, func_dict),
   42439             :     0,
   42440             :     0,
   42441             :     0,
   42442             :     0,
   42443             :     0,
   42444             :     0,
   42445             :     0,
   42446             :     0,
   42447             :     0,
   42448             :     0,
   42449             :     0,
   42450             :     0,
   42451             : #if PY_VERSION_HEX >= 0x030400a1
   42452             :     0,
   42453             : #endif
   42454             : #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   42455             :     0,
   42456             : #endif
   42457             : #if __PYX_NEED_TP_PRINT_SLOT
   42458             :     0,
   42459             : #endif
   42460             : #if PY_VERSION_HEX >= 0x030C0000
   42461             :     0,
   42462             : #endif
   42463             : #if PY_VERSION_HEX >= 0x030d00A4
   42464             :     0,
   42465             : #endif
   42466             : #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   42467             :     0,
   42468             : #endif
   42469             : };
   42470             : #endif
   42471           3 : static int __pyx_CyFunction_init(PyObject *module) {
   42472             : #if CYTHON_USE_TYPE_SPECS
   42473             :     __pyx_CyFunctionType = __Pyx_FetchCommonTypeFromSpec(module, &__pyx_CyFunctionType_spec, NULL);
   42474             : #else
   42475           3 :     CYTHON_UNUSED_VAR(module);
   42476           3 :     __pyx_CyFunctionType = __Pyx_FetchCommonType(&__pyx_CyFunctionType_type);
   42477             : #endif
   42478           3 :     if (unlikely(__pyx_CyFunctionType == NULL)) {
   42479           0 :         return -1;
   42480             :     }
   42481             :     return 0;
   42482             : }
   42483           9 : static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *func, size_t size, int pyobjects) {
   42484           9 :     __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
   42485           9 :     m->defaults = PyObject_Malloc(size);
   42486           9 :     if (unlikely(!m->defaults))
   42487           0 :         return PyErr_NoMemory();
   42488           9 :     memset(m->defaults, 0, size);
   42489           9 :     m->defaults_pyobjects = pyobjects;
   42490           9 :     m->defaults_size = size;
   42491           9 :     return m->defaults;
   42492             : }
   42493          99 : static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *func, PyObject *tuple) {
   42494          99 :     __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
   42495          99 :     m->defaults_tuple = tuple;
   42496          99 :     Py_INCREF(tuple);
   42497             : }
   42498             : static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *func, PyObject *dict) {
   42499             :     __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
   42500             :     m->defaults_kwdict = dict;
   42501             :     Py_INCREF(dict);
   42502             : }
   42503             : static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *func, PyObject *dict) {
   42504             :     __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func;
   42505             :     m->func_annotations = dict;
   42506             :     Py_INCREF(dict);
   42507             : }
   42508             : 
   42509             : /* FusedFunction */
   42510             :   static PyObject *
   42511          99 : __pyx_FusedFunction_New(PyMethodDef *ml, int flags,
   42512             :                         PyObject *qualname, PyObject *closure,
   42513             :                         PyObject *module, PyObject *globals,
   42514             :                         PyObject *code)
   42515             : {
   42516          99 :     PyObject *op = __Pyx_CyFunction_Init(
   42517          99 :         PyObject_GC_New(__pyx_CyFunctionObject, __pyx_FusedFunctionType),
   42518             :         ml, flags, qualname, closure, module, globals, code
   42519             :     );
   42520          99 :     if (likely(op)) {
   42521          99 :         __pyx_FusedFunctionObject *fusedfunc = (__pyx_FusedFunctionObject *) op;
   42522          99 :         fusedfunc->__signatures__ = NULL;
   42523          99 :         fusedfunc->self = NULL;
   42524          99 :         PyObject_GC_Track(op);
   42525             :     }
   42526          99 :     return op;
   42527             : }
   42528             : static void
   42529           0 : __pyx_FusedFunction_dealloc(__pyx_FusedFunctionObject *self)
   42530             : {
   42531           0 :     PyObject_GC_UnTrack(self);
   42532           0 :     Py_CLEAR(self->self);
   42533           0 :     Py_CLEAR(self->__signatures__);
   42534           0 :     __Pyx__CyFunction_dealloc((__pyx_CyFunctionObject *) self);
   42535           0 : }
   42536             : static int
   42537           0 : __pyx_FusedFunction_traverse(__pyx_FusedFunctionObject *self,
   42538             :                              visitproc visit,
   42539             :                              void *arg)
   42540             : {
   42541           0 :     Py_VISIT(self->self);
   42542           0 :     Py_VISIT(self->__signatures__);
   42543           0 :     return __Pyx_CyFunction_traverse((__pyx_CyFunctionObject *) self, visit, arg);
   42544             : }
   42545             : static int
   42546           0 : __pyx_FusedFunction_clear(__pyx_FusedFunctionObject *self)
   42547             : {
   42548           0 :     Py_CLEAR(self->self);
   42549           0 :     Py_CLEAR(self->__signatures__);
   42550           0 :     return __Pyx_CyFunction_clear((__pyx_CyFunctionObject *) self);
   42551             : }
   42552             : static PyObject *
   42553           0 : __pyx_FusedFunction_descr_get(PyObject *self, PyObject *obj, PyObject *type)
   42554             : {
   42555           0 :     __pyx_FusedFunctionObject *func, *meth;
   42556           0 :     func = (__pyx_FusedFunctionObject *) self;
   42557           0 :     if (func->self || func->func.flags & __Pyx_CYFUNCTION_STATICMETHOD) {
   42558           0 :         Py_INCREF(self);
   42559           0 :         return self;
   42560             :     }
   42561           0 :     if (obj == Py_None)
   42562           0 :         obj = NULL;
   42563           0 :     if (func->func.flags & __Pyx_CYFUNCTION_CLASSMETHOD)
   42564           0 :         obj = type;
   42565           0 :     if (obj == NULL) {
   42566           0 :         Py_INCREF(self);
   42567           0 :         return self;
   42568             :     }
   42569           0 :     meth = (__pyx_FusedFunctionObject *) __pyx_FusedFunction_New(
   42570             :                     ((PyCFunctionObject *) func)->m_ml,
   42571             :                     ((__pyx_CyFunctionObject *) func)->flags,
   42572             :                     ((__pyx_CyFunctionObject *) func)->func_qualname,
   42573             :                     ((__pyx_CyFunctionObject *) func)->func_closure,
   42574             :                     ((PyCFunctionObject *) func)->m_module,
   42575             :                     ((__pyx_CyFunctionObject *) func)->func_globals,
   42576             :                     ((__pyx_CyFunctionObject *) func)->func_code);
   42577           0 :     if (unlikely(!meth))
   42578             :         return NULL;
   42579           0 :     if (func->func.defaults) {
   42580           0 :         PyObject **pydefaults;
   42581           0 :         int i;
   42582           0 :         if (unlikely(!__Pyx_CyFunction_InitDefaults(
   42583             :                 (PyObject*)meth,
   42584             :                 func->func.defaults_size,
   42585             :                 func->func.defaults_pyobjects))) {
   42586           0 :             Py_XDECREF((PyObject*)meth);
   42587           0 :             return NULL;
   42588             :         }
   42589           0 :         memcpy(meth->func.defaults, func->func.defaults, func->func.defaults_size);
   42590           0 :         pydefaults = __Pyx_CyFunction_Defaults(PyObject *, meth);
   42591           0 :         for (i = 0; i < meth->func.defaults_pyobjects; i++)
   42592           0 :             Py_XINCREF(pydefaults[i]);
   42593             :     }
   42594           0 :     __Pyx_CyFunction_SetClassObj(meth, __Pyx_CyFunction_GetClassObj(func));
   42595           0 :     Py_XINCREF(func->__signatures__);
   42596           0 :     meth->__signatures__ = func->__signatures__;
   42597           0 :     Py_XINCREF(func->func.defaults_tuple);
   42598           0 :     meth->func.defaults_tuple = func->func.defaults_tuple;
   42599           0 :     Py_XINCREF(obj);
   42600           0 :     meth->self = obj;
   42601           0 :     return (PyObject *) meth;
   42602             : }
   42603             : static PyObject *
   42604           0 : _obj_to_string(PyObject *obj)
   42605             : {
   42606           0 :     if (PyUnicode_CheckExact(obj))
   42607           0 :         return __Pyx_NewRef(obj);
   42608             : #if PY_MAJOR_VERSION == 2
   42609             :     else if (PyString_Check(obj))
   42610             :         return PyUnicode_FromEncodedObject(obj, NULL, "strict");
   42611             : #endif
   42612           0 :     else if (PyType_Check(obj))
   42613           0 :         return PyObject_GetAttr(obj, __pyx_n_s_name_2);
   42614             :     else
   42615           0 :         return PyObject_Unicode(obj);
   42616             : }
   42617             : static PyObject *
   42618           0 : __pyx_FusedFunction_getitem(__pyx_FusedFunctionObject *self, PyObject *idx)
   42619             : {
   42620           0 :     PyObject *signature = NULL;
   42621           0 :     PyObject *unbound_result_func;
   42622           0 :     PyObject *result_func = NULL;
   42623           0 :     if (unlikely(self->__signatures__ == NULL)) {
   42624           0 :         PyErr_SetString(PyExc_TypeError, "Function is not fused");
   42625           0 :         return NULL;
   42626             :     }
   42627           0 :     if (PyTuple_Check(idx)) {
   42628           0 :         Py_ssize_t n = PyTuple_GET_SIZE(idx);
   42629           0 :         PyObject *list = PyList_New(n);
   42630           0 :         int i;
   42631           0 :         if (unlikely(!list))
   42632             :             return NULL;
   42633           0 :         for (i = 0; i < n; i++) {
   42634           0 :             PyObject *string;
   42635             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   42636           0 :             PyObject *item = PyTuple_GET_ITEM(idx, i);
   42637             : #else
   42638             :             PyObject *item = PySequence_ITEM(idx, i);  if (unlikely(!item)) goto __pyx_err;
   42639             : #endif
   42640           0 :             string = _obj_to_string(item);
   42641             : #if !(CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS)
   42642             :             Py_DECREF(item);
   42643             : #endif
   42644           0 :             if (unlikely(!string)) goto __pyx_err;
   42645           0 :             PyList_SET_ITEM(list, i, string);
   42646             :         }
   42647           0 :         signature = PyUnicode_Join(__pyx_kp_u__13, list);
   42648           0 : __pyx_err:;
   42649           0 :         Py_DECREF(list);
   42650             :     } else {
   42651           0 :         signature = _obj_to_string(idx);
   42652             :     }
   42653           0 :     if (unlikely(!signature))
   42654             :         return NULL;
   42655           0 :     unbound_result_func = PyObject_GetItem(self->__signatures__, signature);
   42656           0 :     if (likely(unbound_result_func)) {
   42657           0 :         if (self->self) {
   42658           0 :             __pyx_FusedFunctionObject *unbound = (__pyx_FusedFunctionObject *) unbound_result_func;
   42659           0 :             __Pyx_CyFunction_SetClassObj(unbound, __Pyx_CyFunction_GetClassObj(self));
   42660           0 :             result_func = __pyx_FusedFunction_descr_get(unbound_result_func,
   42661             :                                                         self->self, self->self);
   42662             :         } else {
   42663           0 :             result_func = unbound_result_func;
   42664           0 :             Py_INCREF(result_func);
   42665             :         }
   42666             :     }
   42667           0 :     Py_DECREF(signature);
   42668           0 :     Py_XDECREF(unbound_result_func);
   42669           0 :     return result_func;
   42670             : }
   42671             : static PyObject *
   42672           0 : __pyx_FusedFunction_callfunction(PyObject *func, PyObject *args, PyObject *kw)
   42673             : {
   42674           0 :      __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *) func;
   42675           0 :     int static_specialized = (cyfunc->flags & __Pyx_CYFUNCTION_STATICMETHOD &&
   42676           0 :                               !((__pyx_FusedFunctionObject *) func)->__signatures__);
   42677           0 :     if ((cyfunc->flags & __Pyx_CYFUNCTION_CCLASS) && !static_specialized) {
   42678           0 :         return __Pyx_CyFunction_CallAsMethod(func, args, kw);
   42679             :     } else {
   42680           0 :         return __Pyx_CyFunction_Call(func, args, kw);
   42681             :     }
   42682             : }
   42683             : static PyObject *
   42684           0 : __pyx_FusedFunction_call(PyObject *func, PyObject *args, PyObject *kw)
   42685             : {
   42686           0 :     __pyx_FusedFunctionObject *binding_func = (__pyx_FusedFunctionObject *) func;
   42687           0 :     Py_ssize_t argc = PyTuple_GET_SIZE(args);
   42688           0 :     PyObject *new_args = NULL;
   42689           0 :     __pyx_FusedFunctionObject *new_func = NULL;
   42690           0 :     PyObject *result = NULL;
   42691           0 :     int is_staticmethod = binding_func->func.flags & __Pyx_CYFUNCTION_STATICMETHOD;
   42692           0 :     if (binding_func->self) {
   42693           0 :         PyObject *self;
   42694           0 :         Py_ssize_t i;
   42695           0 :         new_args = PyTuple_New(argc + 1);
   42696           0 :         if (unlikely(!new_args))
   42697             :             return NULL;
   42698           0 :         self = binding_func->self;
   42699           0 :         Py_INCREF(self);
   42700           0 :         PyTuple_SET_ITEM(new_args, 0, self);
   42701           0 :         self = NULL;
   42702           0 :         for (i = 0; i < argc; i++) {
   42703             : #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
   42704           0 :             PyObject *item = PyTuple_GET_ITEM(args, i);
   42705           0 :             Py_INCREF(item);
   42706             : #else
   42707             :             PyObject *item = PySequence_ITEM(args, i);  if (unlikely(!item)) goto bad;
   42708             : #endif
   42709           0 :             PyTuple_SET_ITEM(new_args, i + 1, item);
   42710             :         }
   42711             :         args = new_args;
   42712             :     }
   42713           0 :     if (binding_func->__signatures__) {
   42714           0 :         PyObject *tup;
   42715           0 :         if (is_staticmethod && binding_func->func.flags & __Pyx_CYFUNCTION_CCLASS) {
   42716           0 :             tup = PyTuple_Pack(3, args,
   42717             :                                kw == NULL ? Py_None : kw,
   42718             :                                binding_func->func.defaults_tuple);
   42719           0 :             if (unlikely(!tup)) goto bad;
   42720           0 :             new_func = (__pyx_FusedFunctionObject *) __Pyx_CyFunction_CallMethod(
   42721             :                 func, binding_func->__signatures__, tup, NULL);
   42722             :         } else {
   42723           0 :             tup = PyTuple_Pack(4, binding_func->__signatures__, args,
   42724             :                                kw == NULL ? Py_None : kw,
   42725             :                                binding_func->func.defaults_tuple);
   42726           0 :             if (unlikely(!tup)) goto bad;
   42727           0 :             new_func = (__pyx_FusedFunctionObject *) __pyx_FusedFunction_callfunction(func, tup, NULL);
   42728             :         }
   42729           0 :         Py_DECREF(tup);
   42730           0 :         if (unlikely(!new_func))
   42731           0 :             goto bad;
   42732           0 :         __Pyx_CyFunction_SetClassObj(new_func, __Pyx_CyFunction_GetClassObj(binding_func));
   42733           0 :         func = (PyObject *) new_func;
   42734             :     }
   42735           0 :     result = __pyx_FusedFunction_callfunction(func, args, kw);
   42736           0 : bad:
   42737           0 :     Py_XDECREF(new_args);
   42738           0 :     Py_XDECREF((PyObject *) new_func);
   42739           0 :     return result;
   42740             : }
   42741             : static PyMemberDef __pyx_FusedFunction_members[] = {
   42742             :     {(char *) "__signatures__",
   42743             :      T_OBJECT,
   42744             :      offsetof(__pyx_FusedFunctionObject, __signatures__),
   42745             :      READONLY,
   42746             :      0},
   42747             :     {(char *) "__self__", T_OBJECT_EX, offsetof(__pyx_FusedFunctionObject, self), READONLY, 0},
   42748             :     {0, 0, 0, 0, 0},
   42749             : };
   42750             : static PyGetSetDef __pyx_FusedFunction_getsets[] = {
   42751             :     {(char *) "__doc__",  (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0},
   42752             :     {0, 0, 0, 0, 0}
   42753             : };
   42754             : #if CYTHON_USE_TYPE_SPECS
   42755             : static PyType_Slot __pyx_FusedFunctionType_slots[] = {
   42756             :     {Py_tp_dealloc, (void *)__pyx_FusedFunction_dealloc},
   42757             :     {Py_tp_call, (void *)__pyx_FusedFunction_call},
   42758             :     {Py_tp_traverse, (void *)__pyx_FusedFunction_traverse},
   42759             :     {Py_tp_clear, (void *)__pyx_FusedFunction_clear},
   42760             :     {Py_tp_members, (void *)__pyx_FusedFunction_members},
   42761             :     {Py_tp_getset, (void *)__pyx_FusedFunction_getsets},
   42762             :     {Py_tp_descr_get, (void *)__pyx_FusedFunction_descr_get},
   42763             :     {Py_mp_subscript, (void *)__pyx_FusedFunction_getitem},
   42764             :     {0, 0},
   42765             : };
   42766             : static PyType_Spec __pyx_FusedFunctionType_spec = {
   42767             :     __PYX_TYPE_MODULE_PREFIX "fused_cython_function",
   42768             :     sizeof(__pyx_FusedFunctionObject),
   42769             :     0,
   42770             :     Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC | Py_TPFLAGS_BASETYPE,
   42771             :     __pyx_FusedFunctionType_slots
   42772             : };
   42773             : #else
   42774             : static PyMappingMethods __pyx_FusedFunction_mapping_methods = {
   42775             :     0,
   42776             :     (binaryfunc) __pyx_FusedFunction_getitem,
   42777             :     0,
   42778             : };
   42779             : static PyTypeObject __pyx_FusedFunctionType_type = {
   42780             :     PyVarObject_HEAD_INIT(0, 0)
   42781             :     __PYX_TYPE_MODULE_PREFIX "fused_cython_function",
   42782             :     sizeof(__pyx_FusedFunctionObject),
   42783             :     0,
   42784             :     (destructor) __pyx_FusedFunction_dealloc,
   42785             :     0,
   42786             :     0,
   42787             :     0,
   42788             : #if PY_MAJOR_VERSION < 3
   42789             :     0,
   42790             : #else
   42791             :     0,
   42792             : #endif
   42793             :     0,
   42794             :     0,
   42795             :     0,
   42796             :     &__pyx_FusedFunction_mapping_methods,
   42797             :     0,
   42798             :     (ternaryfunc) __pyx_FusedFunction_call,
   42799             :     0,
   42800             :     0,
   42801             :     0,
   42802             :     0,
   42803             :     Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC | Py_TPFLAGS_BASETYPE,
   42804             :     0,
   42805             :     (traverseproc) __pyx_FusedFunction_traverse,
   42806             :     (inquiry) __pyx_FusedFunction_clear,
   42807             :     0,
   42808             :     0,
   42809             :     0,
   42810             :     0,
   42811             :     0,
   42812             :     __pyx_FusedFunction_members,
   42813             :     __pyx_FusedFunction_getsets,
   42814             :     &__pyx_CyFunctionType_type,
   42815             :     0,
   42816             :     __pyx_FusedFunction_descr_get,
   42817             :     0,
   42818             :     0,
   42819             :     0,
   42820             :     0,
   42821             :     0,
   42822             :     0,
   42823             :     0,
   42824             :     0,
   42825             :     0,
   42826             :     0,
   42827             :     0,
   42828             :     0,
   42829             :     0,
   42830             :     0,
   42831             : #if PY_VERSION_HEX >= 0x030400a1
   42832             :     0,
   42833             : #endif
   42834             : #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
   42835             :     0,
   42836             : #endif
   42837             : #if __PYX_NEED_TP_PRINT_SLOT
   42838             :     0,
   42839             : #endif
   42840             : #if PY_VERSION_HEX >= 0x030C0000
   42841             :     0,
   42842             : #endif
   42843             : #if PY_VERSION_HEX >= 0x030d00A4
   42844             :     0,
   42845             : #endif
   42846             : #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000 && PY_VERSION_HEX < 0x030a0000
   42847             :     0,
   42848             : #endif
   42849             : };
   42850             : #endif
   42851           3 : static int __pyx_FusedFunction_init(PyObject *module) {
   42852             : #if CYTHON_USE_TYPE_SPECS
   42853             :     PyObject *bases = PyTuple_Pack(1, __pyx_CyFunctionType);
   42854             :     if (unlikely(!bases)) {
   42855             :         return -1;
   42856             :     }
   42857             :     __pyx_FusedFunctionType = __Pyx_FetchCommonTypeFromSpec(module, &__pyx_FusedFunctionType_spec, bases);
   42858             :     Py_DECREF(bases);
   42859             : #else
   42860           3 :     CYTHON_UNUSED_VAR(module);
   42861           3 :     __pyx_FusedFunctionType_type.tp_base = __pyx_CyFunctionType;
   42862           3 :     __pyx_FusedFunctionType = __Pyx_FetchCommonType(&__pyx_FusedFunctionType_type);
   42863             : #endif
   42864           3 :     if (unlikely(__pyx_FusedFunctionType == NULL)) {
   42865           0 :         return -1;
   42866             :     }
   42867             :     return 0;
   42868             : }
   42869             : 
   42870             : /* CythonFunction */
   42871           3 :   static PyObject *__Pyx_CyFunction_New(PyMethodDef *ml, int flags, PyObject* qualname,
   42872             :                                       PyObject *closure, PyObject *module, PyObject* globals, PyObject* code) {
   42873           3 :     PyObject *op = __Pyx_CyFunction_Init(
   42874           3 :         PyObject_GC_New(__pyx_CyFunctionObject, __pyx_CyFunctionType),
   42875             :         ml, flags, qualname, closure, module, globals, code
   42876             :     );
   42877           3 :     if (likely(op)) {
   42878           3 :         PyObject_GC_Track(op);
   42879             :     }
   42880           3 :     return op;
   42881             : }
   42882             : 
   42883             : /* CLineInTraceback */
   42884             :   #ifndef CYTHON_CLINE_IN_TRACEBACK
   42885           0 : static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line) {
   42886           0 :     PyObject *use_cline;
   42887           0 :     PyObject *ptype, *pvalue, *ptraceback;
   42888             : #if CYTHON_COMPILING_IN_CPYTHON
   42889           0 :     PyObject **cython_runtime_dict;
   42890             : #endif
   42891           0 :     CYTHON_MAYBE_UNUSED_VAR(tstate);
   42892           0 :     if (unlikely(!__pyx_cython_runtime)) {
   42893             :         return c_line;
   42894             :     }
   42895           0 :     __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
   42896             : #if CYTHON_COMPILING_IN_CPYTHON
   42897           0 :     cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
   42898           0 :     if (likely(cython_runtime_dict)) {
   42899           0 :         __PYX_PY_DICT_LOOKUP_IF_MODIFIED(
   42900             :             use_cline, *cython_runtime_dict,
   42901             :             __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback))
   42902             :     } else
   42903             : #endif
   42904             :     {
   42905           0 :       PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStrNoError(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
   42906           0 :       if (use_cline_obj) {
   42907           0 :         use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
   42908           0 :         Py_DECREF(use_cline_obj);
   42909             :       } else {
   42910           0 :         PyErr_Clear();
   42911           0 :         use_cline = NULL;
   42912             :       }
   42913             :     }
   42914           0 :     if (!use_cline) {
   42915           0 :         c_line = 0;
   42916           0 :         (void) PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
   42917             :     }
   42918           0 :     else if (use_cline == Py_False || (use_cline != Py_True && PyObject_Not(use_cline) != 0)) {
   42919             :         c_line = 0;
   42920             :     }
   42921           0 :     __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
   42922           0 :     return c_line;
   42923             : }
   42924             : #endif
   42925             : 
   42926             : /* CodeObjectCache */
   42927             :   #if !CYTHON_COMPILING_IN_LIMITED_API
   42928           0 : static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
   42929           0 :     int start = 0, mid = 0, end = count - 1;
   42930           0 :     if (end >= 0 && code_line > entries[end].code_line) {
   42931             :         return count;
   42932             :     }
   42933           0 :     while (start < end) {
   42934           0 :         mid = start + (end - start) / 2;
   42935           0 :         if (code_line < entries[mid].code_line) {
   42936             :             end = mid;
   42937           0 :         } else if (code_line > entries[mid].code_line) {
   42938           0 :              start = mid + 1;
   42939             :         } else {
   42940           0 :             return mid;
   42941             :         }
   42942             :     }
   42943           0 :     if (code_line <= entries[mid].code_line) {
   42944             :         return mid;
   42945             :     } else {
   42946           0 :         return mid + 1;
   42947             :     }
   42948             : }
   42949           0 : static PyCodeObject *__pyx_find_code_object(int code_line) {
   42950           0 :     PyCodeObject* code_object;
   42951           0 :     int pos;
   42952           0 :     if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
   42953             :         return NULL;
   42954             :     }
   42955           0 :     pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
   42956           0 :     if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
   42957             :         return NULL;
   42958             :     }
   42959           0 :     code_object = __pyx_code_cache.entries[pos].code_object;
   42960           0 :     Py_INCREF(code_object);
   42961             :     return code_object;
   42962             : }
   42963           0 : static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
   42964           0 :     int pos, i;
   42965           0 :     __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
   42966           0 :     if (unlikely(!code_line)) {
   42967             :         return;
   42968             :     }
   42969           0 :     if (unlikely(!entries)) {
   42970           0 :         entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
   42971           0 :         if (likely(entries)) {
   42972           0 :             __pyx_code_cache.entries = entries;
   42973           0 :             __pyx_code_cache.max_count = 64;
   42974           0 :             __pyx_code_cache.count = 1;
   42975           0 :             entries[0].code_line = code_line;
   42976           0 :             entries[0].code_object = code_object;
   42977           0 :             Py_INCREF(code_object);
   42978             :         }
   42979           0 :         return;
   42980             :     }
   42981           0 :     pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
   42982           0 :     if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
   42983           0 :         PyCodeObject* tmp = entries[pos].code_object;
   42984           0 :         entries[pos].code_object = code_object;
   42985           0 :         Py_DECREF(tmp);
   42986           0 :         return;
   42987             :     }
   42988           0 :     if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
   42989           0 :         int new_max = __pyx_code_cache.max_count + 64;
   42990           0 :         entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
   42991           0 :             __pyx_code_cache.entries, ((size_t)new_max) * sizeof(__Pyx_CodeObjectCacheEntry));
   42992           0 :         if (unlikely(!entries)) {
   42993             :             return;
   42994             :         }
   42995           0 :         __pyx_code_cache.entries = entries;
   42996           0 :         __pyx_code_cache.max_count = new_max;
   42997             :     }
   42998           0 :     for (i=__pyx_code_cache.count; i>pos; i--) {
   42999           0 :         entries[i] = entries[i-1];
   43000             :     }
   43001           0 :     entries[pos].code_line = code_line;
   43002           0 :     entries[pos].code_object = code_object;
   43003           0 :     __pyx_code_cache.count++;
   43004           0 :     Py_INCREF(code_object);
   43005             : }
   43006             : #endif
   43007             : 
   43008             : /* AddTraceback */
   43009             :   #include "compile.h"
   43010             : #include "frameobject.h"
   43011             : #include "traceback.h"
   43012             : #if PY_VERSION_HEX >= 0x030b00a6 && !CYTHON_COMPILING_IN_LIMITED_API
   43013             :   #ifndef Py_BUILD_CORE
   43014             :     #define Py_BUILD_CORE 1
   43015             :   #endif
   43016             :   #include "internal/pycore_frame.h"
   43017             : #endif
   43018             : #if CYTHON_COMPILING_IN_LIMITED_API
   43019             : static PyObject *__Pyx_PyCode_Replace_For_AddTraceback(PyObject *code, PyObject *scratch_dict,
   43020             :                                                        PyObject *firstlineno, PyObject *name) {
   43021             :     PyObject *replace = NULL;
   43022             :     if (unlikely(PyDict_SetItemString(scratch_dict, "co_firstlineno", firstlineno))) return NULL;
   43023             :     if (unlikely(PyDict_SetItemString(scratch_dict, "co_name", name))) return NULL;
   43024             :     replace = PyObject_GetAttrString(code, "replace");
   43025             :     if (likely(replace)) {
   43026             :         PyObject *result;
   43027             :         result = PyObject_Call(replace, __pyx_empty_tuple, scratch_dict);
   43028             :         Py_DECREF(replace);
   43029             :         return result;
   43030             :     }
   43031             :     PyErr_Clear();
   43032             :     #if __PYX_LIMITED_VERSION_HEX < 0x030780000
   43033             :     {
   43034             :         PyObject *compiled = NULL, *result = NULL;
   43035             :         if (unlikely(PyDict_SetItemString(scratch_dict, "code", code))) return NULL;
   43036             :         if (unlikely(PyDict_SetItemString(scratch_dict, "type", (PyObject*)(&PyType_Type)))) return NULL;
   43037             :         compiled = Py_CompileString(
   43038             :             "out = type(code)(\n"
   43039             :             "  code.co_argcount, code.co_kwonlyargcount, code.co_nlocals, code.co_stacksize,\n"
   43040             :             "  code.co_flags, code.co_code, code.co_consts, code.co_names,\n"
   43041             :             "  code.co_varnames, code.co_filename, co_name, co_firstlineno,\n"
   43042             :             "  code.co_lnotab)\n", "<dummy>", Py_file_input);
   43043             :         if (!compiled) return NULL;
   43044             :         result = PyEval_EvalCode(compiled, scratch_dict, scratch_dict);
   43045             :         Py_DECREF(compiled);
   43046             :         if (!result) PyErr_Print();
   43047             :         Py_DECREF(result);
   43048             :         result = PyDict_GetItemString(scratch_dict, "out");
   43049             :         if (result) Py_INCREF(result);
   43050             :         return result;
   43051             :     }
   43052             :     #else
   43053             :     return NULL;
   43054             :     #endif
   43055             : }
   43056             : static void __Pyx_AddTraceback(const char *funcname, int c_line,
   43057             :                                int py_line, const char *filename) {
   43058             :     PyObject *code_object = NULL, *py_py_line = NULL, *py_funcname = NULL, *dict = NULL;
   43059             :     PyObject *replace = NULL, *getframe = NULL, *frame = NULL;
   43060             :     PyObject *exc_type, *exc_value, *exc_traceback;
   43061             :     int success = 0;
   43062             :     if (c_line) {
   43063             :         (void) __pyx_cfilenm;
   43064             :         (void) __Pyx_CLineForTraceback(__Pyx_PyThreadState_Current, c_line);
   43065             :     }
   43066             :     PyErr_Fetch(&exc_type, &exc_value, &exc_traceback);
   43067             :     code_object = Py_CompileString("_getframe()", filename, Py_eval_input);
   43068             :     if (unlikely(!code_object)) goto bad;
   43069             :     py_py_line = PyLong_FromLong(py_line);
   43070             :     if (unlikely(!py_py_line)) goto bad;
   43071             :     py_funcname = PyUnicode_FromString(funcname);
   43072             :     if (unlikely(!py_funcname)) goto bad;
   43073             :     dict = PyDict_New();
   43074             :     if (unlikely(!dict)) goto bad;
   43075             :     {
   43076             :         PyObject *old_code_object = code_object;
   43077             :         code_object = __Pyx_PyCode_Replace_For_AddTraceback(code_object, dict, py_py_line, py_funcname);
   43078             :         Py_DECREF(old_code_object);
   43079             :     }
   43080             :     if (unlikely(!code_object)) goto bad;
   43081             :     getframe = PySys_GetObject("_getframe");
   43082             :     if (unlikely(!getframe)) goto bad;
   43083             :     if (unlikely(PyDict_SetItemString(dict, "_getframe", getframe))) goto bad;
   43084             :     frame = PyEval_EvalCode(code_object, dict, dict);
   43085             :     if (unlikely(!frame) || frame == Py_None) goto bad;
   43086             :     success = 1;
   43087             :   bad:
   43088             :     PyErr_Restore(exc_type, exc_value, exc_traceback);
   43089             :     Py_XDECREF(code_object);
   43090             :     Py_XDECREF(py_py_line);
   43091             :     Py_XDECREF(py_funcname);
   43092             :     Py_XDECREF(dict);
   43093             :     Py_XDECREF(replace);
   43094             :     if (success) {
   43095             :         PyTraceBack_Here(
   43096             :             (struct _frame*)frame);
   43097             :     }
   43098             :     Py_XDECREF(frame);
   43099             : }
   43100             : #else
   43101           0 : static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
   43102             :             const char *funcname, int c_line,
   43103             :             int py_line, const char *filename) {
   43104           0 :     PyCodeObject *py_code = NULL;
   43105           0 :     PyObject *py_funcname = NULL;
   43106             :     #if PY_MAJOR_VERSION < 3
   43107             :     PyObject *py_srcfile = NULL;
   43108             :     py_srcfile = PyString_FromString(filename);
   43109             :     if (!py_srcfile) goto bad;
   43110             :     #endif
   43111           0 :     if (c_line) {
   43112             :         #if PY_MAJOR_VERSION < 3
   43113             :         py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
   43114             :         if (!py_funcname) goto bad;
   43115             :         #else
   43116           0 :         py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
   43117           0 :         if (!py_funcname) goto bad;
   43118           0 :         funcname = PyUnicode_AsUTF8(py_funcname);
   43119           0 :         if (!funcname) goto bad;
   43120             :         #endif
   43121             :     }
   43122             :     else {
   43123             :         #if PY_MAJOR_VERSION < 3
   43124             :         py_funcname = PyString_FromString(funcname);
   43125             :         if (!py_funcname) goto bad;
   43126             :         #endif
   43127           0 :     }
   43128             :     #if PY_MAJOR_VERSION < 3
   43129             :     py_code = __Pyx_PyCode_New(
   43130             :         0,
   43131             :         0,
   43132             :         0,
   43133             :         0,
   43134             :         0,
   43135             :         0,
   43136             :         __pyx_empty_bytes, /*PyObject *code,*/
   43137             :         __pyx_empty_tuple, /*PyObject *consts,*/
   43138             :         __pyx_empty_tuple, /*PyObject *names,*/
   43139             :         __pyx_empty_tuple, /*PyObject *varnames,*/
   43140             :         __pyx_empty_tuple, /*PyObject *freevars,*/
   43141             :         __pyx_empty_tuple, /*PyObject *cellvars,*/
   43142             :         py_srcfile,   /*PyObject *filename,*/
   43143             :         py_funcname,  /*PyObject *name,*/
   43144             :         py_line,
   43145             :         __pyx_empty_bytes  /*PyObject *lnotab*/
   43146             :     );
   43147             :     Py_DECREF(py_srcfile);
   43148             :     #else
   43149           0 :     py_code = PyCode_NewEmpty(filename, funcname, py_line);
   43150             :     #endif
   43151           0 :     Py_XDECREF(py_funcname);
   43152           0 :     return py_code;
   43153           0 : bad:
   43154           0 :     Py_XDECREF(py_funcname);
   43155             :     #if PY_MAJOR_VERSION < 3
   43156             :     Py_XDECREF(py_srcfile);
   43157             :     #endif
   43158           0 :     return NULL;
   43159             : }
   43160           0 : static void __Pyx_AddTraceback(const char *funcname, int c_line,
   43161             :                                int py_line, const char *filename) {
   43162           0 :     PyCodeObject *py_code = 0;
   43163           0 :     PyFrameObject *py_frame = 0;
   43164           0 :     PyThreadState *tstate = __Pyx_PyThreadState_Current;
   43165           0 :     PyObject *ptype, *pvalue, *ptraceback;
   43166           0 :     if (c_line) {
   43167           0 :         c_line = __Pyx_CLineForTraceback(tstate, c_line);
   43168             :     }
   43169           0 :     py_code = __pyx_find_code_object(c_line ? -c_line : py_line);
   43170           0 :     if (!py_code) {
   43171           0 :         __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
   43172           0 :         py_code = __Pyx_CreateCodeObjectForTraceback(
   43173             :             funcname, c_line, py_line, filename);
   43174           0 :         if (!py_code) {
   43175             :             /* If the code object creation fails, then we should clear the
   43176             :                fetched exception references and propagate the new exception */
   43177           0 :             Py_XDECREF(ptype);
   43178           0 :             Py_XDECREF(pvalue);
   43179           0 :             Py_XDECREF(ptraceback);
   43180           0 :             goto bad;
   43181             :         }
   43182           0 :         __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
   43183           0 :         __pyx_insert_code_object(c_line ? -c_line : py_line, py_code);
   43184             :     }
   43185           0 :     py_frame = PyFrame_New(
   43186             :         tstate,            /*PyThreadState *tstate,*/
   43187             :         py_code,           /*PyCodeObject *code,*/
   43188           0 :         __pyx_d,    /*PyObject *globals,*/
   43189             :         0                  /*PyObject *locals*/
   43190             :     );
   43191           0 :     if (!py_frame) goto bad;
   43192           0 :     __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
   43193           0 :     PyTraceBack_Here(py_frame);
   43194           0 : bad:
   43195           0 :     Py_XDECREF(py_code);
   43196           0 :     Py_XDECREF(py_frame);
   43197           0 : }
   43198             : #endif
   43199             : 
   43200             : #if PY_MAJOR_VERSION < 3
   43201             : static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view, int flags) {
   43202             :     __Pyx_TypeName obj_type_name;
   43203             :     if (PyObject_CheckBuffer(obj)) return PyObject_GetBuffer(obj, view, flags);
   43204             :         if (__Pyx_TypeCheck(obj, __pyx_array_type)) return __pyx_array_getbuffer(obj, view, flags);
   43205             :         if (__Pyx_TypeCheck(obj, __pyx_memoryview_type)) return __pyx_memoryview_getbuffer(obj, view, flags);
   43206             :     obj_type_name = __Pyx_PyType_GetName(Py_TYPE(obj));
   43207             :     PyErr_Format(PyExc_TypeError,
   43208             :                  "'" __Pyx_FMT_TYPENAME "' does not have the buffer interface",
   43209             :                  obj_type_name);
   43210             :     __Pyx_DECREF_TypeName(obj_type_name);
   43211             :     return -1;
   43212             : }
   43213             : static void __Pyx_ReleaseBuffer(Py_buffer *view) {
   43214             :     PyObject *obj = view->obj;
   43215             :     if (!obj) return;
   43216             :     if (PyObject_CheckBuffer(obj)) {
   43217             :         PyBuffer_Release(view);
   43218             :         return;
   43219             :     }
   43220             :     if ((0)) {}
   43221             :     view->obj = NULL;
   43222             :     Py_DECREF(obj);
   43223             : }
   43224             : #endif
   43225             : 
   43226             : 
   43227             :   /* MemviewSliceIsContig */
   43228             :   static int
   43229           0 : __pyx_memviewslice_is_contig(const __Pyx_memviewslice mvs, char order, int ndim)
   43230             : {
   43231           0 :     int i, index, step, start;
   43232           0 :     Py_ssize_t itemsize = mvs.memview->view.itemsize;
   43233           0 :     if (order == 'F') {
   43234             :         step = 1;
   43235             :         start = 0;
   43236             :     } else {
   43237           0 :         step = -1;
   43238           0 :         start = ndim - 1;
   43239             :     }
   43240           0 :     for (i = 0; i < ndim; i++) {
   43241           0 :         index = start + step * i;
   43242           0 :         if (mvs.suboffsets[index] >= 0 || mvs.strides[index] != itemsize)
   43243             :             return 0;
   43244           0 :         itemsize *= mvs.shape[index];
   43245             :     }
   43246             :     return 1;
   43247             : }
   43248             : 
   43249             : /* OverlappingSlices */
   43250             :   static void
   43251           0 : __pyx_get_array_memory_extents(__Pyx_memviewslice *slice,
   43252             :                                void **out_start, void **out_end,
   43253             :                                int ndim, size_t itemsize)
   43254             : {
   43255           0 :     char *start, *end;
   43256           0 :     int i;
   43257           0 :     start = end = slice->data;
   43258           0 :     for (i = 0; i < ndim; i++) {
   43259           0 :         Py_ssize_t stride = slice->strides[i];
   43260           0 :         Py_ssize_t extent = slice->shape[i];
   43261           0 :         if (extent == 0) {
   43262           0 :             *out_start = *out_end = start;
   43263           0 :             return;
   43264             :         } else {
   43265           0 :             if (stride > 0)
   43266           0 :                 end += stride * (extent - 1);
   43267             :             else
   43268           0 :                 start += stride * (extent - 1);
   43269             :         }
   43270             :     }
   43271           0 :     *out_start = start;
   43272           0 :     *out_end = end + itemsize;
   43273             : }
   43274             : static int
   43275           0 : __pyx_slices_overlap(__Pyx_memviewslice *slice1,
   43276             :                      __Pyx_memviewslice *slice2,
   43277             :                      int ndim, size_t itemsize)
   43278             : {
   43279           0 :     void *start1, *end1, *start2, *end2;
   43280           0 :     __pyx_get_array_memory_extents(slice1, &start1, &end1, ndim, itemsize);
   43281           0 :     __pyx_get_array_memory_extents(slice2, &start2, &end2, ndim, itemsize);
   43282           0 :     return (start1 < end2) && (start2 < end1);
   43283             : }
   43284             : 
   43285             : /* TypeInfoCompare */
   43286             :   static int
   43287           0 : __pyx_typeinfo_cmp(__Pyx_TypeInfo *a, __Pyx_TypeInfo *b)
   43288             : {
   43289           0 :     int i;
   43290           0 :     if (!a || !b)
   43291             :         return 0;
   43292           0 :     if (a == b)
   43293             :         return 1;
   43294           0 :     if (a->size != b->size || a->typegroup != b->typegroup ||
   43295           0 :             a->is_unsigned != b->is_unsigned || a->ndim != b->ndim) {
   43296           0 :         if (a->typegroup == 'H' || b->typegroup == 'H') {
   43297           0 :             return a->size == b->size;
   43298             :         } else {
   43299             :             return 0;
   43300             :         }
   43301             :     }
   43302           0 :     if (a->ndim) {
   43303           0 :         for (i = 0; i < a->ndim; i++)
   43304           0 :             if (a->arraysize[i] != b->arraysize[i])
   43305             :                 return 0;
   43306             :     }
   43307           0 :     if (a->typegroup == 'S') {
   43308           0 :         if (a->flags != b->flags)
   43309             :             return 0;
   43310           0 :         if (a->fields || b->fields) {
   43311           0 :             if (!(a->fields && b->fields))
   43312             :                 return 0;
   43313           0 :             for (i = 0; a->fields[i].type && b->fields[i].type; i++) {
   43314           0 :                 __Pyx_StructField *field_a = a->fields + i;
   43315           0 :                 __Pyx_StructField *field_b = b->fields + i;
   43316           0 :                 if (field_a->offset != field_b->offset ||
   43317           0 :                     !__pyx_typeinfo_cmp(field_a->type, field_b->type))
   43318           0 :                     return 0;
   43319             :             }
   43320           0 :             return !a->fields[i].type && !b->fields[i].type;
   43321             :         }
   43322             :     }
   43323             :     return 1;
   43324             : }
   43325             : 
   43326             : /* MemviewSliceValidateAndInit */
   43327             :   static int
   43328           0 : __pyx_check_strides(Py_buffer *buf, int dim, int ndim, int spec)
   43329             : {
   43330           0 :     if (buf->shape[dim] <= 1)
   43331             :         return 1;
   43332           0 :     if (buf->strides) {
   43333           0 :         if (spec & __Pyx_MEMVIEW_CONTIG) {
   43334           0 :             if (spec & (__Pyx_MEMVIEW_PTR|__Pyx_MEMVIEW_FULL)) {
   43335           0 :                 if (unlikely(buf->strides[dim] != sizeof(void *))) {
   43336           0 :                     PyErr_Format(PyExc_ValueError,
   43337             :                                  "Buffer is not indirectly contiguous "
   43338             :                                  "in dimension %d.", dim);
   43339           0 :                     goto fail;
   43340             :                 }
   43341           0 :             } else if (unlikely(buf->strides[dim] != buf->itemsize)) {
   43342           0 :                 PyErr_SetString(PyExc_ValueError,
   43343             :                                 "Buffer and memoryview are not contiguous "
   43344             :                                 "in the same dimension.");
   43345           0 :                 goto fail;
   43346             :             }
   43347             :         }
   43348           0 :         if (spec & __Pyx_MEMVIEW_FOLLOW) {
   43349           0 :             Py_ssize_t stride = buf->strides[dim];
   43350           0 :             if (stride < 0)
   43351             :                 stride = -stride;
   43352           0 :             if (unlikely(stride < buf->itemsize)) {
   43353           0 :                 PyErr_SetString(PyExc_ValueError,
   43354             :                                 "Buffer and memoryview are not contiguous "
   43355             :                                 "in the same dimension.");
   43356           0 :                 goto fail;
   43357             :             }
   43358             :         }
   43359             :     } else {
   43360           0 :         if (unlikely(spec & __Pyx_MEMVIEW_CONTIG && dim != ndim - 1)) {
   43361           0 :             PyErr_Format(PyExc_ValueError,
   43362             :                          "C-contiguous buffer is not contiguous in "
   43363             :                          "dimension %d", dim);
   43364           0 :             goto fail;
   43365           0 :         } else if (unlikely(spec & (__Pyx_MEMVIEW_PTR))) {
   43366           0 :             PyErr_Format(PyExc_ValueError,
   43367             :                          "C-contiguous buffer is not indirect in "
   43368             :                          "dimension %d", dim);
   43369           0 :             goto fail;
   43370           0 :         } else if (unlikely(buf->suboffsets)) {
   43371           0 :             PyErr_SetString(PyExc_ValueError,
   43372             :                             "Buffer exposes suboffsets but no strides");
   43373           0 :             goto fail;
   43374             :         }
   43375             :     }
   43376             :     return 1;
   43377             : fail:
   43378             :     return 0;
   43379             : }
   43380             : static int
   43381           0 : __pyx_check_suboffsets(Py_buffer *buf, int dim, int ndim, int spec)
   43382             : {
   43383           0 :     CYTHON_UNUSED_VAR(ndim);
   43384           0 :     if (spec & __Pyx_MEMVIEW_DIRECT) {
   43385           0 :         if (unlikely(buf->suboffsets && buf->suboffsets[dim] >= 0)) {
   43386           0 :             PyErr_Format(PyExc_ValueError,
   43387             :                          "Buffer not compatible with direct access "
   43388             :                          "in dimension %d.", dim);
   43389           0 :             goto fail;
   43390             :         }
   43391             :     }
   43392           0 :     if (spec & __Pyx_MEMVIEW_PTR) {
   43393           0 :         if (unlikely(!buf->suboffsets || (buf->suboffsets[dim] < 0))) {
   43394           0 :             PyErr_Format(PyExc_ValueError,
   43395             :                          "Buffer is not indirectly accessible "
   43396             :                          "in dimension %d.", dim);
   43397           0 :             goto fail;
   43398             :         }
   43399             :     }
   43400             :     return 1;
   43401             : fail:
   43402             :     return 0;
   43403             : }
   43404             : static int
   43405           0 : __pyx_verify_contig(Py_buffer *buf, int ndim, int c_or_f_flag)
   43406             : {
   43407           0 :     int i;
   43408           0 :     if (c_or_f_flag & __Pyx_IS_F_CONTIG) {
   43409             :         Py_ssize_t stride = 1;
   43410           0 :         for (i = 0; i < ndim; i++) {
   43411           0 :             if (unlikely(stride * buf->itemsize != buf->strides[i]  &&  buf->shape[i] > 1)) {
   43412           0 :                 PyErr_SetString(PyExc_ValueError,
   43413             :                     "Buffer not fortran contiguous.");
   43414           0 :                 goto fail;
   43415             :             }
   43416           0 :             stride = stride * buf->shape[i];
   43417             :         }
   43418           0 :     } else if (c_or_f_flag & __Pyx_IS_C_CONTIG) {
   43419           0 :         Py_ssize_t stride = 1;
   43420           0 :         for (i = ndim - 1; i >- 1; i--) {
   43421           0 :             if (unlikely(stride * buf->itemsize != buf->strides[i]  &&  buf->shape[i] > 1)) {
   43422           0 :                 PyErr_SetString(PyExc_ValueError,
   43423             :                     "Buffer not C contiguous.");
   43424           0 :                 goto fail;
   43425             :             }
   43426           0 :             stride = stride * buf->shape[i];
   43427             :         }
   43428             :     }
   43429             :     return 1;
   43430             : fail:
   43431             :     return 0;
   43432             : }
   43433           0 : static int __Pyx_ValidateAndInit_memviewslice(
   43434             :                 int *axes_specs,
   43435             :                 int c_or_f_flag,
   43436             :                 int buf_flags,
   43437             :                 int ndim,
   43438             :                 __Pyx_TypeInfo *dtype,
   43439             :                 __Pyx_BufFmt_StackElem stack[],
   43440             :                 __Pyx_memviewslice *memviewslice,
   43441             :                 PyObject *original_obj)
   43442             : {
   43443           0 :     struct __pyx_memoryview_obj *memview, *new_memview;
   43444             :     __Pyx_RefNannyDeclarations
   43445           0 :     Py_buffer *buf;
   43446           0 :     int i, spec = 0, retval = -1;
   43447           0 :     __Pyx_BufFmt_Context ctx;
   43448           0 :     int from_memoryview = __pyx_memoryview_check(original_obj);
   43449           0 :     __Pyx_RefNannySetupContext("ValidateAndInit_memviewslice", 0);
   43450           0 :     if (from_memoryview && __pyx_typeinfo_cmp(dtype, ((struct __pyx_memoryview_obj *)
   43451             :                                                             original_obj)->typeinfo)) {
   43452             :         memview = (struct __pyx_memoryview_obj *) original_obj;
   43453             :         new_memview = NULL;
   43454             :     } else {
   43455           0 :         memview = (struct __pyx_memoryview_obj *) __pyx_memoryview_new(
   43456             :                                             original_obj, buf_flags, 0, dtype);
   43457           0 :         new_memview = memview;
   43458           0 :         if (unlikely(!memview))
   43459           0 :             goto fail;
   43460             :     }
   43461           0 :     buf = &memview->view;
   43462           0 :     if (unlikely(buf->ndim != ndim)) {
   43463           0 :         PyErr_Format(PyExc_ValueError,
   43464             :                 "Buffer has wrong number of dimensions (expected %d, got %d)",
   43465             :                 ndim, buf->ndim);
   43466           0 :         goto fail;
   43467             :     }
   43468           0 :     if (new_memview) {
   43469           0 :         __Pyx_BufFmt_Init(&ctx, stack, dtype);
   43470           0 :         if (unlikely(!__Pyx_BufFmt_CheckString(&ctx, buf->format))) goto fail;
   43471             :     }
   43472           0 :     if (unlikely((unsigned) buf->itemsize != dtype->size)) {
   43473           0 :         PyErr_Format(PyExc_ValueError,
   43474             :                      "Item size of buffer (%" CYTHON_FORMAT_SSIZE_T "u byte%s) "
   43475             :                      "does not match size of '%s' (%" CYTHON_FORMAT_SSIZE_T "u byte%s)",
   43476             :                      buf->itemsize,
   43477             :                      (buf->itemsize > 1) ? "s" : "",
   43478             :                      dtype->name,
   43479             :                      dtype->size,
   43480             :                      (dtype->size > 1) ? "s" : "");
   43481           0 :         goto fail;
   43482             :     }
   43483           0 :     if (buf->len > 0) {
   43484           0 :         for (i = 0; i < ndim; i++) {
   43485           0 :             spec = axes_specs[i];
   43486           0 :             if (unlikely(!__pyx_check_strides(buf, i, ndim, spec)))
   43487           0 :                 goto fail;
   43488           0 :             if (unlikely(!__pyx_check_suboffsets(buf, i, ndim, spec)))
   43489           0 :                 goto fail;
   43490             :         }
   43491           0 :         if (unlikely(buf->strides && !__pyx_verify_contig(buf, ndim, c_or_f_flag)))
   43492           0 :             goto fail;
   43493             :     }
   43494           0 :     if (unlikely(__Pyx_init_memviewslice(memview, ndim, memviewslice,
   43495             :                                          new_memview != NULL) == -1)) {
   43496           0 :         goto fail;
   43497             :     }
   43498           0 :     retval = 0;
   43499           0 :     goto no_fail;
   43500           0 : fail:
   43501           0 :     Py_XDECREF(new_memview);
   43502           0 :     retval = -1;
   43503           0 : no_fail:
   43504           0 :     __Pyx_RefNannyFinishContext();
   43505           0 :     return retval;
   43506             : }
   43507             : 
   43508             : /* ObjectToMemviewSlice */
   43509           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int8_t(PyObject *obj, int writable_flag) {
   43510           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43511           0 :     __Pyx_BufFmt_StackElem stack[1];
   43512           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43513           0 :     int retcode;
   43514           0 :     if (obj == Py_None) {
   43515           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43516           0 :         return result;
   43517             :     }
   43518           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43519             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43520             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_int8_t, stack,
   43521             :                                                  &result, obj);
   43522           0 :     if (unlikely(retcode == -1))
   43523           0 :         goto __pyx_fail;
   43524           0 :     return result;
   43525           0 : __pyx_fail:
   43526           0 :     result.memview = NULL;
   43527           0 :     result.data = NULL;
   43528           0 :     return result;
   43529             : }
   43530             : 
   43531             : /* ObjectToMemviewSlice */
   43532           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int16_t(PyObject *obj, int writable_flag) {
   43533           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43534           0 :     __Pyx_BufFmt_StackElem stack[1];
   43535           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43536           0 :     int retcode;
   43537           0 :     if (obj == Py_None) {
   43538           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43539           0 :         return result;
   43540             :     }
   43541           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43542             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43543             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_int16_t, stack,
   43544             :                                                  &result, obj);
   43545           0 :     if (unlikely(retcode == -1))
   43546           0 :         goto __pyx_fail;
   43547           0 :     return result;
   43548           0 : __pyx_fail:
   43549           0 :     result.memview = NULL;
   43550           0 :     result.data = NULL;
   43551           0 :     return result;
   43552             : }
   43553             : 
   43554             : /* ObjectToMemviewSlice */
   43555           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int32_t(PyObject *obj, int writable_flag) {
   43556           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43557           0 :     __Pyx_BufFmt_StackElem stack[1];
   43558           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43559           0 :     int retcode;
   43560           0 :     if (obj == Py_None) {
   43561           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43562           0 :         return result;
   43563             :     }
   43564           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43565             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43566             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, stack,
   43567             :                                                  &result, obj);
   43568           0 :     if (unlikely(retcode == -1))
   43569           0 :         goto __pyx_fail;
   43570           0 :     return result;
   43571           0 : __pyx_fail:
   43572           0 :     result.memview = NULL;
   43573           0 :     result.data = NULL;
   43574           0 :     return result;
   43575             : }
   43576             : 
   43577             : /* ObjectToMemviewSlice */
   43578           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_int64_t(PyObject *obj, int writable_flag) {
   43579           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43580           0 :     __Pyx_BufFmt_StackElem stack[1];
   43581           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43582           0 :     int retcode;
   43583           0 :     if (obj == Py_None) {
   43584           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43585           0 :         return result;
   43586             :     }
   43587           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43588             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43589             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, stack,
   43590             :                                                  &result, obj);
   43591           0 :     if (unlikely(retcode == -1))
   43592           0 :         goto __pyx_fail;
   43593           0 :     return result;
   43594           0 : __pyx_fail:
   43595           0 :     result.memview = NULL;
   43596           0 :     result.data = NULL;
   43597           0 :     return result;
   43598             : }
   43599             : 
   43600             : /* ObjectToMemviewSlice */
   43601           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint8_t(PyObject *obj, int writable_flag) {
   43602           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43603           0 :     __Pyx_BufFmt_StackElem stack[1];
   43604           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43605           0 :     int retcode;
   43606           0 :     if (obj == Py_None) {
   43607           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43608           0 :         return result;
   43609             :     }
   43610           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43611             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43612             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint8_t, stack,
   43613             :                                                  &result, obj);
   43614           0 :     if (unlikely(retcode == -1))
   43615           0 :         goto __pyx_fail;
   43616           0 :     return result;
   43617           0 : __pyx_fail:
   43618           0 :     result.memview = NULL;
   43619           0 :     result.data = NULL;
   43620           0 :     return result;
   43621             : }
   43622             : 
   43623             : /* ObjectToMemviewSlice */
   43624           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint16_t(PyObject *obj, int writable_flag) {
   43625           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43626           0 :     __Pyx_BufFmt_StackElem stack[1];
   43627           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43628           0 :     int retcode;
   43629           0 :     if (obj == Py_None) {
   43630           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43631           0 :         return result;
   43632             :     }
   43633           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43634             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43635             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint16_t, stack,
   43636             :                                                  &result, obj);
   43637           0 :     if (unlikely(retcode == -1))
   43638           0 :         goto __pyx_fail;
   43639           0 :     return result;
   43640           0 : __pyx_fail:
   43641           0 :     result.memview = NULL;
   43642           0 :     result.data = NULL;
   43643           0 :     return result;
   43644             : }
   43645             : 
   43646             : /* ObjectToMemviewSlice */
   43647           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint32_t(PyObject *obj, int writable_flag) {
   43648           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43649           0 :     __Pyx_BufFmt_StackElem stack[1];
   43650           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43651           0 :     int retcode;
   43652           0 :     if (obj == Py_None) {
   43653           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43654           0 :         return result;
   43655             :     }
   43656           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43657             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43658             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint32_t, stack,
   43659             :                                                  &result, obj);
   43660           0 :     if (unlikely(retcode == -1))
   43661           0 :         goto __pyx_fail;
   43662           0 :     return result;
   43663           0 : __pyx_fail:
   43664           0 :     result.memview = NULL;
   43665           0 :     result.data = NULL;
   43666           0 :     return result;
   43667             : }
   43668             : 
   43669             : /* ObjectToMemviewSlice */
   43670           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_uint64_t(PyObject *obj, int writable_flag) {
   43671           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43672           0 :     __Pyx_BufFmt_StackElem stack[1];
   43673           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43674           0 :     int retcode;
   43675           0 :     if (obj == Py_None) {
   43676           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43677           0 :         return result;
   43678             :     }
   43679           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43680             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43681             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_uint64_t, stack,
   43682             :                                                  &result, obj);
   43683           0 :     if (unlikely(retcode == -1))
   43684           0 :         goto __pyx_fail;
   43685           0 :     return result;
   43686           0 : __pyx_fail:
   43687           0 :     result.memview = NULL;
   43688           0 :     result.data = NULL;
   43689           0 :     return result;
   43690             : }
   43691             : 
   43692             : /* ObjectToMemviewSlice */
   43693           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float32_t(PyObject *obj, int writable_flag) {
   43694           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43695           0 :     __Pyx_BufFmt_StackElem stack[1];
   43696           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43697           0 :     int retcode;
   43698           0 :     if (obj == Py_None) {
   43699           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43700           0 :         return result;
   43701             :     }
   43702           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43703             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43704             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, stack,
   43705             :                                                  &result, obj);
   43706           0 :     if (unlikely(retcode == -1))
   43707           0 :         goto __pyx_fail;
   43708           0 :     return result;
   43709           0 : __pyx_fail:
   43710           0 :     result.memview = NULL;
   43711           0 :     result.data = NULL;
   43712           0 :     return result;
   43713             : }
   43714             : 
   43715             : /* ObjectToMemviewSlice */
   43716           0 :   static CYTHON_INLINE __Pyx_memviewslice __Pyx_PyObject_to_MemoryviewSlice_ds_nn___pyx_t_5numpy_float64_t(PyObject *obj, int writable_flag) {
   43717           0 :     __Pyx_memviewslice result = { 0, 0, { 0 }, { 0 }, { 0 } };
   43718           0 :     __Pyx_BufFmt_StackElem stack[1];
   43719           0 :     int axes_specs[] = { (__Pyx_MEMVIEW_DIRECT | __Pyx_MEMVIEW_STRIDED) };
   43720           0 :     int retcode;
   43721           0 :     if (obj == Py_None) {
   43722           0 :         result.memview = (struct __pyx_memoryview_obj *) Py_None;
   43723           0 :         return result;
   43724             :     }
   43725           0 :     retcode = __Pyx_ValidateAndInit_memviewslice(axes_specs, 0,
   43726             :                                                  PyBUF_RECORDS_RO | writable_flag, 1,
   43727             :                                                  &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, stack,
   43728             :                                                  &result, obj);
   43729           0 :     if (unlikely(retcode == -1))
   43730           0 :         goto __pyx_fail;
   43731           0 :     return result;
   43732           0 : __pyx_fail:
   43733           0 :     result.memview = NULL;
   43734           0 :     result.data = NULL;
   43735           0 :     return result;
   43736             : }
   43737             : 
   43738             : /* CIntFromPyVerify */
   43739             :   #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
   43740             :     __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
   43741             : #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
   43742             :     __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
   43743             : #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
   43744             :     {\
   43745             :         func_type value = func_value;\
   43746             :         if (sizeof(target_type) < sizeof(func_type)) {\
   43747             :             if (unlikely(value != (func_type) (target_type) value)) {\
   43748             :                 func_type zero = 0;\
   43749             :                 if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
   43750             :                     return (target_type) -1;\
   43751             :                 if (is_unsigned && unlikely(value < zero))\
   43752             :                     goto raise_neg_overflow;\
   43753             :                 else\
   43754             :                     goto raise_overflow;\
   43755             :             }\
   43756             :         }\
   43757             :         return (target_type) value;\
   43758             :     }
   43759             : 
   43760             : /* PyUCS4InUnicode */
   43761             :   #if PY_VERSION_HEX < 0x03090000 || (defined(PyUnicode_WCHAR_KIND) && defined(PyUnicode_AS_UNICODE))
   43762             : #if PY_VERSION_HEX < 0x03090000
   43763             : #define __Pyx_PyUnicode_AS_UNICODE(op) PyUnicode_AS_UNICODE(op)
   43764             : #define __Pyx_PyUnicode_GET_SIZE(op) PyUnicode_GET_SIZE(op)
   43765             : #else
   43766             : #define __Pyx_PyUnicode_AS_UNICODE(op) (((PyASCIIObject *)(op))->wstr)
   43767             : #define __Pyx_PyUnicode_GET_SIZE(op) ((PyCompactUnicodeObject *)(op))->wstr_length
   43768             : #endif
   43769             : #if !defined(Py_UNICODE_SIZE) || Py_UNICODE_SIZE == 2
   43770             : static int __Pyx_PyUnicodeBufferContainsUCS4_SP(Py_UNICODE* buffer, Py_ssize_t length, Py_UCS4 character) {
   43771             :     Py_UNICODE high_val, low_val;
   43772             :     Py_UNICODE* pos;
   43773             :     high_val = (Py_UNICODE) (0xD800 | (((character - 0x10000) >> 10) & ((1<<10)-1)));
   43774             :     low_val  = (Py_UNICODE) (0xDC00 | ( (character - 0x10000)        & ((1<<10)-1)));
   43775             :     for (pos=buffer; pos < buffer+length-1; pos++) {
   43776             :         if (unlikely((high_val == pos[0]) & (low_val == pos[1]))) return 1;
   43777             :     }
   43778             :     return 0;
   43779             : }
   43780             : #endif
   43781             : static int __Pyx_PyUnicodeBufferContainsUCS4_BMP(Py_UNICODE* buffer, Py_ssize_t length, Py_UCS4 character) {
   43782             :     Py_UNICODE uchar;
   43783             :     Py_UNICODE* pos;
   43784             :     uchar = (Py_UNICODE) character;
   43785             :     for (pos=buffer; pos < buffer+length; pos++) {
   43786             :         if (unlikely(uchar == pos[0])) return 1;
   43787             :     }
   43788             :     return 0;
   43789             : }
   43790             : #endif
   43791             : static CYTHON_INLINE int __Pyx_UnicodeContainsUCS4(PyObject* unicode, Py_UCS4 character) {
   43792             : #if CYTHON_PEP393_ENABLED
   43793             :     const int kind = PyUnicode_KIND(unicode);
   43794             :     #ifdef PyUnicode_WCHAR_KIND
   43795             :     if (likely(kind != PyUnicode_WCHAR_KIND))
   43796             :     #endif
   43797             :     {
   43798             :         Py_ssize_t i;
   43799             :         const void* udata = PyUnicode_DATA(unicode);
   43800             :         const Py_ssize_t length = PyUnicode_GET_LENGTH(unicode);
   43801             :         for (i=0; i < length; i++) {
   43802             :             if (unlikely(character == PyUnicode_READ(kind, udata, i))) return 1;
   43803             :         }
   43804             :         return 0;
   43805             :     }
   43806             : #elif PY_VERSION_HEX >= 0x03090000
   43807             :     #error Cannot use "UChar in Unicode" in Python 3.9 without PEP-393 unicode strings.
   43808             : #elif !defined(PyUnicode_AS_UNICODE)
   43809             :     #error Cannot use "UChar in Unicode" in Python < 3.9 without Py_UNICODE support.
   43810             : #endif
   43811             : #if PY_VERSION_HEX < 0x03090000 || (defined(PyUnicode_WCHAR_KIND) && defined(PyUnicode_AS_UNICODE))
   43812             : #if !defined(Py_UNICODE_SIZE) || Py_UNICODE_SIZE == 2
   43813             :     if ((sizeof(Py_UNICODE) == 2) && unlikely(character > 65535)) {
   43814             :         return __Pyx_PyUnicodeBufferContainsUCS4_SP(
   43815             :             __Pyx_PyUnicode_AS_UNICODE(unicode),
   43816             :             __Pyx_PyUnicode_GET_SIZE(unicode),
   43817             :             character);
   43818             :     } else
   43819             : #endif
   43820             :     {
   43821             :         return __Pyx_PyUnicodeBufferContainsUCS4_BMP(
   43822             :             __Pyx_PyUnicode_AS_UNICODE(unicode),
   43823             :             __Pyx_PyUnicode_GET_SIZE(unicode),
   43824             :             character);
   43825             :     }
   43826             : #endif
   43827             : }
   43828             : 
   43829             : /* Declarations */
   43830             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   43831             :   #ifdef __cplusplus
   43832             :     static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
   43833             :       return ::std::complex< float >(x, y);
   43834             :     }
   43835             :   #else
   43836             :     static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
   43837             :       return x + y*(__pyx_t_float_complex)_Complex_I;
   43838             :     }
   43839             :   #endif
   43840             : #else
   43841             :     static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
   43842             :       __pyx_t_float_complex z;
   43843             :       z.real = x;
   43844             :       z.imag = y;
   43845             :       return z;
   43846             :     }
   43847             : #endif
   43848             : 
   43849             : /* Arithmetic */
   43850             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   43851             : #else
   43852             :     static CYTHON_INLINE int __Pyx_c_eq_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43853             :        return (a.real == b.real) && (a.imag == b.imag);
   43854             :     }
   43855             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43856             :         __pyx_t_float_complex z;
   43857             :         z.real = a.real + b.real;
   43858             :         z.imag = a.imag + b.imag;
   43859             :         return z;
   43860             :     }
   43861             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43862             :         __pyx_t_float_complex z;
   43863             :         z.real = a.real - b.real;
   43864             :         z.imag = a.imag - b.imag;
   43865             :         return z;
   43866             :     }
   43867             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43868             :         __pyx_t_float_complex z;
   43869             :         z.real = a.real * b.real - a.imag * b.imag;
   43870             :         z.imag = a.real * b.imag + a.imag * b.real;
   43871             :         return z;
   43872             :     }
   43873             :     #if 1
   43874             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43875             :         if (b.imag == 0) {
   43876             :             return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
   43877             :         } else if (fabsf(b.real) >= fabsf(b.imag)) {
   43878             :             if (b.real == 0 && b.imag == 0) {
   43879             :                 return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.imag);
   43880             :             } else {
   43881             :                 float r = b.imag / b.real;
   43882             :                 float s = (float)(1.0) / (b.real + b.imag * r);
   43883             :                 return __pyx_t_float_complex_from_parts(
   43884             :                     (a.real + a.imag * r) * s, (a.imag - a.real * r) * s);
   43885             :             }
   43886             :         } else {
   43887             :             float r = b.real / b.imag;
   43888             :             float s = (float)(1.0) / (b.imag + b.real * r);
   43889             :             return __pyx_t_float_complex_from_parts(
   43890             :                 (a.real * r + a.imag) * s, (a.imag * r - a.real) * s);
   43891             :         }
   43892             :     }
   43893             :     #else
   43894             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43895             :         if (b.imag == 0) {
   43896             :             return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
   43897             :         } else {
   43898             :             float denom = b.real * b.real + b.imag * b.imag;
   43899             :             return __pyx_t_float_complex_from_parts(
   43900             :                 (a.real * b.real + a.imag * b.imag) / denom,
   43901             :                 (a.imag * b.real - a.real * b.imag) / denom);
   43902             :         }
   43903             :     }
   43904             :     #endif
   43905             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex a) {
   43906             :         __pyx_t_float_complex z;
   43907             :         z.real = -a.real;
   43908             :         z.imag = -a.imag;
   43909             :         return z;
   43910             :     }
   43911             :     static CYTHON_INLINE int __Pyx_c_is_zero_float(__pyx_t_float_complex a) {
   43912             :        return (a.real == 0) && (a.imag == 0);
   43913             :     }
   43914             :     static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex a) {
   43915             :         __pyx_t_float_complex z;
   43916             :         z.real =  a.real;
   43917             :         z.imag = -a.imag;
   43918             :         return z;
   43919             :     }
   43920             :     #if 1
   43921             :         static CYTHON_INLINE float __Pyx_c_abs_float(__pyx_t_float_complex z) {
   43922             :           #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
   43923             :             return sqrtf(z.real*z.real + z.imag*z.imag);
   43924             :           #else
   43925             :             return hypotf(z.real, z.imag);
   43926             :           #endif
   43927             :         }
   43928             :         static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
   43929             :             __pyx_t_float_complex z;
   43930             :             float r, lnr, theta, z_r, z_theta;
   43931             :             if (b.imag == 0 && b.real == (int)b.real) {
   43932             :                 if (b.real < 0) {
   43933             :                     float denom = a.real * a.real + a.imag * a.imag;
   43934             :                     a.real = a.real / denom;
   43935             :                     a.imag = -a.imag / denom;
   43936             :                     b.real = -b.real;
   43937             :                 }
   43938             :                 switch ((int)b.real) {
   43939             :                     case 0:
   43940             :                         z.real = 1;
   43941             :                         z.imag = 0;
   43942             :                         return z;
   43943             :                     case 1:
   43944             :                         return a;
   43945             :                     case 2:
   43946             :                         return __Pyx_c_prod_float(a, a);
   43947             :                     case 3:
   43948             :                         z = __Pyx_c_prod_float(a, a);
   43949             :                         return __Pyx_c_prod_float(z, a);
   43950             :                     case 4:
   43951             :                         z = __Pyx_c_prod_float(a, a);
   43952             :                         return __Pyx_c_prod_float(z, z);
   43953             :                 }
   43954             :             }
   43955             :             if (a.imag == 0) {
   43956             :                 if (a.real == 0) {
   43957             :                     return a;
   43958             :                 } else if ((b.imag == 0) && (a.real >= 0)) {
   43959             :                     z.real = powf(a.real, b.real);
   43960             :                     z.imag = 0;
   43961             :                     return z;
   43962             :                 } else if (a.real > 0) {
   43963             :                     r = a.real;
   43964             :                     theta = 0;
   43965             :                 } else {
   43966             :                     r = -a.real;
   43967             :                     theta = atan2f(0.0, -1.0);
   43968             :                 }
   43969             :             } else {
   43970             :                 r = __Pyx_c_abs_float(a);
   43971             :                 theta = atan2f(a.imag, a.real);
   43972             :             }
   43973             :             lnr = logf(r);
   43974             :             z_r = expf(lnr * b.real - theta * b.imag);
   43975             :             z_theta = theta * b.real + lnr * b.imag;
   43976             :             z.real = z_r * cosf(z_theta);
   43977             :             z.imag = z_r * sinf(z_theta);
   43978             :             return z;
   43979             :         }
   43980             :     #endif
   43981             : #endif
   43982             : 
   43983             : /* Declarations */
   43984             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   43985             :   #ifdef __cplusplus
   43986             :     static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
   43987             :       return ::std::complex< double >(x, y);
   43988             :     }
   43989             :   #else
   43990             :     static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
   43991             :       return x + y*(__pyx_t_double_complex)_Complex_I;
   43992             :     }
   43993             :   #endif
   43994             : #else
   43995             :     static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
   43996             :       __pyx_t_double_complex z;
   43997             :       z.real = x;
   43998             :       z.imag = y;
   43999             :       return z;
   44000             :     }
   44001             : #endif
   44002             : 
   44003             : /* Arithmetic */
   44004             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   44005             : #else
   44006             :     static CYTHON_INLINE int __Pyx_c_eq_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44007             :        return (a.real == b.real) && (a.imag == b.imag);
   44008             :     }
   44009             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44010             :         __pyx_t_double_complex z;
   44011             :         z.real = a.real + b.real;
   44012             :         z.imag = a.imag + b.imag;
   44013             :         return z;
   44014             :     }
   44015             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44016             :         __pyx_t_double_complex z;
   44017             :         z.real = a.real - b.real;
   44018             :         z.imag = a.imag - b.imag;
   44019             :         return z;
   44020             :     }
   44021             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44022             :         __pyx_t_double_complex z;
   44023             :         z.real = a.real * b.real - a.imag * b.imag;
   44024             :         z.imag = a.real * b.imag + a.imag * b.real;
   44025             :         return z;
   44026             :     }
   44027             :     #if 1
   44028             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44029             :         if (b.imag == 0) {
   44030             :             return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
   44031             :         } else if (fabs(b.real) >= fabs(b.imag)) {
   44032             :             if (b.real == 0 && b.imag == 0) {
   44033             :                 return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.imag);
   44034             :             } else {
   44035             :                 double r = b.imag / b.real;
   44036             :                 double s = (double)(1.0) / (b.real + b.imag * r);
   44037             :                 return __pyx_t_double_complex_from_parts(
   44038             :                     (a.real + a.imag * r) * s, (a.imag - a.real * r) * s);
   44039             :             }
   44040             :         } else {
   44041             :             double r = b.real / b.imag;
   44042             :             double s = (double)(1.0) / (b.imag + b.real * r);
   44043             :             return __pyx_t_double_complex_from_parts(
   44044             :                 (a.real * r + a.imag) * s, (a.imag * r - a.real) * s);
   44045             :         }
   44046             :     }
   44047             :     #else
   44048             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44049             :         if (b.imag == 0) {
   44050             :             return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
   44051             :         } else {
   44052             :             double denom = b.real * b.real + b.imag * b.imag;
   44053             :             return __pyx_t_double_complex_from_parts(
   44054             :                 (a.real * b.real + a.imag * b.imag) / denom,
   44055             :                 (a.imag * b.real - a.real * b.imag) / denom);
   44056             :         }
   44057             :     }
   44058             :     #endif
   44059             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex a) {
   44060             :         __pyx_t_double_complex z;
   44061             :         z.real = -a.real;
   44062             :         z.imag = -a.imag;
   44063             :         return z;
   44064             :     }
   44065             :     static CYTHON_INLINE int __Pyx_c_is_zero_double(__pyx_t_double_complex a) {
   44066             :        return (a.real == 0) && (a.imag == 0);
   44067             :     }
   44068             :     static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex a) {
   44069             :         __pyx_t_double_complex z;
   44070             :         z.real =  a.real;
   44071             :         z.imag = -a.imag;
   44072             :         return z;
   44073             :     }
   44074             :     #if 1
   44075             :         static CYTHON_INLINE double __Pyx_c_abs_double(__pyx_t_double_complex z) {
   44076             :           #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
   44077             :             return sqrt(z.real*z.real + z.imag*z.imag);
   44078             :           #else
   44079             :             return hypot(z.real, z.imag);
   44080             :           #endif
   44081             :         }
   44082             :         static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
   44083             :             __pyx_t_double_complex z;
   44084             :             double r, lnr, theta, z_r, z_theta;
   44085             :             if (b.imag == 0 && b.real == (int)b.real) {
   44086             :                 if (b.real < 0) {
   44087             :                     double denom = a.real * a.real + a.imag * a.imag;
   44088             :                     a.real = a.real / denom;
   44089             :                     a.imag = -a.imag / denom;
   44090             :                     b.real = -b.real;
   44091             :                 }
   44092             :                 switch ((int)b.real) {
   44093             :                     case 0:
   44094             :                         z.real = 1;
   44095             :                         z.imag = 0;
   44096             :                         return z;
   44097             :                     case 1:
   44098             :                         return a;
   44099             :                     case 2:
   44100             :                         return __Pyx_c_prod_double(a, a);
   44101             :                     case 3:
   44102             :                         z = __Pyx_c_prod_double(a, a);
   44103             :                         return __Pyx_c_prod_double(z, a);
   44104             :                     case 4:
   44105             :                         z = __Pyx_c_prod_double(a, a);
   44106             :                         return __Pyx_c_prod_double(z, z);
   44107             :                 }
   44108             :             }
   44109             :             if (a.imag == 0) {
   44110             :                 if (a.real == 0) {
   44111             :                     return a;
   44112             :                 } else if ((b.imag == 0) && (a.real >= 0)) {
   44113             :                     z.real = pow(a.real, b.real);
   44114             :                     z.imag = 0;
   44115             :                     return z;
   44116             :                 } else if (a.real > 0) {
   44117             :                     r = a.real;
   44118             :                     theta = 0;
   44119             :                 } else {
   44120             :                     r = -a.real;
   44121             :                     theta = atan2(0.0, -1.0);
   44122             :                 }
   44123             :             } else {
   44124             :                 r = __Pyx_c_abs_double(a);
   44125             :                 theta = atan2(a.imag, a.real);
   44126             :             }
   44127             :             lnr = log(r);
   44128             :             z_r = exp(lnr * b.real - theta * b.imag);
   44129             :             z_theta = theta * b.real + lnr * b.imag;
   44130             :             z.real = z_r * cos(z_theta);
   44131             :             z.imag = z_r * sin(z_theta);
   44132             :             return z;
   44133             :         }
   44134             :     #endif
   44135             : #endif
   44136             : 
   44137             : /* Declarations */
   44138             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   44139             :   #ifdef __cplusplus
   44140             :     static CYTHON_INLINE __pyx_t_long_double_complex __pyx_t_long_double_complex_from_parts(long double x, long double y) {
   44141             :       return ::std::complex< long double >(x, y);
   44142             :     }
   44143             :   #else
   44144             :     static CYTHON_INLINE __pyx_t_long_double_complex __pyx_t_long_double_complex_from_parts(long double x, long double y) {
   44145             :       return x + y*(__pyx_t_long_double_complex)_Complex_I;
   44146             :     }
   44147             :   #endif
   44148             : #else
   44149             :     static CYTHON_INLINE __pyx_t_long_double_complex __pyx_t_long_double_complex_from_parts(long double x, long double y) {
   44150             :       __pyx_t_long_double_complex z;
   44151             :       z.real = x;
   44152             :       z.imag = y;
   44153             :       return z;
   44154             :     }
   44155             : #endif
   44156             : 
   44157             : /* Arithmetic */
   44158             :   #if CYTHON_CCOMPLEX && (1) && (!0 || __cplusplus)
   44159             : #else
   44160             :     static CYTHON_INLINE int __Pyx_c_eq_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44161             :        return (a.real == b.real) && (a.imag == b.imag);
   44162             :     }
   44163             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_sum_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44164             :         __pyx_t_long_double_complex z;
   44165             :         z.real = a.real + b.real;
   44166             :         z.imag = a.imag + b.imag;
   44167             :         return z;
   44168             :     }
   44169             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_diff_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44170             :         __pyx_t_long_double_complex z;
   44171             :         z.real = a.real - b.real;
   44172             :         z.imag = a.imag - b.imag;
   44173             :         return z;
   44174             :     }
   44175             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_prod_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44176             :         __pyx_t_long_double_complex z;
   44177             :         z.real = a.real * b.real - a.imag * b.imag;
   44178             :         z.imag = a.real * b.imag + a.imag * b.real;
   44179             :         return z;
   44180             :     }
   44181             :     #if 1
   44182             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_quot_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44183             :         if (b.imag == 0) {
   44184             :             return __pyx_t_long_double_complex_from_parts(a.real / b.real, a.imag / b.real);
   44185             :         } else if (fabsl(b.real) >= fabsl(b.imag)) {
   44186             :             if (b.real == 0 && b.imag == 0) {
   44187             :                 return __pyx_t_long_double_complex_from_parts(a.real / b.real, a.imag / b.imag);
   44188             :             } else {
   44189             :                 long double r = b.imag / b.real;
   44190             :                 long double s = (long double)(1.0) / (b.real + b.imag * r);
   44191             :                 return __pyx_t_long_double_complex_from_parts(
   44192             :                     (a.real + a.imag * r) * s, (a.imag - a.real * r) * s);
   44193             :             }
   44194             :         } else {
   44195             :             long double r = b.real / b.imag;
   44196             :             long double s = (long double)(1.0) / (b.imag + b.real * r);
   44197             :             return __pyx_t_long_double_complex_from_parts(
   44198             :                 (a.real * r + a.imag) * s, (a.imag * r - a.real) * s);
   44199             :         }
   44200             :     }
   44201             :     #else
   44202             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_quot_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44203             :         if (b.imag == 0) {
   44204             :             return __pyx_t_long_double_complex_from_parts(a.real / b.real, a.imag / b.real);
   44205             :         } else {
   44206             :             long double denom = b.real * b.real + b.imag * b.imag;
   44207             :             return __pyx_t_long_double_complex_from_parts(
   44208             :                 (a.real * b.real + a.imag * b.imag) / denom,
   44209             :                 (a.imag * b.real - a.real * b.imag) / denom);
   44210             :         }
   44211             :     }
   44212             :     #endif
   44213             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_neg_long__double(__pyx_t_long_double_complex a) {
   44214             :         __pyx_t_long_double_complex z;
   44215             :         z.real = -a.real;
   44216             :         z.imag = -a.imag;
   44217             :         return z;
   44218             :     }
   44219             :     static CYTHON_INLINE int __Pyx_c_is_zero_long__double(__pyx_t_long_double_complex a) {
   44220             :        return (a.real == 0) && (a.imag == 0);
   44221             :     }
   44222             :     static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_conj_long__double(__pyx_t_long_double_complex a) {
   44223             :         __pyx_t_long_double_complex z;
   44224             :         z.real =  a.real;
   44225             :         z.imag = -a.imag;
   44226             :         return z;
   44227             :     }
   44228             :     #if 1
   44229             :         static CYTHON_INLINE long double __Pyx_c_abs_long__double(__pyx_t_long_double_complex z) {
   44230             :           #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
   44231             :             return sqrtl(z.real*z.real + z.imag*z.imag);
   44232             :           #else
   44233             :             return hypotl(z.real, z.imag);
   44234             :           #endif
   44235             :         }
   44236             :         static CYTHON_INLINE __pyx_t_long_double_complex __Pyx_c_pow_long__double(__pyx_t_long_double_complex a, __pyx_t_long_double_complex b) {
   44237             :             __pyx_t_long_double_complex z;
   44238             :             long double r, lnr, theta, z_r, z_theta;
   44239             :             if (b.imag == 0 && b.real == (int)b.real) {
   44240             :                 if (b.real < 0) {
   44241             :                     long double denom = a.real * a.real + a.imag * a.imag;
   44242             :                     a.real = a.real / denom;
   44243             :                     a.imag = -a.imag / denom;
   44244             :                     b.real = -b.real;
   44245             :                 }
   44246             :                 switch ((int)b.real) {
   44247             :                     case 0:
   44248             :                         z.real = 1;
   44249             :                         z.imag = 0;
   44250             :                         return z;
   44251             :                     case 1:
   44252             :                         return a;
   44253             :                     case 2:
   44254             :                         return __Pyx_c_prod_long__double(a, a);
   44255             :                     case 3:
   44256             :                         z = __Pyx_c_prod_long__double(a, a);
   44257             :                         return __Pyx_c_prod_long__double(z, a);
   44258             :                     case 4:
   44259             :                         z = __Pyx_c_prod_long__double(a, a);
   44260             :                         return __Pyx_c_prod_long__double(z, z);
   44261             :                 }
   44262             :             }
   44263             :             if (a.imag == 0) {
   44264             :                 if (a.real == 0) {
   44265             :                     return a;
   44266             :                 } else if ((b.imag == 0) && (a.real >= 0)) {
   44267             :                     z.real = powl(a.real, b.real);
   44268             :                     z.imag = 0;
   44269             :                     return z;
   44270             :                 } else if (a.real > 0) {
   44271             :                     r = a.real;
   44272             :                     theta = 0;
   44273             :                 } else {
   44274             :                     r = -a.real;
   44275             :                     theta = atan2l(0.0, -1.0);
   44276             :                 }
   44277             :             } else {
   44278             :                 r = __Pyx_c_abs_long__double(a);
   44279             :                 theta = atan2l(a.imag, a.real);
   44280             :             }
   44281             :             lnr = logl(r);
   44282             :             z_r = expl(lnr * b.real - theta * b.imag);
   44283             :             z_theta = theta * b.real + lnr * b.imag;
   44284             :             z.real = z_r * cosl(z_theta);
   44285             :             z.imag = z_r * sinl(z_theta);
   44286             :             return z;
   44287             :         }
   44288             :     #endif
   44289             : #endif
   44290             : 
   44291             : /* MemviewSliceCopyTemplate */
   44292             :   static __Pyx_memviewslice
   44293           0 : __pyx_memoryview_copy_new_contig(const __Pyx_memviewslice *from_mvs,
   44294             :                                  const char *mode, int ndim,
   44295             :                                  size_t sizeof_dtype, int contig_flag,
   44296             :                                  int dtype_is_object)
   44297             : {
   44298             :     __Pyx_RefNannyDeclarations
   44299           0 :     int i;
   44300           0 :     __Pyx_memviewslice new_mvs = { 0, 0, { 0 }, { 0 }, { 0 } };
   44301           0 :     struct __pyx_memoryview_obj *from_memview = from_mvs->memview;
   44302           0 :     Py_buffer *buf = &from_memview->view;
   44303           0 :     PyObject *shape_tuple = NULL;
   44304           0 :     PyObject *temp_int = NULL;
   44305           0 :     struct __pyx_array_obj *array_obj = NULL;
   44306           0 :     struct __pyx_memoryview_obj *memview_obj = NULL;
   44307           0 :     __Pyx_RefNannySetupContext("__pyx_memoryview_copy_new_contig", 0);
   44308           0 :     for (i = 0; i < ndim; i++) {
   44309           0 :         if (unlikely(from_mvs->suboffsets[i] >= 0)) {
   44310           0 :             PyErr_Format(PyExc_ValueError, "Cannot copy memoryview slice with "
   44311             :                                            "indirect dimensions (axis %d)", i);
   44312           0 :             goto fail;
   44313             :         }
   44314             :     }
   44315           0 :     shape_tuple = PyTuple_New(ndim);
   44316           0 :     if (unlikely(!shape_tuple)) {
   44317           0 :         goto fail;
   44318             :     }
   44319             :     __Pyx_GOTREF(shape_tuple);
   44320           0 :     for(i = 0; i < ndim; i++) {
   44321           0 :         temp_int = PyInt_FromSsize_t(from_mvs->shape[i]);
   44322           0 :         if(unlikely(!temp_int)) {
   44323           0 :             goto fail;
   44324             :         } else {
   44325           0 :             PyTuple_SET_ITEM(shape_tuple, i, temp_int);
   44326           0 :             temp_int = NULL;
   44327             :         }
   44328             :     }
   44329           0 :     array_obj = __pyx_array_new(shape_tuple, sizeof_dtype, buf->format, (char *) mode, NULL);
   44330           0 :     if (unlikely(!array_obj)) {
   44331           0 :         goto fail;
   44332             :     }
   44333           0 :     __Pyx_GOTREF(array_obj);
   44334           0 :     memview_obj = (struct __pyx_memoryview_obj *) __pyx_memoryview_new(
   44335             :                                     (PyObject *) array_obj, contig_flag,
   44336             :                                     dtype_is_object,
   44337           0 :                                     from_mvs->memview->typeinfo);
   44338           0 :     if (unlikely(!memview_obj))
   44339           0 :         goto fail;
   44340           0 :     if (unlikely(__Pyx_init_memviewslice(memview_obj, ndim, &new_mvs, 1) < 0))
   44341           0 :         goto fail;
   44342           0 :     if (unlikely(__pyx_memoryview_copy_contents(*from_mvs, new_mvs, ndim, ndim,
   44343             :                                                 dtype_is_object) < 0))
   44344           0 :         goto fail;
   44345           0 :     goto no_fail;
   44346           0 : fail:
   44347           0 :     __Pyx_XDECREF(new_mvs.memview);
   44348           0 :     new_mvs.memview = NULL;
   44349           0 :     new_mvs.data = NULL;
   44350           0 : no_fail:
   44351           0 :     __Pyx_XDECREF(shape_tuple);
   44352           0 :     __Pyx_XDECREF(temp_int);
   44353           0 :     __Pyx_XDECREF(array_obj);
   44354           0 :     __Pyx_RefNannyFinishContext();
   44355           0 :     return new_mvs;
   44356             : }
   44357             : 
   44358             : /* MemviewSliceInit */
   44359             :   static int
   44360           0 : __Pyx_init_memviewslice(struct __pyx_memoryview_obj *memview,
   44361             :                         int ndim,
   44362             :                         __Pyx_memviewslice *memviewslice,
   44363             :                         int memview_is_new_reference)
   44364             : {
   44365             :     __Pyx_RefNannyDeclarations
   44366           0 :     int i, retval=-1;
   44367           0 :     Py_buffer *buf = &memview->view;
   44368           0 :     __Pyx_RefNannySetupContext("init_memviewslice", 0);
   44369           0 :     if (unlikely(memviewslice->memview || memviewslice->data)) {
   44370           0 :         PyErr_SetString(PyExc_ValueError,
   44371             :             "memviewslice is already initialized!");
   44372           0 :         goto fail;
   44373             :     }
   44374           0 :     if (buf->strides) {
   44375           0 :         for (i = 0; i < ndim; i++) {
   44376           0 :             memviewslice->strides[i] = buf->strides[i];
   44377             :         }
   44378             :     } else {
   44379           0 :         Py_ssize_t stride = buf->itemsize;
   44380           0 :         for (i = ndim - 1; i >= 0; i--) {
   44381           0 :             memviewslice->strides[i] = stride;
   44382           0 :             stride *= buf->shape[i];
   44383             :         }
   44384             :     }
   44385           0 :     for (i = 0; i < ndim; i++) {
   44386           0 :         memviewslice->shape[i]   = buf->shape[i];
   44387           0 :         if (buf->suboffsets) {
   44388           0 :             memviewslice->suboffsets[i] = buf->suboffsets[i];
   44389             :         } else {
   44390           0 :             memviewslice->suboffsets[i] = -1;
   44391             :         }
   44392             :     }
   44393           0 :     memviewslice->memview = memview;
   44394           0 :     memviewslice->data = (char *)buf->buf;
   44395           0 :     if (__pyx_add_acquisition_count(memview) == 0 && !memview_is_new_reference) {
   44396           0 :         Py_INCREF(memview);
   44397             :     }
   44398           0 :     retval = 0;
   44399           0 :     goto no_fail;
   44400           0 : fail:
   44401           0 :     memviewslice->memview = 0;
   44402           0 :     memviewslice->data = 0;
   44403           0 :     retval = -1;
   44404           0 : no_fail:
   44405           0 :     __Pyx_RefNannyFinishContext();
   44406           0 :     return retval;
   44407             : }
   44408             : #ifndef Py_NO_RETURN
   44409             : #define Py_NO_RETURN
   44410             : #endif
   44411           0 : static void __pyx_fatalerror(const char *fmt, ...) Py_NO_RETURN {
   44412           0 :     va_list vargs;
   44413           0 :     char msg[200];
   44414             : #if PY_VERSION_HEX >= 0x030A0000 || defined(HAVE_STDARG_PROTOTYPES)
   44415           0 :     va_start(vargs, fmt);
   44416             : #else
   44417             :     va_start(vargs);
   44418             : #endif
   44419           0 :     vsnprintf(msg, 200, fmt, vargs);
   44420           0 :     va_end(vargs);
   44421           0 :     Py_FatalError(msg);
   44422             : }
   44423             : static CYTHON_INLINE int
   44424             : __pyx_add_acquisition_count_locked(__pyx_atomic_int_type *acquisition_count,
   44425             :                                    PyThread_type_lock lock)
   44426             : {
   44427             :     int result;
   44428             :     PyThread_acquire_lock(lock, 1);
   44429             :     result = (*acquisition_count)++;
   44430             :     PyThread_release_lock(lock);
   44431             :     return result;
   44432             : }
   44433             : static CYTHON_INLINE int
   44434             : __pyx_sub_acquisition_count_locked(__pyx_atomic_int_type *acquisition_count,
   44435             :                                    PyThread_type_lock lock)
   44436             : {
   44437             :     int result;
   44438             :     PyThread_acquire_lock(lock, 1);
   44439             :     result = (*acquisition_count)--;
   44440             :     PyThread_release_lock(lock);
   44441             :     return result;
   44442             : }
   44443             : static CYTHON_INLINE void
   44444           0 : __Pyx_INC_MEMVIEW(__Pyx_memviewslice *memslice, int have_gil, int lineno)
   44445             : {
   44446           0 :     __pyx_nonatomic_int_type old_acquisition_count;
   44447           0 :     struct __pyx_memoryview_obj *memview = memslice->memview;
   44448           0 :     if (unlikely(!memview || (PyObject *) memview == Py_None)) {
   44449             :         return;
   44450             :     }
   44451           0 :     old_acquisition_count = __pyx_add_acquisition_count(memview);
   44452           0 :     if (unlikely(old_acquisition_count <= 0)) {
   44453           0 :         if (likely(old_acquisition_count == 0)) {
   44454           0 :             if (have_gil) {
   44455           0 :                 Py_INCREF((PyObject *) memview);
   44456             :             } else {
   44457           0 :                 PyGILState_STATE _gilstate = PyGILState_Ensure();
   44458           0 :                 Py_INCREF((PyObject *) memview);
   44459           0 :                 PyGILState_Release(_gilstate);
   44460             :             }
   44461             :         } else {
   44462           0 :             __pyx_fatalerror("Acquisition count is %d (line %d)",
   44463             :                              old_acquisition_count+1, lineno);
   44464             :         }
   44465             :     }
   44466             : }
   44467           0 : static CYTHON_INLINE void __Pyx_XCLEAR_MEMVIEW(__Pyx_memviewslice *memslice,
   44468             :                                              int have_gil, int lineno) {
   44469           0 :     __pyx_nonatomic_int_type old_acquisition_count;
   44470           0 :     struct __pyx_memoryview_obj *memview = memslice->memview;
   44471           0 :     if (unlikely(!memview || (PyObject *) memview == Py_None)) {
   44472           0 :         memslice->memview = NULL;
   44473           0 :         return;
   44474             :     }
   44475           0 :     old_acquisition_count = __pyx_sub_acquisition_count(memview);
   44476           0 :     memslice->data = NULL;
   44477           0 :     if (likely(old_acquisition_count > 1)) {
   44478           0 :         memslice->memview = NULL;
   44479           0 :     } else if (likely(old_acquisition_count == 1)) {
   44480           0 :         if (have_gil) {
   44481           0 :             Py_CLEAR(memslice->memview);
   44482             :         } else {
   44483           0 :             PyGILState_STATE _gilstate = PyGILState_Ensure();
   44484           0 :             Py_CLEAR(memslice->memview);
   44485           0 :             PyGILState_Release(_gilstate);
   44486             :         }
   44487             :     } else {
   44488           0 :         __pyx_fatalerror("Acquisition count is %d (line %d)",
   44489             :                          old_acquisition_count-1, lineno);
   44490             :     }
   44491             : }
   44492             : 
   44493             : /* CIntToPy */
   44494         238 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_From_npy_intp(npy_intp value) {
   44495             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44496             : #pragma GCC diagnostic push
   44497             : #pragma GCC diagnostic ignored "-Wconversion"
   44498             : #endif
   44499         238 :     const npy_intp neg_one = (npy_intp) -1, const_zero = (npy_intp) 0;
   44500             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44501             : #pragma GCC diagnostic pop
   44502             : #endif
   44503         238 :     const int is_unsigned = neg_one > const_zero;
   44504         238 :     if (is_unsigned) {
   44505             :         if (sizeof(npy_intp) < sizeof(long)) {
   44506             :             return PyInt_FromLong((long) value);
   44507             :         } else if (sizeof(npy_intp) <= sizeof(unsigned long)) {
   44508             :             return PyLong_FromUnsignedLong((unsigned long) value);
   44509             : #ifdef HAVE_LONG_LONG
   44510             :         } else if (sizeof(npy_intp) <= sizeof(unsigned PY_LONG_LONG)) {
   44511             :             return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
   44512             : #endif
   44513             :         }
   44514             :     } else {
   44515         238 :         if (sizeof(npy_intp) <= sizeof(long)) {
   44516         238 :             return PyInt_FromLong((long) value);
   44517             : #ifdef HAVE_LONG_LONG
   44518             :         } else if (sizeof(npy_intp) <= sizeof(PY_LONG_LONG)) {
   44519             :             return PyLong_FromLongLong((PY_LONG_LONG) value);
   44520             : #endif
   44521             :         }
   44522             :     }
   44523             :     {
   44524             :         unsigned char *bytes = (unsigned char *)&value;
   44525             : #if !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x030d00A4
   44526             :         if (is_unsigned) {
   44527             :             return PyLong_FromUnsignedNativeBytes(bytes, sizeof(value), -1);
   44528             :         } else {
   44529             :             return PyLong_FromNativeBytes(bytes, sizeof(value), -1);
   44530             :         }
   44531             : #elif !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX < 0x030d0000
   44532             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44533             :         return _PyLong_FromByteArray(bytes, sizeof(npy_intp),
   44534             :                                      little, !is_unsigned);
   44535             : #else
   44536             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44537             :         PyObject *from_bytes, *result = NULL;
   44538             :         PyObject *py_bytes = NULL, *arg_tuple = NULL, *kwds = NULL, *order_str = NULL;
   44539             :         from_bytes = PyObject_GetAttrString((PyObject*)&PyLong_Type, "from_bytes");
   44540             :         if (!from_bytes) return NULL;
   44541             :         py_bytes = PyBytes_FromStringAndSize((char*)bytes, sizeof(npy_intp));
   44542             :         if (!py_bytes) goto limited_bad;
   44543             :         order_str = PyUnicode_FromString(little ? "little" : "big");
   44544             :         if (!order_str) goto limited_bad;
   44545             :         arg_tuple = PyTuple_Pack(2, py_bytes, order_str);
   44546             :         if (!arg_tuple) goto limited_bad;
   44547             :         if (!is_unsigned) {
   44548             :             kwds = PyDict_New();
   44549             :             if (!kwds) goto limited_bad;
   44550             :             if (PyDict_SetItemString(kwds, "signed", __Pyx_NewRef(Py_True))) goto limited_bad;
   44551             :         }
   44552             :         result = PyObject_Call(from_bytes, arg_tuple, kwds);
   44553             :         limited_bad:
   44554             :         Py_XDECREF(kwds);
   44555             :         Py_XDECREF(arg_tuple);
   44556             :         Py_XDECREF(order_str);
   44557             :         Py_XDECREF(py_bytes);
   44558             :         Py_XDECREF(from_bytes);
   44559             :         return result;
   44560             : #endif
   44561             :     }
   44562             : }
   44563             : 
   44564             : /* CIntFromPy */
   44565             :   static CYTHON_INLINE npy_intp __Pyx_PyInt_As_npy_intp(PyObject *x) {
   44566             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44567             : #pragma GCC diagnostic push
   44568             : #pragma GCC diagnostic ignored "-Wconversion"
   44569             : #endif
   44570             :     const npy_intp neg_one = (npy_intp) -1, const_zero = (npy_intp) 0;
   44571             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44572             : #pragma GCC diagnostic pop
   44573             : #endif
   44574             :     const int is_unsigned = neg_one > const_zero;
   44575             : #if PY_MAJOR_VERSION < 3
   44576             :     if (likely(PyInt_Check(x))) {
   44577             :         if ((sizeof(npy_intp) < sizeof(long))) {
   44578             :             __PYX_VERIFY_RETURN_INT(npy_intp, long, PyInt_AS_LONG(x))
   44579             :         } else {
   44580             :             long val = PyInt_AS_LONG(x);
   44581             :             if (is_unsigned && unlikely(val < 0)) {
   44582             :                 goto raise_neg_overflow;
   44583             :             }
   44584             :             return (npy_intp) val;
   44585             :         }
   44586             :     }
   44587             : #endif
   44588             :     if (unlikely(!PyLong_Check(x))) {
   44589             :         npy_intp val;
   44590             :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   44591             :         if (!tmp) return (npy_intp) -1;
   44592             :         val = __Pyx_PyInt_As_npy_intp(tmp);
   44593             :         Py_DECREF(tmp);
   44594             :         return val;
   44595             :     }
   44596             :     if (is_unsigned) {
   44597             : #if CYTHON_USE_PYLONG_INTERNALS
   44598             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   44599             :             goto raise_neg_overflow;
   44600             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   44601             :             __PYX_VERIFY_RETURN_INT(npy_intp, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   44602             :         } else {
   44603             :             const digit* digits = __Pyx_PyLong_Digits(x);
   44604             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   44605             :             switch (__Pyx_PyLong_DigitCount(x)) {
   44606             :                 case 2:
   44607             :                     if ((8 * sizeof(npy_intp) > 1 * PyLong_SHIFT)) {
   44608             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   44609             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44610             :                         } else if ((8 * sizeof(npy_intp) >= 2 * PyLong_SHIFT)) {
   44611             :                             return (npy_intp) (((((npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0]));
   44612             :                         }
   44613             :                     }
   44614             :                     break;
   44615             :                 case 3:
   44616             :                     if ((8 * sizeof(npy_intp) > 2 * PyLong_SHIFT)) {
   44617             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   44618             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44619             :                         } else if ((8 * sizeof(npy_intp) >= 3 * PyLong_SHIFT)) {
   44620             :                             return (npy_intp) (((((((npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0]));
   44621             :                         }
   44622             :                     }
   44623             :                     break;
   44624             :                 case 4:
   44625             :                     if ((8 * sizeof(npy_intp) > 3 * PyLong_SHIFT)) {
   44626             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   44627             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44628             :                         } else if ((8 * sizeof(npy_intp) >= 4 * PyLong_SHIFT)) {
   44629             :                             return (npy_intp) (((((((((npy_intp)digits[3]) << PyLong_SHIFT) | (npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0]));
   44630             :                         }
   44631             :                     }
   44632             :                     break;
   44633             :             }
   44634             :         }
   44635             : #endif
   44636             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   44637             :         if (unlikely(Py_SIZE(x) < 0)) {
   44638             :             goto raise_neg_overflow;
   44639             :         }
   44640             : #else
   44641             :         {
   44642             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   44643             :             if (unlikely(result < 0))
   44644             :                 return (npy_intp) -1;
   44645             :             if (unlikely(result == 1))
   44646             :                 goto raise_neg_overflow;
   44647             :         }
   44648             : #endif
   44649             :         if ((sizeof(npy_intp) <= sizeof(unsigned long))) {
   44650             :             __PYX_VERIFY_RETURN_INT_EXC(npy_intp, unsigned long, PyLong_AsUnsignedLong(x))
   44651             : #ifdef HAVE_LONG_LONG
   44652             :         } else if ((sizeof(npy_intp) <= sizeof(unsigned PY_LONG_LONG))) {
   44653             :             __PYX_VERIFY_RETURN_INT_EXC(npy_intp, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   44654             : #endif
   44655             :         }
   44656             :     } else {
   44657             : #if CYTHON_USE_PYLONG_INTERNALS
   44658             :         if (__Pyx_PyLong_IsCompact(x)) {
   44659             :             __PYX_VERIFY_RETURN_INT(npy_intp, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   44660             :         } else {
   44661             :             const digit* digits = __Pyx_PyLong_Digits(x);
   44662             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   44663             :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   44664             :                 case -2:
   44665             :                     if ((8 * sizeof(npy_intp) - 1 > 1 * PyLong_SHIFT)) {
   44666             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   44667             :                             __PYX_VERIFY_RETURN_INT(npy_intp, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44668             :                         } else if ((8 * sizeof(npy_intp) - 1 > 2 * PyLong_SHIFT)) {
   44669             :                             return (npy_intp) (((npy_intp)-1)*(((((npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44670             :                         }
   44671             :                     }
   44672             :                     break;
   44673             :                 case 2:
   44674             :                     if ((8 * sizeof(npy_intp) > 1 * PyLong_SHIFT)) {
   44675             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   44676             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44677             :                         } else if ((8 * sizeof(npy_intp) - 1 > 2 * PyLong_SHIFT)) {
   44678             :                             return (npy_intp) ((((((npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44679             :                         }
   44680             :                     }
   44681             :                     break;
   44682             :                 case -3:
   44683             :                     if ((8 * sizeof(npy_intp) - 1 > 2 * PyLong_SHIFT)) {
   44684             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   44685             :                             __PYX_VERIFY_RETURN_INT(npy_intp, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44686             :                         } else if ((8 * sizeof(npy_intp) - 1 > 3 * PyLong_SHIFT)) {
   44687             :                             return (npy_intp) (((npy_intp)-1)*(((((((npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44688             :                         }
   44689             :                     }
   44690             :                     break;
   44691             :                 case 3:
   44692             :                     if ((8 * sizeof(npy_intp) > 2 * PyLong_SHIFT)) {
   44693             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   44694             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44695             :                         } else if ((8 * sizeof(npy_intp) - 1 > 3 * PyLong_SHIFT)) {
   44696             :                             return (npy_intp) ((((((((npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44697             :                         }
   44698             :                     }
   44699             :                     break;
   44700             :                 case -4:
   44701             :                     if ((8 * sizeof(npy_intp) - 1 > 3 * PyLong_SHIFT)) {
   44702             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   44703             :                             __PYX_VERIFY_RETURN_INT(npy_intp, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44704             :                         } else if ((8 * sizeof(npy_intp) - 1 > 4 * PyLong_SHIFT)) {
   44705             :                             return (npy_intp) (((npy_intp)-1)*(((((((((npy_intp)digits[3]) << PyLong_SHIFT) | (npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44706             :                         }
   44707             :                     }
   44708             :                     break;
   44709             :                 case 4:
   44710             :                     if ((8 * sizeof(npy_intp) > 3 * PyLong_SHIFT)) {
   44711             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   44712             :                             __PYX_VERIFY_RETURN_INT(npy_intp, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   44713             :                         } else if ((8 * sizeof(npy_intp) - 1 > 4 * PyLong_SHIFT)) {
   44714             :                             return (npy_intp) ((((((((((npy_intp)digits[3]) << PyLong_SHIFT) | (npy_intp)digits[2]) << PyLong_SHIFT) | (npy_intp)digits[1]) << PyLong_SHIFT) | (npy_intp)digits[0])));
   44715             :                         }
   44716             :                     }
   44717             :                     break;
   44718             :             }
   44719             :         }
   44720             : #endif
   44721             :         if ((sizeof(npy_intp) <= sizeof(long))) {
   44722             :             __PYX_VERIFY_RETURN_INT_EXC(npy_intp, long, PyLong_AsLong(x))
   44723             : #ifdef HAVE_LONG_LONG
   44724             :         } else if ((sizeof(npy_intp) <= sizeof(PY_LONG_LONG))) {
   44725             :             __PYX_VERIFY_RETURN_INT_EXC(npy_intp, PY_LONG_LONG, PyLong_AsLongLong(x))
   44726             : #endif
   44727             :         }
   44728             :     }
   44729             :     {
   44730             :         npy_intp val;
   44731             :         int ret = -1;
   44732             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   44733             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   44734             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   44735             :         if (unlikely(bytes_copied == -1)) {
   44736             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   44737             :             goto raise_overflow;
   44738             :         } else {
   44739             :             ret = 0;
   44740             :         }
   44741             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   44742             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   44743             :         unsigned char *bytes = (unsigned char *)&val;
   44744             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   44745             :                                     bytes, sizeof(val),
   44746             :                                     is_little, !is_unsigned);
   44747             : #else
   44748             :         PyObject *v;
   44749             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   44750             :         int bits, remaining_bits, is_negative = 0;
   44751             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   44752             :         if (likely(PyLong_CheckExact(x))) {
   44753             :             v = __Pyx_NewRef(x);
   44754             :         } else {
   44755             :             v = PyNumber_Long(x);
   44756             :             if (unlikely(!v)) return (npy_intp) -1;
   44757             :             assert(PyLong_CheckExact(v));
   44758             :         }
   44759             :         {
   44760             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   44761             :             if (unlikely(result < 0)) {
   44762             :                 Py_DECREF(v);
   44763             :                 return (npy_intp) -1;
   44764             :             }
   44765             :             is_negative = result == 1;
   44766             :         }
   44767             :         if (is_unsigned && unlikely(is_negative)) {
   44768             :             Py_DECREF(v);
   44769             :             goto raise_neg_overflow;
   44770             :         } else if (is_negative) {
   44771             :             stepval = PyNumber_Invert(v);
   44772             :             Py_DECREF(v);
   44773             :             if (unlikely(!stepval))
   44774             :                 return (npy_intp) -1;
   44775             :         } else {
   44776             :             stepval = v;
   44777             :         }
   44778             :         v = NULL;
   44779             :         val = (npy_intp) 0;
   44780             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   44781             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   44782             :         for (bits = 0; bits < (int) sizeof(npy_intp) * 8 - chunk_size; bits += chunk_size) {
   44783             :             PyObject *tmp, *digit;
   44784             :             long idigit;
   44785             :             digit = PyNumber_And(stepval, mask);
   44786             :             if (unlikely(!digit)) goto done;
   44787             :             idigit = PyLong_AsLong(digit);
   44788             :             Py_DECREF(digit);
   44789             :             if (unlikely(idigit < 0)) goto done;
   44790             :             val |= ((npy_intp) idigit) << bits;
   44791             :             tmp = PyNumber_Rshift(stepval, shift);
   44792             :             if (unlikely(!tmp)) goto done;
   44793             :             Py_DECREF(stepval); stepval = tmp;
   44794             :         }
   44795             :         Py_DECREF(shift); shift = NULL;
   44796             :         Py_DECREF(mask); mask = NULL;
   44797             :         {
   44798             :             long idigit = PyLong_AsLong(stepval);
   44799             :             if (unlikely(idigit < 0)) goto done;
   44800             :             remaining_bits = ((int) sizeof(npy_intp) * 8) - bits - (is_unsigned ? 0 : 1);
   44801             :             if (unlikely(idigit >= (1L << remaining_bits)))
   44802             :                 goto raise_overflow;
   44803             :             val |= ((npy_intp) idigit) << bits;
   44804             :         }
   44805             :         if (!is_unsigned) {
   44806             :             if (unlikely(val & (((npy_intp) 1) << (sizeof(npy_intp) * 8 - 1))))
   44807             :                 goto raise_overflow;
   44808             :             if (is_negative)
   44809             :                 val = ~val;
   44810             :         }
   44811             :         ret = 0;
   44812             :     done:
   44813             :         Py_XDECREF(shift);
   44814             :         Py_XDECREF(mask);
   44815             :         Py_XDECREF(stepval);
   44816             : #endif
   44817             :         if (unlikely(ret))
   44818             :             return (npy_intp) -1;
   44819             :         return val;
   44820             :     }
   44821             : raise_overflow:
   44822             :     PyErr_SetString(PyExc_OverflowError,
   44823             :         "value too large to convert to npy_intp");
   44824             :     return (npy_intp) -1;
   44825             : raise_neg_overflow:
   44826             :     PyErr_SetString(PyExc_OverflowError,
   44827             :         "can't convert negative value to npy_intp");
   44828             :     return (npy_intp) -1;
   44829             : }
   44830             : 
   44831             : /* CIntToPy */
   44832           0 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
   44833             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44834             : #pragma GCC diagnostic push
   44835             : #pragma GCC diagnostic ignored "-Wconversion"
   44836             : #endif
   44837           0 :     const long neg_one = (long) -1, const_zero = (long) 0;
   44838             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44839             : #pragma GCC diagnostic pop
   44840             : #endif
   44841           0 :     const int is_unsigned = neg_one > const_zero;
   44842           0 :     if (is_unsigned) {
   44843             :         if (sizeof(long) < sizeof(long)) {
   44844             :             return PyInt_FromLong((long) value);
   44845             :         } else if (sizeof(long) <= sizeof(unsigned long)) {
   44846             :             return PyLong_FromUnsignedLong((unsigned long) value);
   44847             : #ifdef HAVE_LONG_LONG
   44848             :         } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
   44849             :             return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
   44850             : #endif
   44851             :         }
   44852             :     } else {
   44853           0 :         if (sizeof(long) <= sizeof(long)) {
   44854           0 :             return PyInt_FromLong((long) value);
   44855             : #ifdef HAVE_LONG_LONG
   44856             :         } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
   44857             :             return PyLong_FromLongLong((PY_LONG_LONG) value);
   44858             : #endif
   44859             :         }
   44860             :     }
   44861             :     {
   44862             :         unsigned char *bytes = (unsigned char *)&value;
   44863             : #if !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x030d00A4
   44864             :         if (is_unsigned) {
   44865             :             return PyLong_FromUnsignedNativeBytes(bytes, sizeof(value), -1);
   44866             :         } else {
   44867             :             return PyLong_FromNativeBytes(bytes, sizeof(value), -1);
   44868             :         }
   44869             : #elif !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX < 0x030d0000
   44870             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44871             :         return _PyLong_FromByteArray(bytes, sizeof(long),
   44872             :                                      little, !is_unsigned);
   44873             : #else
   44874             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44875             :         PyObject *from_bytes, *result = NULL;
   44876             :         PyObject *py_bytes = NULL, *arg_tuple = NULL, *kwds = NULL, *order_str = NULL;
   44877             :         from_bytes = PyObject_GetAttrString((PyObject*)&PyLong_Type, "from_bytes");
   44878             :         if (!from_bytes) return NULL;
   44879             :         py_bytes = PyBytes_FromStringAndSize((char*)bytes, sizeof(long));
   44880             :         if (!py_bytes) goto limited_bad;
   44881             :         order_str = PyUnicode_FromString(little ? "little" : "big");
   44882             :         if (!order_str) goto limited_bad;
   44883             :         arg_tuple = PyTuple_Pack(2, py_bytes, order_str);
   44884             :         if (!arg_tuple) goto limited_bad;
   44885             :         if (!is_unsigned) {
   44886             :             kwds = PyDict_New();
   44887             :             if (!kwds) goto limited_bad;
   44888             :             if (PyDict_SetItemString(kwds, "signed", __Pyx_NewRef(Py_True))) goto limited_bad;
   44889             :         }
   44890             :         result = PyObject_Call(from_bytes, arg_tuple, kwds);
   44891             :         limited_bad:
   44892             :         Py_XDECREF(kwds);
   44893             :         Py_XDECREF(arg_tuple);
   44894             :         Py_XDECREF(order_str);
   44895             :         Py_XDECREF(py_bytes);
   44896             :         Py_XDECREF(from_bytes);
   44897             :         return result;
   44898             : #endif
   44899             :     }
   44900             : }
   44901             : 
   44902             : /* CIntToPy */
   44903         357 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_From_Py_intptr_t(Py_intptr_t value) {
   44904             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44905             : #pragma GCC diagnostic push
   44906             : #pragma GCC diagnostic ignored "-Wconversion"
   44907             : #endif
   44908         357 :     const Py_intptr_t neg_one = (Py_intptr_t) -1, const_zero = (Py_intptr_t) 0;
   44909             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44910             : #pragma GCC diagnostic pop
   44911             : #endif
   44912         357 :     const int is_unsigned = neg_one > const_zero;
   44913         357 :     if (is_unsigned) {
   44914             :         if (sizeof(Py_intptr_t) < sizeof(long)) {
   44915             :             return PyInt_FromLong((long) value);
   44916             :         } else if (sizeof(Py_intptr_t) <= sizeof(unsigned long)) {
   44917             :             return PyLong_FromUnsignedLong((unsigned long) value);
   44918             : #ifdef HAVE_LONG_LONG
   44919             :         } else if (sizeof(Py_intptr_t) <= sizeof(unsigned PY_LONG_LONG)) {
   44920             :             return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
   44921             : #endif
   44922             :         }
   44923             :     } else {
   44924         357 :         if (sizeof(Py_intptr_t) <= sizeof(long)) {
   44925         357 :             return PyInt_FromLong((long) value);
   44926             : #ifdef HAVE_LONG_LONG
   44927             :         } else if (sizeof(Py_intptr_t) <= sizeof(PY_LONG_LONG)) {
   44928             :             return PyLong_FromLongLong((PY_LONG_LONG) value);
   44929             : #endif
   44930             :         }
   44931             :     }
   44932             :     {
   44933             :         unsigned char *bytes = (unsigned char *)&value;
   44934             : #if !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x030d00A4
   44935             :         if (is_unsigned) {
   44936             :             return PyLong_FromUnsignedNativeBytes(bytes, sizeof(value), -1);
   44937             :         } else {
   44938             :             return PyLong_FromNativeBytes(bytes, sizeof(value), -1);
   44939             :         }
   44940             : #elif !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX < 0x030d0000
   44941             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44942             :         return _PyLong_FromByteArray(bytes, sizeof(Py_intptr_t),
   44943             :                                      little, !is_unsigned);
   44944             : #else
   44945             :         int one = 1; int little = (int)*(unsigned char *)&one;
   44946             :         PyObject *from_bytes, *result = NULL;
   44947             :         PyObject *py_bytes = NULL, *arg_tuple = NULL, *kwds = NULL, *order_str = NULL;
   44948             :         from_bytes = PyObject_GetAttrString((PyObject*)&PyLong_Type, "from_bytes");
   44949             :         if (!from_bytes) return NULL;
   44950             :         py_bytes = PyBytes_FromStringAndSize((char*)bytes, sizeof(Py_intptr_t));
   44951             :         if (!py_bytes) goto limited_bad;
   44952             :         order_str = PyUnicode_FromString(little ? "little" : "big");
   44953             :         if (!order_str) goto limited_bad;
   44954             :         arg_tuple = PyTuple_Pack(2, py_bytes, order_str);
   44955             :         if (!arg_tuple) goto limited_bad;
   44956             :         if (!is_unsigned) {
   44957             :             kwds = PyDict_New();
   44958             :             if (!kwds) goto limited_bad;
   44959             :             if (PyDict_SetItemString(kwds, "signed", __Pyx_NewRef(Py_True))) goto limited_bad;
   44960             :         }
   44961             :         result = PyObject_Call(from_bytes, arg_tuple, kwds);
   44962             :         limited_bad:
   44963             :         Py_XDECREF(kwds);
   44964             :         Py_XDECREF(arg_tuple);
   44965             :         Py_XDECREF(order_str);
   44966             :         Py_XDECREF(py_bytes);
   44967             :         Py_XDECREF(from_bytes);
   44968             :         return result;
   44969             : #endif
   44970             :     }
   44971             : }
   44972             : 
   44973             : /* CIntToPy */
   44974           0 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) {
   44975             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44976             : #pragma GCC diagnostic push
   44977             : #pragma GCC diagnostic ignored "-Wconversion"
   44978             : #endif
   44979           0 :     const int neg_one = (int) -1, const_zero = (int) 0;
   44980             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   44981             : #pragma GCC diagnostic pop
   44982             : #endif
   44983           0 :     const int is_unsigned = neg_one > const_zero;
   44984           0 :     if (is_unsigned) {
   44985             :         if (sizeof(int) < sizeof(long)) {
   44986             :             return PyInt_FromLong((long) value);
   44987             :         } else if (sizeof(int) <= sizeof(unsigned long)) {
   44988             :             return PyLong_FromUnsignedLong((unsigned long) value);
   44989             : #ifdef HAVE_LONG_LONG
   44990             :         } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
   44991             :             return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
   44992             : #endif
   44993             :         }
   44994             :     } else {
   44995           0 :         if (sizeof(int) <= sizeof(long)) {
   44996           0 :             return PyInt_FromLong((long) value);
   44997             : #ifdef HAVE_LONG_LONG
   44998             :         } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
   44999             :             return PyLong_FromLongLong((PY_LONG_LONG) value);
   45000             : #endif
   45001             :         }
   45002             :     }
   45003             :     {
   45004             :         unsigned char *bytes = (unsigned char *)&value;
   45005             : #if !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x030d00A4
   45006             :         if (is_unsigned) {
   45007             :             return PyLong_FromUnsignedNativeBytes(bytes, sizeof(value), -1);
   45008             :         } else {
   45009             :             return PyLong_FromNativeBytes(bytes, sizeof(value), -1);
   45010             :         }
   45011             : #elif !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX < 0x030d0000
   45012             :         int one = 1; int little = (int)*(unsigned char *)&one;
   45013             :         return _PyLong_FromByteArray(bytes, sizeof(int),
   45014             :                                      little, !is_unsigned);
   45015             : #else
   45016             :         int one = 1; int little = (int)*(unsigned char *)&one;
   45017             :         PyObject *from_bytes, *result = NULL;
   45018             :         PyObject *py_bytes = NULL, *arg_tuple = NULL, *kwds = NULL, *order_str = NULL;
   45019             :         from_bytes = PyObject_GetAttrString((PyObject*)&PyLong_Type, "from_bytes");
   45020             :         if (!from_bytes) return NULL;
   45021             :         py_bytes = PyBytes_FromStringAndSize((char*)bytes, sizeof(int));
   45022             :         if (!py_bytes) goto limited_bad;
   45023             :         order_str = PyUnicode_FromString(little ? "little" : "big");
   45024             :         if (!order_str) goto limited_bad;
   45025             :         arg_tuple = PyTuple_Pack(2, py_bytes, order_str);
   45026             :         if (!arg_tuple) goto limited_bad;
   45027             :         if (!is_unsigned) {
   45028             :             kwds = PyDict_New();
   45029             :             if (!kwds) goto limited_bad;
   45030             :             if (PyDict_SetItemString(kwds, "signed", __Pyx_NewRef(Py_True))) goto limited_bad;
   45031             :         }
   45032             :         result = PyObject_Call(from_bytes, arg_tuple, kwds);
   45033             :         limited_bad:
   45034             :         Py_XDECREF(kwds);
   45035             :         Py_XDECREF(arg_tuple);
   45036             :         Py_XDECREF(order_str);
   45037             :         Py_XDECREF(py_bytes);
   45038             :         Py_XDECREF(from_bytes);
   45039             :         return result;
   45040             : #endif
   45041             :     }
   45042             : }
   45043             : 
   45044             : /* CIntFromPy */
   45045         357 :   static CYTHON_INLINE Py_intptr_t __Pyx_PyInt_As_Py_intptr_t(PyObject *x) {
   45046             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45047             : #pragma GCC diagnostic push
   45048             : #pragma GCC diagnostic ignored "-Wconversion"
   45049             : #endif
   45050         357 :     const Py_intptr_t neg_one = (Py_intptr_t) -1, const_zero = (Py_intptr_t) 0;
   45051             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45052             : #pragma GCC diagnostic pop
   45053             : #endif
   45054         357 :     const int is_unsigned = neg_one > const_zero;
   45055             : #if PY_MAJOR_VERSION < 3
   45056             :     if (likely(PyInt_Check(x))) {
   45057             :         if ((sizeof(Py_intptr_t) < sizeof(long))) {
   45058             :             __PYX_VERIFY_RETURN_INT(Py_intptr_t, long, PyInt_AS_LONG(x))
   45059             :         } else {
   45060             :             long val = PyInt_AS_LONG(x);
   45061             :             if (is_unsigned && unlikely(val < 0)) {
   45062             :                 goto raise_neg_overflow;
   45063             :             }
   45064             :             return (Py_intptr_t) val;
   45065             :         }
   45066             :     }
   45067             : #endif
   45068         357 :     if (unlikely(!PyLong_Check(x))) {
   45069           0 :         Py_intptr_t val;
   45070           0 :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   45071           0 :         if (!tmp) return (Py_intptr_t) -1;
   45072           0 :         val = __Pyx_PyInt_As_Py_intptr_t(tmp);
   45073           0 :         Py_DECREF(tmp);
   45074           0 :         return val;
   45075             :     }
   45076         357 :     if (is_unsigned) {
   45077             : #if CYTHON_USE_PYLONG_INTERNALS
   45078             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   45079             :             goto raise_neg_overflow;
   45080             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   45081             :             __PYX_VERIFY_RETURN_INT(Py_intptr_t, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   45082             :         } else {
   45083             :             const digit* digits = __Pyx_PyLong_Digits(x);
   45084             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45085             :             switch (__Pyx_PyLong_DigitCount(x)) {
   45086             :                 case 2:
   45087             :                     if ((8 * sizeof(Py_intptr_t) > 1 * PyLong_SHIFT)) {
   45088             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45089             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45090             :                         } else if ((8 * sizeof(Py_intptr_t) >= 2 * PyLong_SHIFT)) {
   45091             :                             return (Py_intptr_t) (((((Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0]));
   45092             :                         }
   45093             :                     }
   45094             :                     break;
   45095             :                 case 3:
   45096             :                     if ((8 * sizeof(Py_intptr_t) > 2 * PyLong_SHIFT)) {
   45097             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45098             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45099             :                         } else if ((8 * sizeof(Py_intptr_t) >= 3 * PyLong_SHIFT)) {
   45100             :                             return (Py_intptr_t) (((((((Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0]));
   45101             :                         }
   45102             :                     }
   45103             :                     break;
   45104             :                 case 4:
   45105             :                     if ((8 * sizeof(Py_intptr_t) > 3 * PyLong_SHIFT)) {
   45106             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45107             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45108             :                         } else if ((8 * sizeof(Py_intptr_t) >= 4 * PyLong_SHIFT)) {
   45109             :                             return (Py_intptr_t) (((((((((Py_intptr_t)digits[3]) << PyLong_SHIFT) | (Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0]));
   45110             :                         }
   45111             :                     }
   45112             :                     break;
   45113             :             }
   45114             :         }
   45115             : #endif
   45116             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   45117             :         if (unlikely(Py_SIZE(x) < 0)) {
   45118             :             goto raise_neg_overflow;
   45119             :         }
   45120             : #else
   45121             :         {
   45122             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   45123             :             if (unlikely(result < 0))
   45124             :                 return (Py_intptr_t) -1;
   45125             :             if (unlikely(result == 1))
   45126             :                 goto raise_neg_overflow;
   45127             :         }
   45128             : #endif
   45129             :         if ((sizeof(Py_intptr_t) <= sizeof(unsigned long))) {
   45130             :             __PYX_VERIFY_RETURN_INT_EXC(Py_intptr_t, unsigned long, PyLong_AsUnsignedLong(x))
   45131             : #ifdef HAVE_LONG_LONG
   45132             :         } else if ((sizeof(Py_intptr_t) <= sizeof(unsigned PY_LONG_LONG))) {
   45133             :             __PYX_VERIFY_RETURN_INT_EXC(Py_intptr_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   45134             : #endif
   45135             :         }
   45136             :     } else {
   45137             : #if CYTHON_USE_PYLONG_INTERNALS
   45138         357 :         if (__Pyx_PyLong_IsCompact(x)) {
   45139           0 :             __PYX_VERIFY_RETURN_INT(Py_intptr_t, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   45140             :         } else {
   45141         357 :             const digit* digits = __Pyx_PyLong_Digits(x);
   45142         357 :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45143         357 :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   45144             :                 case -2:
   45145           0 :                     if ((8 * sizeof(Py_intptr_t) - 1 > 1 * PyLong_SHIFT)) {
   45146           0 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45147           0 :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45148             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 2 * PyLong_SHIFT)) {
   45149             :                             return (Py_intptr_t) (((Py_intptr_t)-1)*(((((Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45150             :                         }
   45151             :                     }
   45152             :                     break;
   45153             :                 case 2:
   45154         357 :                     if ((8 * sizeof(Py_intptr_t) > 1 * PyLong_SHIFT)) {
   45155         357 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45156         357 :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45157             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 2 * PyLong_SHIFT)) {
   45158             :                             return (Py_intptr_t) ((((((Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45159             :                         }
   45160             :                     }
   45161             :                     break;
   45162             :                 case -3:
   45163             :                     if ((8 * sizeof(Py_intptr_t) - 1 > 2 * PyLong_SHIFT)) {
   45164             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45165             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45166             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 3 * PyLong_SHIFT)) {
   45167             :                             return (Py_intptr_t) (((Py_intptr_t)-1)*(((((((Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45168             :                         }
   45169             :                     }
   45170             :                     break;
   45171             :                 case 3:
   45172             :                     if ((8 * sizeof(Py_intptr_t) > 2 * PyLong_SHIFT)) {
   45173             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45174             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45175             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 3 * PyLong_SHIFT)) {
   45176             :                             return (Py_intptr_t) ((((((((Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45177             :                         }
   45178             :                     }
   45179             :                     break;
   45180             :                 case -4:
   45181             :                     if ((8 * sizeof(Py_intptr_t) - 1 > 3 * PyLong_SHIFT)) {
   45182             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45183             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45184             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 4 * PyLong_SHIFT)) {
   45185             :                             return (Py_intptr_t) (((Py_intptr_t)-1)*(((((((((Py_intptr_t)digits[3]) << PyLong_SHIFT) | (Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45186             :                         }
   45187             :                     }
   45188             :                     break;
   45189             :                 case 4:
   45190             :                     if ((8 * sizeof(Py_intptr_t) > 3 * PyLong_SHIFT)) {
   45191             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45192             :                             __PYX_VERIFY_RETURN_INT(Py_intptr_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45193             :                         } else if ((8 * sizeof(Py_intptr_t) - 1 > 4 * PyLong_SHIFT)) {
   45194             :                             return (Py_intptr_t) ((((((((((Py_intptr_t)digits[3]) << PyLong_SHIFT) | (Py_intptr_t)digits[2]) << PyLong_SHIFT) | (Py_intptr_t)digits[1]) << PyLong_SHIFT) | (Py_intptr_t)digits[0])));
   45195             :                         }
   45196             :                     }
   45197             :                     break;
   45198             :             }
   45199             :         }
   45200             : #endif
   45201           0 :         if ((sizeof(Py_intptr_t) <= sizeof(long))) {
   45202           0 :             __PYX_VERIFY_RETURN_INT_EXC(Py_intptr_t, long, PyLong_AsLong(x))
   45203             : #ifdef HAVE_LONG_LONG
   45204             :         } else if ((sizeof(Py_intptr_t) <= sizeof(PY_LONG_LONG))) {
   45205             :             __PYX_VERIFY_RETURN_INT_EXC(Py_intptr_t, PY_LONG_LONG, PyLong_AsLongLong(x))
   45206             : #endif
   45207             :         }
   45208             :     }
   45209             :     {
   45210             :         Py_intptr_t val;
   45211             :         int ret = -1;
   45212             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   45213             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   45214             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   45215             :         if (unlikely(bytes_copied == -1)) {
   45216             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   45217             :             goto raise_overflow;
   45218             :         } else {
   45219             :             ret = 0;
   45220             :         }
   45221             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   45222             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   45223             :         unsigned char *bytes = (unsigned char *)&val;
   45224             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   45225             :                                     bytes, sizeof(val),
   45226             :                                     is_little, !is_unsigned);
   45227             : #else
   45228             :         PyObject *v;
   45229             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   45230             :         int bits, remaining_bits, is_negative = 0;
   45231             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   45232             :         if (likely(PyLong_CheckExact(x))) {
   45233             :             v = __Pyx_NewRef(x);
   45234             :         } else {
   45235             :             v = PyNumber_Long(x);
   45236             :             if (unlikely(!v)) return (Py_intptr_t) -1;
   45237             :             assert(PyLong_CheckExact(v));
   45238             :         }
   45239             :         {
   45240             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   45241             :             if (unlikely(result < 0)) {
   45242             :                 Py_DECREF(v);
   45243             :                 return (Py_intptr_t) -1;
   45244             :             }
   45245             :             is_negative = result == 1;
   45246             :         }
   45247             :         if (is_unsigned && unlikely(is_negative)) {
   45248             :             Py_DECREF(v);
   45249             :             goto raise_neg_overflow;
   45250             :         } else if (is_negative) {
   45251             :             stepval = PyNumber_Invert(v);
   45252             :             Py_DECREF(v);
   45253             :             if (unlikely(!stepval))
   45254             :                 return (Py_intptr_t) -1;
   45255             :         } else {
   45256             :             stepval = v;
   45257             :         }
   45258             :         v = NULL;
   45259             :         val = (Py_intptr_t) 0;
   45260             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   45261             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   45262             :         for (bits = 0; bits < (int) sizeof(Py_intptr_t) * 8 - chunk_size; bits += chunk_size) {
   45263             :             PyObject *tmp, *digit;
   45264             :             long idigit;
   45265             :             digit = PyNumber_And(stepval, mask);
   45266             :             if (unlikely(!digit)) goto done;
   45267             :             idigit = PyLong_AsLong(digit);
   45268             :             Py_DECREF(digit);
   45269             :             if (unlikely(idigit < 0)) goto done;
   45270             :             val |= ((Py_intptr_t) idigit) << bits;
   45271             :             tmp = PyNumber_Rshift(stepval, shift);
   45272             :             if (unlikely(!tmp)) goto done;
   45273             :             Py_DECREF(stepval); stepval = tmp;
   45274             :         }
   45275             :         Py_DECREF(shift); shift = NULL;
   45276             :         Py_DECREF(mask); mask = NULL;
   45277             :         {
   45278             :             long idigit = PyLong_AsLong(stepval);
   45279             :             if (unlikely(idigit < 0)) goto done;
   45280             :             remaining_bits = ((int) sizeof(Py_intptr_t) * 8) - bits - (is_unsigned ? 0 : 1);
   45281             :             if (unlikely(idigit >= (1L << remaining_bits)))
   45282             :                 goto raise_overflow;
   45283             :             val |= ((Py_intptr_t) idigit) << bits;
   45284             :         }
   45285             :         if (!is_unsigned) {
   45286             :             if (unlikely(val & (((Py_intptr_t) 1) << (sizeof(Py_intptr_t) * 8 - 1))))
   45287             :                 goto raise_overflow;
   45288             :             if (is_negative)
   45289             :                 val = ~val;
   45290             :         }
   45291             :         ret = 0;
   45292             :     done:
   45293             :         Py_XDECREF(shift);
   45294             :         Py_XDECREF(mask);
   45295             :         Py_XDECREF(stepval);
   45296             : #endif
   45297             :         if (unlikely(ret))
   45298             :             return (Py_intptr_t) -1;
   45299             :         return val;
   45300             :     }
   45301             : raise_overflow:
   45302             :     PyErr_SetString(PyExc_OverflowError,
   45303             :         "value too large to convert to Py_intptr_t");
   45304             :     return (Py_intptr_t) -1;
   45305             : raise_neg_overflow:
   45306             :     PyErr_SetString(PyExc_OverflowError,
   45307             :         "can't convert negative value to Py_intptr_t");
   45308             :     return (Py_intptr_t) -1;
   45309             : }
   45310             : 
   45311             : /* CIntFromPy */
   45312           0 :   static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
   45313             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45314             : #pragma GCC diagnostic push
   45315             : #pragma GCC diagnostic ignored "-Wconversion"
   45316             : #endif
   45317           0 :     const int neg_one = (int) -1, const_zero = (int) 0;
   45318             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45319             : #pragma GCC diagnostic pop
   45320             : #endif
   45321           0 :     const int is_unsigned = neg_one > const_zero;
   45322             : #if PY_MAJOR_VERSION < 3
   45323             :     if (likely(PyInt_Check(x))) {
   45324             :         if ((sizeof(int) < sizeof(long))) {
   45325             :             __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
   45326             :         } else {
   45327             :             long val = PyInt_AS_LONG(x);
   45328             :             if (is_unsigned && unlikely(val < 0)) {
   45329             :                 goto raise_neg_overflow;
   45330             :             }
   45331             :             return (int) val;
   45332             :         }
   45333             :     }
   45334             : #endif
   45335           0 :     if (unlikely(!PyLong_Check(x))) {
   45336           0 :         int val;
   45337           0 :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   45338           0 :         if (!tmp) return (int) -1;
   45339           0 :         val = __Pyx_PyInt_As_int(tmp);
   45340           0 :         Py_DECREF(tmp);
   45341           0 :         return val;
   45342             :     }
   45343           0 :     if (is_unsigned) {
   45344             : #if CYTHON_USE_PYLONG_INTERNALS
   45345             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   45346             :             goto raise_neg_overflow;
   45347             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   45348             :             __PYX_VERIFY_RETURN_INT(int, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   45349             :         } else {
   45350             :             const digit* digits = __Pyx_PyLong_Digits(x);
   45351             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45352             :             switch (__Pyx_PyLong_DigitCount(x)) {
   45353             :                 case 2:
   45354             :                     if ((8 * sizeof(int) > 1 * PyLong_SHIFT)) {
   45355             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45356             :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45357             :                         } else if ((8 * sizeof(int) >= 2 * PyLong_SHIFT)) {
   45358             :                             return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
   45359             :                         }
   45360             :                     }
   45361             :                     break;
   45362             :                 case 3:
   45363             :                     if ((8 * sizeof(int) > 2 * PyLong_SHIFT)) {
   45364             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45365             :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45366             :                         } else if ((8 * sizeof(int) >= 3 * PyLong_SHIFT)) {
   45367             :                             return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
   45368             :                         }
   45369             :                     }
   45370             :                     break;
   45371             :                 case 4:
   45372             :                     if ((8 * sizeof(int) > 3 * PyLong_SHIFT)) {
   45373             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45374             :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45375             :                         } else if ((8 * sizeof(int) >= 4 * PyLong_SHIFT)) {
   45376             :                             return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
   45377             :                         }
   45378             :                     }
   45379             :                     break;
   45380             :             }
   45381             :         }
   45382             : #endif
   45383             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   45384             :         if (unlikely(Py_SIZE(x) < 0)) {
   45385             :             goto raise_neg_overflow;
   45386             :         }
   45387             : #else
   45388             :         {
   45389             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   45390             :             if (unlikely(result < 0))
   45391             :                 return (int) -1;
   45392             :             if (unlikely(result == 1))
   45393             :                 goto raise_neg_overflow;
   45394             :         }
   45395             : #endif
   45396             :         if ((sizeof(int) <= sizeof(unsigned long))) {
   45397             :             __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
   45398             : #ifdef HAVE_LONG_LONG
   45399             :         } else if ((sizeof(int) <= sizeof(unsigned PY_LONG_LONG))) {
   45400             :             __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   45401             : #endif
   45402             :         }
   45403             :     } else {
   45404             : #if CYTHON_USE_PYLONG_INTERNALS
   45405           0 :         if (__Pyx_PyLong_IsCompact(x)) {
   45406           0 :             __PYX_VERIFY_RETURN_INT(int, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   45407             :         } else {
   45408           0 :             const digit* digits = __Pyx_PyLong_Digits(x);
   45409           0 :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45410           0 :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   45411             :                 case -2:
   45412           0 :                     if ((8 * sizeof(int) - 1 > 1 * PyLong_SHIFT)) {
   45413           0 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45414           0 :                             __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45415             :                         } else if ((8 * sizeof(int) - 1 > 2 * PyLong_SHIFT)) {
   45416             :                             return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45417             :                         }
   45418             :                     }
   45419             :                     break;
   45420             :                 case 2:
   45421           0 :                     if ((8 * sizeof(int) > 1 * PyLong_SHIFT)) {
   45422           0 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45423           0 :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45424             :                         } else if ((8 * sizeof(int) - 1 > 2 * PyLong_SHIFT)) {
   45425             :                             return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45426             :                         }
   45427             :                     }
   45428             :                     break;
   45429             :                 case -3:
   45430             :                     if ((8 * sizeof(int) - 1 > 2 * PyLong_SHIFT)) {
   45431             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45432             :                             __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45433             :                         } else if ((8 * sizeof(int) - 1 > 3 * PyLong_SHIFT)) {
   45434             :                             return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45435             :                         }
   45436             :                     }
   45437             :                     break;
   45438             :                 case 3:
   45439             :                     if ((8 * sizeof(int) > 2 * PyLong_SHIFT)) {
   45440             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45441             :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45442             :                         } else if ((8 * sizeof(int) - 1 > 3 * PyLong_SHIFT)) {
   45443             :                             return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45444             :                         }
   45445             :                     }
   45446             :                     break;
   45447             :                 case -4:
   45448             :                     if ((8 * sizeof(int) - 1 > 3 * PyLong_SHIFT)) {
   45449             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45450             :                             __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45451             :                         } else if ((8 * sizeof(int) - 1 > 4 * PyLong_SHIFT)) {
   45452             :                             return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45453             :                         }
   45454             :                     }
   45455             :                     break;
   45456             :                 case 4:
   45457             :                     if ((8 * sizeof(int) > 3 * PyLong_SHIFT)) {
   45458             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45459             :                             __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45460             :                         } else if ((8 * sizeof(int) - 1 > 4 * PyLong_SHIFT)) {
   45461             :                             return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
   45462             :                         }
   45463             :                     }
   45464             :                     break;
   45465             :             }
   45466             :         }
   45467             : #endif
   45468           0 :         if ((sizeof(int) <= sizeof(long))) {
   45469           0 :             __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
   45470             : #ifdef HAVE_LONG_LONG
   45471             :         } else if ((sizeof(int) <= sizeof(PY_LONG_LONG))) {
   45472             :             __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
   45473             : #endif
   45474             :         }
   45475             :     }
   45476             :     {
   45477             :         int val;
   45478             :         int ret = -1;
   45479             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   45480             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   45481             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   45482             :         if (unlikely(bytes_copied == -1)) {
   45483             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   45484             :             goto raise_overflow;
   45485             :         } else {
   45486             :             ret = 0;
   45487             :         }
   45488             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   45489             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   45490             :         unsigned char *bytes = (unsigned char *)&val;
   45491             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   45492             :                                     bytes, sizeof(val),
   45493             :                                     is_little, !is_unsigned);
   45494             : #else
   45495             :         PyObject *v;
   45496             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   45497             :         int bits, remaining_bits, is_negative = 0;
   45498             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   45499             :         if (likely(PyLong_CheckExact(x))) {
   45500             :             v = __Pyx_NewRef(x);
   45501             :         } else {
   45502             :             v = PyNumber_Long(x);
   45503             :             if (unlikely(!v)) return (int) -1;
   45504             :             assert(PyLong_CheckExact(v));
   45505             :         }
   45506             :         {
   45507             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   45508             :             if (unlikely(result < 0)) {
   45509             :                 Py_DECREF(v);
   45510             :                 return (int) -1;
   45511             :             }
   45512             :             is_negative = result == 1;
   45513             :         }
   45514             :         if (is_unsigned && unlikely(is_negative)) {
   45515             :             Py_DECREF(v);
   45516             :             goto raise_neg_overflow;
   45517             :         } else if (is_negative) {
   45518             :             stepval = PyNumber_Invert(v);
   45519             :             Py_DECREF(v);
   45520             :             if (unlikely(!stepval))
   45521             :                 return (int) -1;
   45522             :         } else {
   45523             :             stepval = v;
   45524             :         }
   45525             :         v = NULL;
   45526             :         val = (int) 0;
   45527             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   45528             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   45529             :         for (bits = 0; bits < (int) sizeof(int) * 8 - chunk_size; bits += chunk_size) {
   45530             :             PyObject *tmp, *digit;
   45531             :             long idigit;
   45532             :             digit = PyNumber_And(stepval, mask);
   45533             :             if (unlikely(!digit)) goto done;
   45534             :             idigit = PyLong_AsLong(digit);
   45535             :             Py_DECREF(digit);
   45536             :             if (unlikely(idigit < 0)) goto done;
   45537             :             val |= ((int) idigit) << bits;
   45538             :             tmp = PyNumber_Rshift(stepval, shift);
   45539             :             if (unlikely(!tmp)) goto done;
   45540             :             Py_DECREF(stepval); stepval = tmp;
   45541             :         }
   45542             :         Py_DECREF(shift); shift = NULL;
   45543             :         Py_DECREF(mask); mask = NULL;
   45544             :         {
   45545             :             long idigit = PyLong_AsLong(stepval);
   45546             :             if (unlikely(idigit < 0)) goto done;
   45547             :             remaining_bits = ((int) sizeof(int) * 8) - bits - (is_unsigned ? 0 : 1);
   45548             :             if (unlikely(idigit >= (1L << remaining_bits)))
   45549             :                 goto raise_overflow;
   45550             :             val |= ((int) idigit) << bits;
   45551             :         }
   45552             :         if (!is_unsigned) {
   45553             :             if (unlikely(val & (((int) 1) << (sizeof(int) * 8 - 1))))
   45554             :                 goto raise_overflow;
   45555             :             if (is_negative)
   45556             :                 val = ~val;
   45557             :         }
   45558             :         ret = 0;
   45559             :     done:
   45560             :         Py_XDECREF(shift);
   45561             :         Py_XDECREF(mask);
   45562             :         Py_XDECREF(stepval);
   45563             : #endif
   45564             :         if (unlikely(ret))
   45565             :             return (int) -1;
   45566             :         return val;
   45567             :     }
   45568           0 : raise_overflow:
   45569           0 :     PyErr_SetString(PyExc_OverflowError,
   45570             :         "value too large to convert to int");
   45571           0 :     return (int) -1;
   45572             : raise_neg_overflow:
   45573             :     PyErr_SetString(PyExc_OverflowError,
   45574             :         "can't convert negative value to int");
   45575             :     return (int) -1;
   45576             : }
   45577             : 
   45578             : /* CIntToPy */
   45579         119 :   static CYTHON_INLINE PyObject* __Pyx_PyInt_From_npy_uintp(npy_uintp value) {
   45580             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45581             : #pragma GCC diagnostic push
   45582             : #pragma GCC diagnostic ignored "-Wconversion"
   45583             : #endif
   45584         119 :     const npy_uintp neg_one = (npy_uintp) -1, const_zero = (npy_uintp) 0;
   45585             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45586             : #pragma GCC diagnostic pop
   45587             : #endif
   45588         119 :     const int is_unsigned = neg_one > const_zero;
   45589         119 :     if (is_unsigned) {
   45590         119 :         if (sizeof(npy_uintp) < sizeof(long)) {
   45591             :             return PyInt_FromLong((long) value);
   45592         119 :         } else if (sizeof(npy_uintp) <= sizeof(unsigned long)) {
   45593         119 :             return PyLong_FromUnsignedLong((unsigned long) value);
   45594             : #ifdef HAVE_LONG_LONG
   45595             :         } else if (sizeof(npy_uintp) <= sizeof(unsigned PY_LONG_LONG)) {
   45596             :             return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
   45597             : #endif
   45598             :         }
   45599             :     } else {
   45600             :         if (sizeof(npy_uintp) <= sizeof(long)) {
   45601             :             return PyInt_FromLong((long) value);
   45602             : #ifdef HAVE_LONG_LONG
   45603             :         } else if (sizeof(npy_uintp) <= sizeof(PY_LONG_LONG)) {
   45604             :             return PyLong_FromLongLong((PY_LONG_LONG) value);
   45605             : #endif
   45606             :         }
   45607             :     }
   45608             :     {
   45609             :         unsigned char *bytes = (unsigned char *)&value;
   45610             : #if !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX >= 0x030d00A4
   45611             :         if (is_unsigned) {
   45612             :             return PyLong_FromUnsignedNativeBytes(bytes, sizeof(value), -1);
   45613             :         } else {
   45614             :             return PyLong_FromNativeBytes(bytes, sizeof(value), -1);
   45615             :         }
   45616             : #elif !CYTHON_COMPILING_IN_LIMITED_API && PY_VERSION_HEX < 0x030d0000
   45617             :         int one = 1; int little = (int)*(unsigned char *)&one;
   45618             :         return _PyLong_FromByteArray(bytes, sizeof(npy_uintp),
   45619             :                                      little, !is_unsigned);
   45620             : #else
   45621             :         int one = 1; int little = (int)*(unsigned char *)&one;
   45622             :         PyObject *from_bytes, *result = NULL;
   45623             :         PyObject *py_bytes = NULL, *arg_tuple = NULL, *kwds = NULL, *order_str = NULL;
   45624             :         from_bytes = PyObject_GetAttrString((PyObject*)&PyLong_Type, "from_bytes");
   45625             :         if (!from_bytes) return NULL;
   45626             :         py_bytes = PyBytes_FromStringAndSize((char*)bytes, sizeof(npy_uintp));
   45627             :         if (!py_bytes) goto limited_bad;
   45628             :         order_str = PyUnicode_FromString(little ? "little" : "big");
   45629             :         if (!order_str) goto limited_bad;
   45630             :         arg_tuple = PyTuple_Pack(2, py_bytes, order_str);
   45631             :         if (!arg_tuple) goto limited_bad;
   45632             :         if (!is_unsigned) {
   45633             :             kwds = PyDict_New();
   45634             :             if (!kwds) goto limited_bad;
   45635             :             if (PyDict_SetItemString(kwds, "signed", __Pyx_NewRef(Py_True))) goto limited_bad;
   45636             :         }
   45637             :         result = PyObject_Call(from_bytes, arg_tuple, kwds);
   45638             :         limited_bad:
   45639             :         Py_XDECREF(kwds);
   45640             :         Py_XDECREF(arg_tuple);
   45641             :         Py_XDECREF(order_str);
   45642             :         Py_XDECREF(py_bytes);
   45643             :         Py_XDECREF(from_bytes);
   45644             :         return result;
   45645             : #endif
   45646             :     }
   45647             : }
   45648             : 
   45649             : /* CIntFromPy */
   45650             :   static CYTHON_INLINE npy_uintp __Pyx_PyInt_As_npy_uintp(PyObject *x) {
   45651             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45652             : #pragma GCC diagnostic push
   45653             : #pragma GCC diagnostic ignored "-Wconversion"
   45654             : #endif
   45655             :     const npy_uintp neg_one = (npy_uintp) -1, const_zero = (npy_uintp) 0;
   45656             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45657             : #pragma GCC diagnostic pop
   45658             : #endif
   45659             :     const int is_unsigned = neg_one > const_zero;
   45660             : #if PY_MAJOR_VERSION < 3
   45661             :     if (likely(PyInt_Check(x))) {
   45662             :         if ((sizeof(npy_uintp) < sizeof(long))) {
   45663             :             __PYX_VERIFY_RETURN_INT(npy_uintp, long, PyInt_AS_LONG(x))
   45664             :         } else {
   45665             :             long val = PyInt_AS_LONG(x);
   45666             :             if (is_unsigned && unlikely(val < 0)) {
   45667             :                 goto raise_neg_overflow;
   45668             :             }
   45669             :             return (npy_uintp) val;
   45670             :         }
   45671             :     }
   45672             : #endif
   45673             :     if (unlikely(!PyLong_Check(x))) {
   45674             :         npy_uintp val;
   45675             :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   45676             :         if (!tmp) return (npy_uintp) -1;
   45677             :         val = __Pyx_PyInt_As_npy_uintp(tmp);
   45678             :         Py_DECREF(tmp);
   45679             :         return val;
   45680             :     }
   45681             :     if (is_unsigned) {
   45682             : #if CYTHON_USE_PYLONG_INTERNALS
   45683             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   45684             :             goto raise_neg_overflow;
   45685             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   45686             :             __PYX_VERIFY_RETURN_INT(npy_uintp, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   45687             :         } else {
   45688             :             const digit* digits = __Pyx_PyLong_Digits(x);
   45689             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45690             :             switch (__Pyx_PyLong_DigitCount(x)) {
   45691             :                 case 2:
   45692             :                     if ((8 * sizeof(npy_uintp) > 1 * PyLong_SHIFT)) {
   45693             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45694             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45695             :                         } else if ((8 * sizeof(npy_uintp) >= 2 * PyLong_SHIFT)) {
   45696             :                             return (npy_uintp) (((((npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0]));
   45697             :                         }
   45698             :                     }
   45699             :                     break;
   45700             :                 case 3:
   45701             :                     if ((8 * sizeof(npy_uintp) > 2 * PyLong_SHIFT)) {
   45702             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45703             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45704             :                         } else if ((8 * sizeof(npy_uintp) >= 3 * PyLong_SHIFT)) {
   45705             :                             return (npy_uintp) (((((((npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0]));
   45706             :                         }
   45707             :                     }
   45708             :                     break;
   45709             :                 case 4:
   45710             :                     if ((8 * sizeof(npy_uintp) > 3 * PyLong_SHIFT)) {
   45711             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45712             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45713             :                         } else if ((8 * sizeof(npy_uintp) >= 4 * PyLong_SHIFT)) {
   45714             :                             return (npy_uintp) (((((((((npy_uintp)digits[3]) << PyLong_SHIFT) | (npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0]));
   45715             :                         }
   45716             :                     }
   45717             :                     break;
   45718             :             }
   45719             :         }
   45720             : #endif
   45721             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   45722             :         if (unlikely(Py_SIZE(x) < 0)) {
   45723             :             goto raise_neg_overflow;
   45724             :         }
   45725             : #else
   45726             :         {
   45727             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   45728             :             if (unlikely(result < 0))
   45729             :                 return (npy_uintp) -1;
   45730             :             if (unlikely(result == 1))
   45731             :                 goto raise_neg_overflow;
   45732             :         }
   45733             : #endif
   45734             :         if ((sizeof(npy_uintp) <= sizeof(unsigned long))) {
   45735             :             __PYX_VERIFY_RETURN_INT_EXC(npy_uintp, unsigned long, PyLong_AsUnsignedLong(x))
   45736             : #ifdef HAVE_LONG_LONG
   45737             :         } else if ((sizeof(npy_uintp) <= sizeof(unsigned PY_LONG_LONG))) {
   45738             :             __PYX_VERIFY_RETURN_INT_EXC(npy_uintp, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   45739             : #endif
   45740             :         }
   45741             :     } else {
   45742             : #if CYTHON_USE_PYLONG_INTERNALS
   45743             :         if (__Pyx_PyLong_IsCompact(x)) {
   45744             :             __PYX_VERIFY_RETURN_INT(npy_uintp, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   45745             :         } else {
   45746             :             const digit* digits = __Pyx_PyLong_Digits(x);
   45747             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45748             :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   45749             :                 case -2:
   45750             :                     if ((8 * sizeof(npy_uintp) - 1 > 1 * PyLong_SHIFT)) {
   45751             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45752             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45753             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 2 * PyLong_SHIFT)) {
   45754             :                             return (npy_uintp) (((npy_uintp)-1)*(((((npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45755             :                         }
   45756             :                     }
   45757             :                     break;
   45758             :                 case 2:
   45759             :                     if ((8 * sizeof(npy_uintp) > 1 * PyLong_SHIFT)) {
   45760             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45761             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45762             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 2 * PyLong_SHIFT)) {
   45763             :                             return (npy_uintp) ((((((npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45764             :                         }
   45765             :                     }
   45766             :                     break;
   45767             :                 case -3:
   45768             :                     if ((8 * sizeof(npy_uintp) - 1 > 2 * PyLong_SHIFT)) {
   45769             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45770             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45771             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 3 * PyLong_SHIFT)) {
   45772             :                             return (npy_uintp) (((npy_uintp)-1)*(((((((npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45773             :                         }
   45774             :                     }
   45775             :                     break;
   45776             :                 case 3:
   45777             :                     if ((8 * sizeof(npy_uintp) > 2 * PyLong_SHIFT)) {
   45778             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45779             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45780             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 3 * PyLong_SHIFT)) {
   45781             :                             return (npy_uintp) ((((((((npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45782             :                         }
   45783             :                     }
   45784             :                     break;
   45785             :                 case -4:
   45786             :                     if ((8 * sizeof(npy_uintp) - 1 > 3 * PyLong_SHIFT)) {
   45787             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45788             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45789             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 4 * PyLong_SHIFT)) {
   45790             :                             return (npy_uintp) (((npy_uintp)-1)*(((((((((npy_uintp)digits[3]) << PyLong_SHIFT) | (npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45791             :                         }
   45792             :                     }
   45793             :                     break;
   45794             :                 case 4:
   45795             :                     if ((8 * sizeof(npy_uintp) > 3 * PyLong_SHIFT)) {
   45796             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   45797             :                             __PYX_VERIFY_RETURN_INT(npy_uintp, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45798             :                         } else if ((8 * sizeof(npy_uintp) - 1 > 4 * PyLong_SHIFT)) {
   45799             :                             return (npy_uintp) ((((((((((npy_uintp)digits[3]) << PyLong_SHIFT) | (npy_uintp)digits[2]) << PyLong_SHIFT) | (npy_uintp)digits[1]) << PyLong_SHIFT) | (npy_uintp)digits[0])));
   45800             :                         }
   45801             :                     }
   45802             :                     break;
   45803             :             }
   45804             :         }
   45805             : #endif
   45806             :         if ((sizeof(npy_uintp) <= sizeof(long))) {
   45807             :             __PYX_VERIFY_RETURN_INT_EXC(npy_uintp, long, PyLong_AsLong(x))
   45808             : #ifdef HAVE_LONG_LONG
   45809             :         } else if ((sizeof(npy_uintp) <= sizeof(PY_LONG_LONG))) {
   45810             :             __PYX_VERIFY_RETURN_INT_EXC(npy_uintp, PY_LONG_LONG, PyLong_AsLongLong(x))
   45811             : #endif
   45812             :         }
   45813             :     }
   45814             :     {
   45815             :         npy_uintp val;
   45816             :         int ret = -1;
   45817             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   45818             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   45819             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   45820             :         if (unlikely(bytes_copied == -1)) {
   45821             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   45822             :             goto raise_overflow;
   45823             :         } else {
   45824             :             ret = 0;
   45825             :         }
   45826             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   45827             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   45828             :         unsigned char *bytes = (unsigned char *)&val;
   45829             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   45830             :                                     bytes, sizeof(val),
   45831             :                                     is_little, !is_unsigned);
   45832             : #else
   45833             :         PyObject *v;
   45834             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   45835             :         int bits, remaining_bits, is_negative = 0;
   45836             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   45837             :         if (likely(PyLong_CheckExact(x))) {
   45838             :             v = __Pyx_NewRef(x);
   45839             :         } else {
   45840             :             v = PyNumber_Long(x);
   45841             :             if (unlikely(!v)) return (npy_uintp) -1;
   45842             :             assert(PyLong_CheckExact(v));
   45843             :         }
   45844             :         {
   45845             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   45846             :             if (unlikely(result < 0)) {
   45847             :                 Py_DECREF(v);
   45848             :                 return (npy_uintp) -1;
   45849             :             }
   45850             :             is_negative = result == 1;
   45851             :         }
   45852             :         if (is_unsigned && unlikely(is_negative)) {
   45853             :             Py_DECREF(v);
   45854             :             goto raise_neg_overflow;
   45855             :         } else if (is_negative) {
   45856             :             stepval = PyNumber_Invert(v);
   45857             :             Py_DECREF(v);
   45858             :             if (unlikely(!stepval))
   45859             :                 return (npy_uintp) -1;
   45860             :         } else {
   45861             :             stepval = v;
   45862             :         }
   45863             :         v = NULL;
   45864             :         val = (npy_uintp) 0;
   45865             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   45866             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   45867             :         for (bits = 0; bits < (int) sizeof(npy_uintp) * 8 - chunk_size; bits += chunk_size) {
   45868             :             PyObject *tmp, *digit;
   45869             :             long idigit;
   45870             :             digit = PyNumber_And(stepval, mask);
   45871             :             if (unlikely(!digit)) goto done;
   45872             :             idigit = PyLong_AsLong(digit);
   45873             :             Py_DECREF(digit);
   45874             :             if (unlikely(idigit < 0)) goto done;
   45875             :             val |= ((npy_uintp) idigit) << bits;
   45876             :             tmp = PyNumber_Rshift(stepval, shift);
   45877             :             if (unlikely(!tmp)) goto done;
   45878             :             Py_DECREF(stepval); stepval = tmp;
   45879             :         }
   45880             :         Py_DECREF(shift); shift = NULL;
   45881             :         Py_DECREF(mask); mask = NULL;
   45882             :         {
   45883             :             long idigit = PyLong_AsLong(stepval);
   45884             :             if (unlikely(idigit < 0)) goto done;
   45885             :             remaining_bits = ((int) sizeof(npy_uintp) * 8) - bits - (is_unsigned ? 0 : 1);
   45886             :             if (unlikely(idigit >= (1L << remaining_bits)))
   45887             :                 goto raise_overflow;
   45888             :             val |= ((npy_uintp) idigit) << bits;
   45889             :         }
   45890             :         if (!is_unsigned) {
   45891             :             if (unlikely(val & (((npy_uintp) 1) << (sizeof(npy_uintp) * 8 - 1))))
   45892             :                 goto raise_overflow;
   45893             :             if (is_negative)
   45894             :                 val = ~val;
   45895             :         }
   45896             :         ret = 0;
   45897             :     done:
   45898             :         Py_XDECREF(shift);
   45899             :         Py_XDECREF(mask);
   45900             :         Py_XDECREF(stepval);
   45901             : #endif
   45902             :         if (unlikely(ret))
   45903             :             return (npy_uintp) -1;
   45904             :         return val;
   45905             :     }
   45906             : raise_overflow:
   45907             :     PyErr_SetString(PyExc_OverflowError,
   45908             :         "value too large to convert to npy_uintp");
   45909             :     return (npy_uintp) -1;
   45910             : raise_neg_overflow:
   45911             :     PyErr_SetString(PyExc_OverflowError,
   45912             :         "can't convert negative value to npy_uintp");
   45913             :     return (npy_uintp) -1;
   45914             : }
   45915             : 
   45916             : /* ImportNumPyArray */
   45917           1 :   static PyObject* __Pyx__ImportNumPyArray(void) {
   45918           1 :     PyObject *numpy_module, *ndarray_object = NULL;
   45919           1 :     numpy_module = __Pyx_Import(__pyx_n_s_numpy, NULL, 0);
   45920           1 :     if (likely(numpy_module)) {
   45921           1 :         ndarray_object = PyObject_GetAttrString(numpy_module, "ndarray");
   45922           1 :         Py_DECREF(numpy_module);
   45923             :     }
   45924           1 :     if (unlikely(!ndarray_object)) {
   45925           0 :         PyErr_Clear();
   45926             :     }
   45927           1 :     if (unlikely(!ndarray_object || !PyObject_TypeCheck(ndarray_object, &PyType_Type))) {
   45928           0 :         Py_XDECREF(ndarray_object);
   45929           0 :         Py_INCREF(Py_None);
   45930             :         ndarray_object = Py_None;
   45931             :     }
   45932           1 :     return ndarray_object;
   45933             : }
   45934         357 : static CYTHON_INLINE PyObject* __Pyx_ImportNumPyArrayTypeIfAvailable(void) {
   45935         357 :     if (unlikely(!__pyx_numpy_ndarray)) {
   45936           1 :         __pyx_numpy_ndarray = __Pyx__ImportNumPyArray();
   45937             :     }
   45938         357 :     Py_INCREF(__pyx_numpy_ndarray);
   45939         357 :     return __pyx_numpy_ndarray;
   45940             : }
   45941             : 
   45942             : /* CIntFromPy */
   45943           0 :   static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
   45944             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45945             : #pragma GCC diagnostic push
   45946             : #pragma GCC diagnostic ignored "-Wconversion"
   45947             : #endif
   45948           0 :     const long neg_one = (long) -1, const_zero = (long) 0;
   45949             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   45950             : #pragma GCC diagnostic pop
   45951             : #endif
   45952           0 :     const int is_unsigned = neg_one > const_zero;
   45953             : #if PY_MAJOR_VERSION < 3
   45954             :     if (likely(PyInt_Check(x))) {
   45955             :         if ((sizeof(long) < sizeof(long))) {
   45956             :             __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
   45957             :         } else {
   45958             :             long val = PyInt_AS_LONG(x);
   45959             :             if (is_unsigned && unlikely(val < 0)) {
   45960             :                 goto raise_neg_overflow;
   45961             :             }
   45962             :             return (long) val;
   45963             :         }
   45964             :     }
   45965             : #endif
   45966           0 :     if (unlikely(!PyLong_Check(x))) {
   45967           0 :         long val;
   45968           0 :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   45969           0 :         if (!tmp) return (long) -1;
   45970           0 :         val = __Pyx_PyInt_As_long(tmp);
   45971           0 :         Py_DECREF(tmp);
   45972           0 :         return val;
   45973             :     }
   45974           0 :     if (is_unsigned) {
   45975             : #if CYTHON_USE_PYLONG_INTERNALS
   45976             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   45977             :             goto raise_neg_overflow;
   45978             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   45979             :             __PYX_VERIFY_RETURN_INT(long, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   45980             :         } else {
   45981             :             const digit* digits = __Pyx_PyLong_Digits(x);
   45982             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   45983             :             switch (__Pyx_PyLong_DigitCount(x)) {
   45984             :                 case 2:
   45985             :                     if ((8 * sizeof(long) > 1 * PyLong_SHIFT)) {
   45986             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   45987             :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45988             :                         } else if ((8 * sizeof(long) >= 2 * PyLong_SHIFT)) {
   45989             :                             return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
   45990             :                         }
   45991             :                     }
   45992             :                     break;
   45993             :                 case 3:
   45994             :                     if ((8 * sizeof(long) > 2 * PyLong_SHIFT)) {
   45995             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   45996             :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   45997             :                         } else if ((8 * sizeof(long) >= 3 * PyLong_SHIFT)) {
   45998             :                             return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
   45999             :                         }
   46000             :                     }
   46001             :                     break;
   46002             :                 case 4:
   46003             :                     if ((8 * sizeof(long) > 3 * PyLong_SHIFT)) {
   46004             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46005             :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46006             :                         } else if ((8 * sizeof(long) >= 4 * PyLong_SHIFT)) {
   46007             :                             return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
   46008             :                         }
   46009             :                     }
   46010             :                     break;
   46011             :             }
   46012             :         }
   46013             : #endif
   46014             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   46015             :         if (unlikely(Py_SIZE(x) < 0)) {
   46016             :             goto raise_neg_overflow;
   46017             :         }
   46018             : #else
   46019             :         {
   46020             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   46021             :             if (unlikely(result < 0))
   46022             :                 return (long) -1;
   46023             :             if (unlikely(result == 1))
   46024             :                 goto raise_neg_overflow;
   46025             :         }
   46026             : #endif
   46027             :         if ((sizeof(long) <= sizeof(unsigned long))) {
   46028             :             __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
   46029             : #ifdef HAVE_LONG_LONG
   46030             :         } else if ((sizeof(long) <= sizeof(unsigned PY_LONG_LONG))) {
   46031             :             __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   46032             : #endif
   46033             :         }
   46034             :     } else {
   46035             : #if CYTHON_USE_PYLONG_INTERNALS
   46036           0 :         if (__Pyx_PyLong_IsCompact(x)) {
   46037           0 :             __PYX_VERIFY_RETURN_INT(long, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   46038             :         } else {
   46039           0 :             const digit* digits = __Pyx_PyLong_Digits(x);
   46040           0 :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   46041           0 :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   46042             :                 case -2:
   46043           0 :                     if ((8 * sizeof(long) - 1 > 1 * PyLong_SHIFT)) {
   46044           0 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   46045           0 :                             __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46046             :                         } else if ((8 * sizeof(long) - 1 > 2 * PyLong_SHIFT)) {
   46047             :                             return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46048             :                         }
   46049             :                     }
   46050             :                     break;
   46051             :                 case 2:
   46052           0 :                     if ((8 * sizeof(long) > 1 * PyLong_SHIFT)) {
   46053           0 :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   46054           0 :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46055             :                         } else if ((8 * sizeof(long) - 1 > 2 * PyLong_SHIFT)) {
   46056             :                             return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46057             :                         }
   46058             :                     }
   46059             :                     break;
   46060             :                 case -3:
   46061             :                     if ((8 * sizeof(long) - 1 > 2 * PyLong_SHIFT)) {
   46062             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   46063             :                             __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46064             :                         } else if ((8 * sizeof(long) - 1 > 3 * PyLong_SHIFT)) {
   46065             :                             return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46066             :                         }
   46067             :                     }
   46068             :                     break;
   46069             :                 case 3:
   46070             :                     if ((8 * sizeof(long) > 2 * PyLong_SHIFT)) {
   46071             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   46072             :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46073             :                         } else if ((8 * sizeof(long) - 1 > 3 * PyLong_SHIFT)) {
   46074             :                             return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46075             :                         }
   46076             :                     }
   46077             :                     break;
   46078             :                 case -4:
   46079             :                     if ((8 * sizeof(long) - 1 > 3 * PyLong_SHIFT)) {
   46080             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46081             :                             __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46082             :                         } else if ((8 * sizeof(long) - 1 > 4 * PyLong_SHIFT)) {
   46083             :                             return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46084             :                         }
   46085             :                     }
   46086             :                     break;
   46087             :                 case 4:
   46088             :                     if ((8 * sizeof(long) > 3 * PyLong_SHIFT)) {
   46089             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46090             :                             __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46091             :                         } else if ((8 * sizeof(long) - 1 > 4 * PyLong_SHIFT)) {
   46092             :                             return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
   46093             :                         }
   46094             :                     }
   46095             :                     break;
   46096             :             }
   46097             :         }
   46098             : #endif
   46099           0 :         if ((sizeof(long) <= sizeof(long))) {
   46100           0 :             __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
   46101             : #ifdef HAVE_LONG_LONG
   46102             :         } else if ((sizeof(long) <= sizeof(PY_LONG_LONG))) {
   46103             :             __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
   46104             : #endif
   46105             :         }
   46106             :     }
   46107             :     {
   46108             :         long val;
   46109             :         int ret = -1;
   46110             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   46111             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   46112             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   46113             :         if (unlikely(bytes_copied == -1)) {
   46114             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   46115             :             goto raise_overflow;
   46116             :         } else {
   46117             :             ret = 0;
   46118             :         }
   46119             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   46120             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   46121             :         unsigned char *bytes = (unsigned char *)&val;
   46122             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   46123             :                                     bytes, sizeof(val),
   46124             :                                     is_little, !is_unsigned);
   46125             : #else
   46126             :         PyObject *v;
   46127             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   46128             :         int bits, remaining_bits, is_negative = 0;
   46129             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   46130             :         if (likely(PyLong_CheckExact(x))) {
   46131             :             v = __Pyx_NewRef(x);
   46132             :         } else {
   46133             :             v = PyNumber_Long(x);
   46134             :             if (unlikely(!v)) return (long) -1;
   46135             :             assert(PyLong_CheckExact(v));
   46136             :         }
   46137             :         {
   46138             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   46139             :             if (unlikely(result < 0)) {
   46140             :                 Py_DECREF(v);
   46141             :                 return (long) -1;
   46142             :             }
   46143             :             is_negative = result == 1;
   46144             :         }
   46145             :         if (is_unsigned && unlikely(is_negative)) {
   46146             :             Py_DECREF(v);
   46147             :             goto raise_neg_overflow;
   46148             :         } else if (is_negative) {
   46149             :             stepval = PyNumber_Invert(v);
   46150             :             Py_DECREF(v);
   46151             :             if (unlikely(!stepval))
   46152             :                 return (long) -1;
   46153             :         } else {
   46154             :             stepval = v;
   46155             :         }
   46156             :         v = NULL;
   46157             :         val = (long) 0;
   46158             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   46159             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   46160             :         for (bits = 0; bits < (int) sizeof(long) * 8 - chunk_size; bits += chunk_size) {
   46161             :             PyObject *tmp, *digit;
   46162             :             long idigit;
   46163             :             digit = PyNumber_And(stepval, mask);
   46164             :             if (unlikely(!digit)) goto done;
   46165             :             idigit = PyLong_AsLong(digit);
   46166             :             Py_DECREF(digit);
   46167             :             if (unlikely(idigit < 0)) goto done;
   46168             :             val |= ((long) idigit) << bits;
   46169             :             tmp = PyNumber_Rshift(stepval, shift);
   46170             :             if (unlikely(!tmp)) goto done;
   46171             :             Py_DECREF(stepval); stepval = tmp;
   46172             :         }
   46173             :         Py_DECREF(shift); shift = NULL;
   46174             :         Py_DECREF(mask); mask = NULL;
   46175             :         {
   46176             :             long idigit = PyLong_AsLong(stepval);
   46177             :             if (unlikely(idigit < 0)) goto done;
   46178             :             remaining_bits = ((int) sizeof(long) * 8) - bits - (is_unsigned ? 0 : 1);
   46179             :             if (unlikely(idigit >= (1L << remaining_bits)))
   46180             :                 goto raise_overflow;
   46181             :             val |= ((long) idigit) << bits;
   46182             :         }
   46183             :         if (!is_unsigned) {
   46184             :             if (unlikely(val & (((long) 1) << (sizeof(long) * 8 - 1))))
   46185             :                 goto raise_overflow;
   46186             :             if (is_negative)
   46187             :                 val = ~val;
   46188             :         }
   46189             :         ret = 0;
   46190             :     done:
   46191             :         Py_XDECREF(shift);
   46192             :         Py_XDECREF(mask);
   46193             :         Py_XDECREF(stepval);
   46194             : #endif
   46195             :         if (unlikely(ret))
   46196             :             return (long) -1;
   46197             :         return val;
   46198             :     }
   46199             : raise_overflow:
   46200             :     PyErr_SetString(PyExc_OverflowError,
   46201             :         "value too large to convert to long");
   46202             :     return (long) -1;
   46203             : raise_neg_overflow:
   46204             :     PyErr_SetString(PyExc_OverflowError,
   46205             :         "can't convert negative value to long");
   46206             :     return (long) -1;
   46207             : }
   46208             : 
   46209             : /* CIntFromPy */
   46210             :   static CYTHON_INLINE char __Pyx_PyInt_As_char(PyObject *x) {
   46211             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   46212             : #pragma GCC diagnostic push
   46213             : #pragma GCC diagnostic ignored "-Wconversion"
   46214             : #endif
   46215             :     const char neg_one = (char) -1, const_zero = (char) 0;
   46216             : #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
   46217             : #pragma GCC diagnostic pop
   46218             : #endif
   46219             :     const int is_unsigned = neg_one > const_zero;
   46220             : #if PY_MAJOR_VERSION < 3
   46221             :     if (likely(PyInt_Check(x))) {
   46222             :         if ((sizeof(char) < sizeof(long))) {
   46223             :             __PYX_VERIFY_RETURN_INT(char, long, PyInt_AS_LONG(x))
   46224             :         } else {
   46225             :             long val = PyInt_AS_LONG(x);
   46226             :             if (is_unsigned && unlikely(val < 0)) {
   46227             :                 goto raise_neg_overflow;
   46228             :             }
   46229             :             return (char) val;
   46230             :         }
   46231             :     }
   46232             : #endif
   46233             :     if (unlikely(!PyLong_Check(x))) {
   46234             :         char val;
   46235             :         PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
   46236             :         if (!tmp) return (char) -1;
   46237             :         val = __Pyx_PyInt_As_char(tmp);
   46238             :         Py_DECREF(tmp);
   46239             :         return val;
   46240             :     }
   46241             :     if (is_unsigned) {
   46242             : #if CYTHON_USE_PYLONG_INTERNALS
   46243             :         if (unlikely(__Pyx_PyLong_IsNeg(x))) {
   46244             :             goto raise_neg_overflow;
   46245             :         } else if (__Pyx_PyLong_IsCompact(x)) {
   46246             :             __PYX_VERIFY_RETURN_INT(char, __Pyx_compact_upylong, __Pyx_PyLong_CompactValueUnsigned(x))
   46247             :         } else {
   46248             :             const digit* digits = __Pyx_PyLong_Digits(x);
   46249             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   46250             :             switch (__Pyx_PyLong_DigitCount(x)) {
   46251             :                 case 2:
   46252             :                     if ((8 * sizeof(char) > 1 * PyLong_SHIFT)) {
   46253             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   46254             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46255             :                         } else if ((8 * sizeof(char) >= 2 * PyLong_SHIFT)) {
   46256             :                             return (char) (((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0]));
   46257             :                         }
   46258             :                     }
   46259             :                     break;
   46260             :                 case 3:
   46261             :                     if ((8 * sizeof(char) > 2 * PyLong_SHIFT)) {
   46262             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   46263             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46264             :                         } else if ((8 * sizeof(char) >= 3 * PyLong_SHIFT)) {
   46265             :                             return (char) (((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]));
   46266             :                         }
   46267             :                     }
   46268             :                     break;
   46269             :                 case 4:
   46270             :                     if ((8 * sizeof(char) > 3 * PyLong_SHIFT)) {
   46271             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46272             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46273             :                         } else if ((8 * sizeof(char) >= 4 * PyLong_SHIFT)) {
   46274             :                             return (char) (((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]));
   46275             :                         }
   46276             :                     }
   46277             :                     break;
   46278             :             }
   46279             :         }
   46280             : #endif
   46281             : #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030C00A7
   46282             :         if (unlikely(Py_SIZE(x) < 0)) {
   46283             :             goto raise_neg_overflow;
   46284             :         }
   46285             : #else
   46286             :         {
   46287             :             int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
   46288             :             if (unlikely(result < 0))
   46289             :                 return (char) -1;
   46290             :             if (unlikely(result == 1))
   46291             :                 goto raise_neg_overflow;
   46292             :         }
   46293             : #endif
   46294             :         if ((sizeof(char) <= sizeof(unsigned long))) {
   46295             :             __PYX_VERIFY_RETURN_INT_EXC(char, unsigned long, PyLong_AsUnsignedLong(x))
   46296             : #ifdef HAVE_LONG_LONG
   46297             :         } else if ((sizeof(char) <= sizeof(unsigned PY_LONG_LONG))) {
   46298             :             __PYX_VERIFY_RETURN_INT_EXC(char, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
   46299             : #endif
   46300             :         }
   46301             :     } else {
   46302             : #if CYTHON_USE_PYLONG_INTERNALS
   46303             :         if (__Pyx_PyLong_IsCompact(x)) {
   46304             :             __PYX_VERIFY_RETURN_INT(char, __Pyx_compact_pylong, __Pyx_PyLong_CompactValue(x))
   46305             :         } else {
   46306             :             const digit* digits = __Pyx_PyLong_Digits(x);
   46307             :             assert(__Pyx_PyLong_DigitCount(x) > 1);
   46308             :             switch (__Pyx_PyLong_SignedDigitCount(x)) {
   46309             :                 case -2:
   46310             :                     if ((8 * sizeof(char) - 1 > 1 * PyLong_SHIFT)) {
   46311             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   46312             :                             __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46313             :                         } else if ((8 * sizeof(char) - 1 > 2 * PyLong_SHIFT)) {
   46314             :                             return (char) (((char)-1)*(((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46315             :                         }
   46316             :                     }
   46317             :                     break;
   46318             :                 case 2:
   46319             :                     if ((8 * sizeof(char) > 1 * PyLong_SHIFT)) {
   46320             :                         if ((8 * sizeof(unsigned long) > 2 * PyLong_SHIFT)) {
   46321             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46322             :                         } else if ((8 * sizeof(char) - 1 > 2 * PyLong_SHIFT)) {
   46323             :                             return (char) ((((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46324             :                         }
   46325             :                     }
   46326             :                     break;
   46327             :                 case -3:
   46328             :                     if ((8 * sizeof(char) - 1 > 2 * PyLong_SHIFT)) {
   46329             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   46330             :                             __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46331             :                         } else if ((8 * sizeof(char) - 1 > 3 * PyLong_SHIFT)) {
   46332             :                             return (char) (((char)-1)*(((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46333             :                         }
   46334             :                     }
   46335             :                     break;
   46336             :                 case 3:
   46337             :                     if ((8 * sizeof(char) > 2 * PyLong_SHIFT)) {
   46338             :                         if ((8 * sizeof(unsigned long) > 3 * PyLong_SHIFT)) {
   46339             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46340             :                         } else if ((8 * sizeof(char) - 1 > 3 * PyLong_SHIFT)) {
   46341             :                             return (char) ((((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46342             :                         }
   46343             :                     }
   46344             :                     break;
   46345             :                 case -4:
   46346             :                     if ((8 * sizeof(char) - 1 > 3 * PyLong_SHIFT)) {
   46347             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46348             :                             __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46349             :                         } else if ((8 * sizeof(char) - 1 > 4 * PyLong_SHIFT)) {
   46350             :                             return (char) (((char)-1)*(((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46351             :                         }
   46352             :                     }
   46353             :                     break;
   46354             :                 case 4:
   46355             :                     if ((8 * sizeof(char) > 3 * PyLong_SHIFT)) {
   46356             :                         if ((8 * sizeof(unsigned long) > 4 * PyLong_SHIFT)) {
   46357             :                             __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
   46358             :                         } else if ((8 * sizeof(char) - 1 > 4 * PyLong_SHIFT)) {
   46359             :                             return (char) ((((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
   46360             :                         }
   46361             :                     }
   46362             :                     break;
   46363             :             }
   46364             :         }
   46365             : #endif
   46366             :         if ((sizeof(char) <= sizeof(long))) {
   46367             :             __PYX_VERIFY_RETURN_INT_EXC(char, long, PyLong_AsLong(x))
   46368             : #ifdef HAVE_LONG_LONG
   46369             :         } else if ((sizeof(char) <= sizeof(PY_LONG_LONG))) {
   46370             :             __PYX_VERIFY_RETURN_INT_EXC(char, PY_LONG_LONG, PyLong_AsLongLong(x))
   46371             : #endif
   46372             :         }
   46373             :     }
   46374             :     {
   46375             :         char val;
   46376             :         int ret = -1;
   46377             : #if PY_VERSION_HEX >= 0x030d00A6 && !CYTHON_COMPILING_IN_LIMITED_API
   46378             :         Py_ssize_t bytes_copied = PyLong_AsNativeBytes(
   46379             :             x, &val, sizeof(val), Py_ASNATIVEBYTES_NATIVE_ENDIAN | (is_unsigned ? Py_ASNATIVEBYTES_UNSIGNED_BUFFER | Py_ASNATIVEBYTES_REJECT_NEGATIVE : 0));
   46380             :         if (unlikely(bytes_copied == -1)) {
   46381             :         } else if (unlikely(bytes_copied > (Py_ssize_t) sizeof(val))) {
   46382             :             goto raise_overflow;
   46383             :         } else {
   46384             :             ret = 0;
   46385             :         }
   46386             : #elif PY_VERSION_HEX < 0x030d0000 && !(CYTHON_COMPILING_IN_PYPY || CYTHON_COMPILING_IN_LIMITED_API) || defined(_PyLong_AsByteArray)
   46387             :         int one = 1; int is_little = (int)*(unsigned char *)&one;
   46388             :         unsigned char *bytes = (unsigned char *)&val;
   46389             :         ret = _PyLong_AsByteArray((PyLongObject *)x,
   46390             :                                     bytes, sizeof(val),
   46391             :                                     is_little, !is_unsigned);
   46392             : #else
   46393             :         PyObject *v;
   46394             :         PyObject *stepval = NULL, *mask = NULL, *shift = NULL;
   46395             :         int bits, remaining_bits, is_negative = 0;
   46396             :         int chunk_size = (sizeof(long) < 8) ? 30 : 62;
   46397             :         if (likely(PyLong_CheckExact(x))) {
   46398             :             v = __Pyx_NewRef(x);
   46399             :         } else {
   46400             :             v = PyNumber_Long(x);
   46401             :             if (unlikely(!v)) return (char) -1;
   46402             :             assert(PyLong_CheckExact(v));
   46403             :         }
   46404             :         {
   46405             :             int result = PyObject_RichCompareBool(v, Py_False, Py_LT);
   46406             :             if (unlikely(result < 0)) {
   46407             :                 Py_DECREF(v);
   46408             :                 return (char) -1;
   46409             :             }
   46410             :             is_negative = result == 1;
   46411             :         }
   46412             :         if (is_unsigned && unlikely(is_negative)) {
   46413             :             Py_DECREF(v);
   46414             :             goto raise_neg_overflow;
   46415             :         } else if (is_negative) {
   46416             :             stepval = PyNumber_Invert(v);
   46417             :             Py_DECREF(v);
   46418             :             if (unlikely(!stepval))
   46419             :                 return (char) -1;
   46420             :         } else {
   46421             :             stepval = v;
   46422             :         }
   46423             :         v = NULL;
   46424             :         val = (char) 0;
   46425             :         mask = PyLong_FromLong((1L << chunk_size) - 1); if (unlikely(!mask)) goto done;
   46426             :         shift = PyLong_FromLong(chunk_size); if (unlikely(!shift)) goto done;
   46427             :         for (bits = 0; bits < (int) sizeof(char) * 8 - chunk_size; bits += chunk_size) {
   46428             :             PyObject *tmp, *digit;
   46429             :             long idigit;
   46430             :             digit = PyNumber_And(stepval, mask);
   46431             :             if (unlikely(!digit)) goto done;
   46432             :             idigit = PyLong_AsLong(digit);
   46433             :             Py_DECREF(digit);
   46434             :             if (unlikely(idigit < 0)) goto done;
   46435             :             val |= ((char) idigit) << bits;
   46436             :             tmp = PyNumber_Rshift(stepval, shift);
   46437             :             if (unlikely(!tmp)) goto done;
   46438             :             Py_DECREF(stepval); stepval = tmp;
   46439             :         }
   46440             :         Py_DECREF(shift); shift = NULL;
   46441             :         Py_DECREF(mask); mask = NULL;
   46442             :         {
   46443             :             long idigit = PyLong_AsLong(stepval);
   46444             :             if (unlikely(idigit < 0)) goto done;
   46445             :             remaining_bits = ((int) sizeof(char) * 8) - bits - (is_unsigned ? 0 : 1);
   46446             :             if (unlikely(idigit >= (1L << remaining_bits)))
   46447             :                 goto raise_overflow;
   46448             :             val |= ((char) idigit) << bits;
   46449             :         }
   46450             :         if (!is_unsigned) {
   46451             :             if (unlikely(val & (((char) 1) << (sizeof(char) * 8 - 1))))
   46452             :                 goto raise_overflow;
   46453             :             if (is_negative)
   46454             :                 val = ~val;
   46455             :         }
   46456             :         ret = 0;
   46457             :     done:
   46458             :         Py_XDECREF(shift);
   46459             :         Py_XDECREF(mask);
   46460             :         Py_XDECREF(stepval);
   46461             : #endif
   46462             :         if (unlikely(ret))
   46463             :             return (char) -1;
   46464             :         return val;
   46465             :     }
   46466             : raise_overflow:
   46467             :     PyErr_SetString(PyExc_OverflowError,
   46468             :         "value too large to convert to char");
   46469             :     return (char) -1;
   46470             : raise_neg_overflow:
   46471             :     PyErr_SetString(PyExc_OverflowError,
   46472             :         "can't convert negative value to char");
   46473             :     return (char) -1;
   46474             : }
   46475             : 
   46476             : /* FormatTypeName */
   46477             :   #if CYTHON_COMPILING_IN_LIMITED_API
   46478             : static __Pyx_TypeName
   46479             : __Pyx_PyType_GetName(PyTypeObject* tp)
   46480             : {
   46481             :     PyObject *name = __Pyx_PyObject_GetAttrStr((PyObject *)tp,
   46482             :                                                __pyx_n_s_name_2);
   46483             :     if (unlikely(name == NULL) || unlikely(!PyUnicode_Check(name))) {
   46484             :         PyErr_Clear();
   46485             :         Py_XDECREF(name);
   46486             :         name = __Pyx_NewRef(__pyx_n_s__34);
   46487             :     }
   46488             :     return name;
   46489             : }
   46490             : #endif
   46491             : 
   46492             : /* CheckBinaryVersion */
   46493           3 :   static unsigned long __Pyx_get_runtime_version(void) {
   46494             : #if __PYX_LIMITED_VERSION_HEX >= 0x030B00A4
   46495           3 :     return Py_Version & ~0xFFUL;
   46496             : #else
   46497             :     const char* rt_version = Py_GetVersion();
   46498             :     unsigned long version = 0;
   46499             :     unsigned long factor = 0x01000000UL;
   46500             :     unsigned int digit = 0;
   46501             :     int i = 0;
   46502             :     while (factor) {
   46503             :         while ('0' <= rt_version[i] && rt_version[i] <= '9') {
   46504             :             digit = digit * 10 + (unsigned int) (rt_version[i] - '0');
   46505             :             ++i;
   46506             :         }
   46507             :         version += factor * digit;
   46508             :         if (rt_version[i] != '.')
   46509             :             break;
   46510             :         digit = 0;
   46511             :         factor >>= 8;
   46512             :         ++i;
   46513             :     }
   46514             :     return version;
   46515             : #endif
   46516             : }
   46517           3 : static int __Pyx_check_binary_version(unsigned long ct_version, unsigned long rt_version, int allow_newer) {
   46518           3 :     const unsigned long MAJOR_MINOR = 0xFFFF0000UL;
   46519           3 :     if ((rt_version & MAJOR_MINOR) == (ct_version & MAJOR_MINOR))
   46520             :         return 0;
   46521           0 :     if (likely(allow_newer && (rt_version & MAJOR_MINOR) > (ct_version & MAJOR_MINOR)))
   46522             :         return 1;
   46523             :     {
   46524           0 :         char message[200];
   46525           0 :         PyOS_snprintf(message, sizeof(message),
   46526             :                       "compile time Python version %d.%d "
   46527             :                       "of module '%.100s' "
   46528             :                       "%s "
   46529             :                       "runtime version %d.%d",
   46530           0 :                        (int) (ct_version >> 24), (int) ((ct_version >> 16) & 0xFF),
   46531             :                        __Pyx_MODULE_NAME,
   46532             :                        (allow_newer) ? "was newer than" : "does not match",
   46533           0 :                        (int) (rt_version >> 24), (int) ((rt_version >> 16) & 0xFF)
   46534             :        );
   46535           0 :         return PyErr_WarnEx(NULL, message, 1);
   46536             :     }
   46537             : }
   46538             : 
   46539             : /* InitStrings */
   46540             :   #if PY_MAJOR_VERSION >= 3
   46541         555 : static int __Pyx_InitString(__Pyx_StringTabEntry t, PyObject **str) {
   46542         555 :     if (t.is_unicode | t.is_str) {
   46543         552 :         if (t.intern) {
   46544         384 :             *str = PyUnicode_InternFromString(t.s);
   46545         168 :         } else if (t.encoding) {
   46546           0 :             *str = PyUnicode_Decode(t.s, t.n - 1, t.encoding, NULL);
   46547             :         } else {
   46548         168 :             *str = PyUnicode_FromStringAndSize(t.s, t.n - 1);
   46549             :         }
   46550             :     } else {
   46551           3 :         *str = PyBytes_FromStringAndSize(t.s, t.n - 1);
   46552             :     }
   46553         555 :     if (!*str)
   46554             :         return -1;
   46555         555 :     if (PyObject_Hash(*str) == -1)
   46556             :         return -1;
   46557             :     return 0;
   46558             : }
   46559             : #endif
   46560           3 : static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
   46561         558 :     while (t->p) {
   46562             :         #if PY_MAJOR_VERSION >= 3
   46563         555 :         __Pyx_InitString(*t, t->p);
   46564             :         #else
   46565             :         if (t->is_unicode) {
   46566             :             *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
   46567             :         } else if (t->intern) {
   46568             :             *t->p = PyString_InternFromString(t->s);
   46569             :         } else {
   46570             :             *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
   46571             :         }
   46572             :         if (!*t->p)
   46573             :             return -1;
   46574             :         if (PyObject_Hash(*t->p) == -1)
   46575             :             return -1;
   46576             :         #endif
   46577         555 :         ++t;
   46578             :     }
   46579           3 :     return 0;
   46580             : }
   46581             : 
   46582             : #include <string.h>
   46583           0 : static CYTHON_INLINE Py_ssize_t __Pyx_ssize_strlen(const char *s) {
   46584           0 :     size_t len = strlen(s);
   46585           0 :     if (unlikely(len > (size_t) PY_SSIZE_T_MAX)) {
   46586             :         PyErr_SetString(PyExc_OverflowError, "byte string is too long");
   46587             :         return -1;
   46588             :     }
   46589             :     return (Py_ssize_t) len;
   46590             : }
   46591             : static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
   46592             :     Py_ssize_t len = __Pyx_ssize_strlen(c_str);
   46593             :     if (unlikely(len < 0)) return NULL;
   46594             :     return __Pyx_PyUnicode_FromStringAndSize(c_str, len);
   46595             : }
   46596             : static CYTHON_INLINE PyObject* __Pyx_PyByteArray_FromString(const char* c_str) {
   46597             :     Py_ssize_t len = __Pyx_ssize_strlen(c_str);
   46598             :     if (unlikely(len < 0)) return NULL;
   46599             :     return PyByteArray_FromStringAndSize(c_str, len);
   46600             : }
   46601             : static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject* o) {
   46602             :     Py_ssize_t ignore;
   46603             :     return __Pyx_PyObject_AsStringAndSize(o, &ignore);
   46604             : }
   46605             : #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
   46606             : #if !CYTHON_PEP393_ENABLED
   46607             : static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
   46608             :     char* defenc_c;
   46609             :     PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
   46610             :     if (!defenc) return NULL;
   46611             :     defenc_c = PyBytes_AS_STRING(defenc);
   46612             : #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
   46613             :     {
   46614             :         char* end = defenc_c + PyBytes_GET_SIZE(defenc);
   46615             :         char* c;
   46616             :         for (c = defenc_c; c < end; c++) {
   46617             :             if ((unsigned char) (*c) >= 128) {
   46618             :                 PyUnicode_AsASCIIString(o);
   46619             :                 return NULL;
   46620             :             }
   46621             :         }
   46622             :     }
   46623             : #endif
   46624             :     *length = PyBytes_GET_SIZE(defenc);
   46625             :     return defenc_c;
   46626             : }
   46627             : #else
   46628             : static CYTHON_INLINE const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
   46629             :     if (unlikely(__Pyx_PyUnicode_READY(o) == -1)) return NULL;
   46630             : #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
   46631             :     if (likely(PyUnicode_IS_ASCII(o))) {
   46632             :         *length = PyUnicode_GET_LENGTH(o);
   46633             :         return PyUnicode_AsUTF8(o);
   46634             :     } else {
   46635             :         PyUnicode_AsASCIIString(o);
   46636             :         return NULL;
   46637             :     }
   46638             : #else
   46639             :     return PyUnicode_AsUTF8AndSize(o, length);
   46640             : #endif
   46641             : }
   46642             : #endif
   46643             : #endif
   46644             : static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
   46645             : #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
   46646             :     if (
   46647             : #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
   46648             :             __Pyx_sys_getdefaultencoding_not_ascii &&
   46649             : #endif
   46650             :             PyUnicode_Check(o)) {
   46651             :         return __Pyx_PyUnicode_AsStringAndSize(o, length);
   46652             :     } else
   46653             : #endif
   46654             : #if (!CYTHON_COMPILING_IN_PYPY && !CYTHON_COMPILING_IN_LIMITED_API) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
   46655             :     if (PyByteArray_Check(o)) {
   46656             :         *length = PyByteArray_GET_SIZE(o);
   46657             :         return PyByteArray_AS_STRING(o);
   46658             :     } else
   46659             : #endif
   46660             :     {
   46661             :         char* result;
   46662             :         int r = PyBytes_AsStringAndSize(o, &result, length);
   46663             :         if (unlikely(r < 0)) {
   46664             :             return NULL;
   46665             :         } else {
   46666             :             return result;
   46667             :         }
   46668             :     }
   46669             : }
   46670        1080 : static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
   46671        1080 :    int is_true = x == Py_True;
   46672        1080 :    if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
   46673         598 :    else return PyObject_IsTrue(x);
   46674             : }
   46675             : static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject* x) {
   46676             :     int retval;
   46677             :     if (unlikely(!x)) return -1;
   46678             :     retval = __Pyx_PyObject_IsTrue(x);
   46679             :     Py_DECREF(x);
   46680             :     return retval;
   46681             : }
   46682           0 : static PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result, const char* type_name) {
   46683           0 :     __Pyx_TypeName result_type_name = __Pyx_PyType_GetName(Py_TYPE(result));
   46684             : #if PY_MAJOR_VERSION >= 3
   46685           0 :     if (PyLong_Check(result)) {
   46686           0 :         if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
   46687             :                 "__int__ returned non-int (type " __Pyx_FMT_TYPENAME ").  "
   46688             :                 "The ability to return an instance of a strict subclass of int is deprecated, "
   46689             :                 "and may be removed in a future version of Python.",
   46690             :                 result_type_name)) {
   46691           0 :             __Pyx_DECREF_TypeName(result_type_name);
   46692           0 :             Py_DECREF(result);
   46693           0 :             return NULL;
   46694             :         }
   46695             :         __Pyx_DECREF_TypeName(result_type_name);
   46696             :         return result;
   46697             :     }
   46698             : #endif
   46699           0 :     PyErr_Format(PyExc_TypeError,
   46700             :                  "__%.4s__ returned non-%.4s (type " __Pyx_FMT_TYPENAME ")",
   46701             :                  type_name, type_name, result_type_name);
   46702           0 :     __Pyx_DECREF_TypeName(result_type_name);
   46703           0 :     Py_DECREF(result);
   46704             :     return NULL;
   46705             : }
   46706           0 : static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
   46707             : #if CYTHON_USE_TYPE_SLOTS
   46708           0 :   PyNumberMethods *m;
   46709             : #endif
   46710           0 :   const char *name = NULL;
   46711           0 :   PyObject *res = NULL;
   46712             : #if PY_MAJOR_VERSION < 3
   46713             :   if (likely(PyInt_Check(x) || PyLong_Check(x)))
   46714             : #else
   46715           0 :   if (likely(PyLong_Check(x)))
   46716             : #endif
   46717           0 :     return __Pyx_NewRef(x);
   46718             : #if CYTHON_USE_TYPE_SLOTS
   46719           0 :   m = Py_TYPE(x)->tp_as_number;
   46720             :   #if PY_MAJOR_VERSION < 3
   46721             :   if (m && m->nb_int) {
   46722             :     name = "int";
   46723             :     res = m->nb_int(x);
   46724             :   }
   46725             :   else if (m && m->nb_long) {
   46726             :     name = "long";
   46727             :     res = m->nb_long(x);
   46728             :   }
   46729             :   #else
   46730           0 :   if (likely(m && m->nb_int)) {
   46731           0 :     name = "int";
   46732           0 :     res = m->nb_int(x);
   46733             :   }
   46734             :   #endif
   46735             : #else
   46736             :   if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
   46737             :     res = PyNumber_Int(x);
   46738             :   }
   46739             : #endif
   46740           0 :   if (likely(res)) {
   46741             : #if PY_MAJOR_VERSION < 3
   46742             :     if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
   46743             : #else
   46744           0 :     if (unlikely(!PyLong_CheckExact(res))) {
   46745             : #endif
   46746           0 :         return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
   46747             :     }
   46748             :   }
   46749           0 :   else if (!PyErr_Occurred()) {
   46750           0 :     PyErr_SetString(PyExc_TypeError,
   46751             :                     "an integer is required");
   46752             :   }
   46753             :   return res;
   46754             : }
   46755         762 : static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
   46756         762 :   Py_ssize_t ival;
   46757         762 :   PyObject *x;
   46758             : #if PY_MAJOR_VERSION < 3
   46759             :   if (likely(PyInt_CheckExact(b))) {
   46760             :     if (sizeof(Py_ssize_t) >= sizeof(long))
   46761             :         return PyInt_AS_LONG(b);
   46762             :     else
   46763             :         return PyInt_AsSsize_t(b);
   46764             :   }
   46765             : #endif
   46766         762 :   if (likely(PyLong_CheckExact(b))) {
   46767             :     #if CYTHON_USE_PYLONG_INTERNALS
   46768         762 :     if (likely(__Pyx_PyLong_IsCompact(b))) {
   46769         762 :         return __Pyx_PyLong_CompactValue(b);
   46770             :     } else {
   46771           0 :       const digit* digits = __Pyx_PyLong_Digits(b);
   46772           0 :       const Py_ssize_t size = __Pyx_PyLong_SignedDigitCount(b);
   46773           0 :       switch (size) {
   46774             :          case 2:
   46775           0 :            if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
   46776           0 :              return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46777             :            }
   46778             :            break;
   46779             :          case -2:
   46780           0 :            if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
   46781           0 :              return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46782             :            }
   46783             :            break;
   46784             :          case 3:
   46785             :            if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
   46786             :              return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46787             :            }
   46788             :            break;
   46789             :          case -3:
   46790             :            if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
   46791             :              return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46792             :            }
   46793             :            break;
   46794             :          case 4:
   46795             :            if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
   46796             :              return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46797             :            }
   46798             :            break;
   46799             :          case -4:
   46800             :            if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
   46801             :              return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
   46802             :            }
   46803             :            break;
   46804             :       }
   46805             :     }
   46806             :     #endif
   46807           0 :     return PyLong_AsSsize_t(b);
   46808             :   }
   46809           0 :   x = PyNumber_Index(b);
   46810           0 :   if (!x) return -1;
   46811           0 :   ival = PyInt_AsSsize_t(x);
   46812           0 :   Py_DECREF(x);
   46813             :   return ival;
   46814             : }
   46815             : static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject* o) {
   46816             :   if (sizeof(Py_hash_t) == sizeof(Py_ssize_t)) {
   46817             :     return (Py_hash_t) __Pyx_PyIndex_AsSsize_t(o);
   46818             : #if PY_MAJOR_VERSION < 3
   46819             :   } else if (likely(PyInt_CheckExact(o))) {
   46820             :     return PyInt_AS_LONG(o);
   46821             : #endif
   46822             :   } else {
   46823             :     Py_ssize_t ival;
   46824             :     PyObject *x;
   46825             :     x = PyNumber_Index(o);
   46826             :     if (!x) return -1;
   46827             :     ival = PyInt_AsLong(x);
   46828             :     Py_DECREF(x);
   46829             :     return ival;
   46830             :   }
   46831             : }
   46832           0 : static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
   46833           0 :   return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
   46834             : }
   46835             : static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
   46836             :     return PyInt_FromSize_t(ival);
   46837             : }
   46838             : 
   46839             : 
   46840             : /* #### Code section: utility_code_pragmas_end ### */
   46841             : #ifdef _MSC_VER
   46842             : #pragma warning( pop )
   46843             : #endif
   46844             : 
   46845             : 
   46846             : 
   46847             : /* #### Code section: end ### */
   46848             : #endif /* Py_PYTHON_H */

Generated by: LCOV version 1.16